Collections question

Jakob Ovrum via Digitalmars-d digitalmars-d at puremagic.com
Fri Nov 27 22:26:01 PST 2015


On Friday, 27 November 2015 at 20:25:12 UTC, Adam D. Ruppe wrote:
> That syntax is the same as constructors... if that's what you 
> want it to look like, we ought to actually use a constructor 
> for all but the zero-argument ones which I'd use a static named 
> function for (perhaps .make or perhaps .makeEmpty too)

While I think this would be nice and explicit, it's bad for 
generic code, which would have to specialize to correctly call 
the nullary version.



More information about the Digitalmars-d mailing list