Proposal: Relax rules for 'pure'

klickverbot see at klickverbot.at
Wed Sep 22 11:03:05 PDT 2010


On 9/22/10 7:10 PM, Steven Schveighoffer wrote:
> But the compiler will be able to tell. I think adding a
> __traits(isStronglyPure, symbol) will be good for those rare occasions
> where you really want to ensure purity.
>
> static assert(__traits(isStronglyPure, foo));
>
> -Steve

Shouldn't it be possible to implement that in a library template, not 
requiring any additions to the compiler at all?


More information about the Digitalmars-d mailing list