alias foo = __traits(...)

Nick Treleaven via Digitalmars-d digitalmars-d at puremagic.com
Thu Nov 6 04:43:45 PST 2014


On 06/11/2014 01:36, Shammah Chancellor wrote:
> Is this fixed now?

How about:

alias compiles(alias expr) = __traits(compiles, expr);

I guess supporting that may be problematic (it's too liberal), so I 
think we should have __compiles(expr) instead. It looks like a small 
saving, but in complex template code I'm sure it would be appreciated. I 
think all the other traits could be wrapped normally if $SUBJECT is 
implemented, but __traits(compiles, ...) is special.


More information about the Digitalmars-d mailing list