Silly struct behaviour

Stefan Koch via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Thu Jul 13 11:48:17 PDT 2017


On Thursday, 13 July 2017 at 18:45:45 UTC, JN wrote:
> I know that's a wrong syntax, I was just showing an example.
>
> Yes, here it will work, but if you want to initialize only some 
> fields (poor man's keyword arguments), you can't use the 
> default constructor.

easily fixable by using FunctionLiterals.


More information about the Digitalmars-d-learn mailing list