Voldemort declarations inside structs with ctor initialization
via Digitalmars-d
digitalmars-d at puremagic.com
Tue May 27 10:23:23 PDT 2014
On Tuesday, 27 May 2014 at 15:06:53 UTC, bearophile wrote:
> Luís Marques:
>
>> If the language allowed foo to be declared using auto (which
>> would be deduced from the assignment in the ctor), that would
>> be nice, right?
>
> This is a kind of flow typing, it's rather useful but it
> introduces several complexities, so I think it's now too much
> late to add it to D.
Not necessarily. The first assignment of a member in a
constructor is already treated as special, so I guess we're
halfway there.
More information about the Digitalmars-d
mailing list