Universal Construction Syntax for Pointers?

Meta via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Fri Jun 13 22:29:49 PDT 2014


I thought this was possible, but DMD 2.065 doesn't allow it, 
saying "no constructor for int":

int* p = new int(3);

Is something like this planned for the future? I know we can 
already do:

int n = int(3);


More information about the Digitalmars-d-learn mailing list