Struct default constructor - need some kind of solution for C++ interop

Andrei Alexandrescu via Digitalmars-d digitalmars-d at puremagic.com
Thu Sep 8 05:32:44 PDT 2016


On 9/8/16 12:06 PM, John Colvin wrote:
> I think it's too late for this stuff now for D anyway. There are
> workarounds that make life acceptable without default constructors, I
> can't see how we could add them without getting into a real mess.

A good point. I should mention, however, that the lack of a default 
constructor made at least one reference counting (in fact reference 
linking IIRC) impossible in D.

One thing we could look at is allow only CTFEable default constructors.


Andrei



More information about the Digitalmars-d mailing list