Confusion regarding struct lifecycle

Mike Parker via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Mon Feb 15 20:00:27 PST 2016


On Tuesday, 16 February 2016 at 03:39:00 UTC, Matt Elkins wrote:
> On Tuesday, 16 February 2016 at 03:31:51 UTC, maik klein wrote:
>> In D you can always call Foo.init even with @disable this(),
>
> Foo.init can be called implicitly (not just explicitly)? If so, 
> why even have @disable this(), if it offers no guarantees?

IMO, this is a bug. It should have to be explicit, just as it is 
with a single struct instance.


More information about the Digitalmars-d-learn mailing list