Feature request: assert expressions should live inside version(assert)

Peter Alexander peter.alexander.au at gmail.com
Sun Jul 7 05:55:36 PDT 2013


On Sunday, 7 July 2013 at 12:30:28 UTC, Andrej Mitrovic wrote:
> I've ran into an issue when implementing this feature back in 
> February
> (see the pull request):
>
> http://d.puremagic.com/issues/show_bug.cgi?id=9450
> https://github.com/D-Programming-Language/dmd/pull/1614

WTF:

> Hmm.. I think we might have to close the report as invalid. The
> trouble is, you can't just ignore running semantic during 
> -release
> because the assert expression could be a compile-time false
> value, which turns the assert into a halt instruction 
> regardless of
> the -release switch.

I had no idea of this. What a terrible decision!


More information about the Digitalmars-d mailing list