std.sumtype?

rm rymrg at memail.com
Thu Mar 18 15:04:13 UTC 2021


> Is this realy final variant for including to phobos, not 
> std.experimental? No way for getting tag explicitly (it's private), no 
> way for getting type by tag, sumtype depend on order of types... I don't 
> see any discussion about including it to phobos... Why? Nobody cares?


I agree. Being able to extract items by type is missing. If the 
incorrect type is used, it can just assert(0);
This makes it really complicated to use in @nogc, since you cannot even 
create delegates to change things in your scope.


More information about the Digitalmars-d mailing list