@nogc

Dicebot via Digitalmars-d digitalmars-d at puremagic.com
Fri Jul 11 02:29:56 PDT 2014


On Friday, 11 July 2014 at 03:45:17 UTC, Walter Bright wrote:
> I've thought of allowing "throw new ...", and yours would be in 
> addition to that, in @nogc functions, but was waiting to see 
> how this would play out a bit first.

One can replace throwing of Error with printf + abort in @nogc 
blocks, similar to how assert(false) is reduced to HLT in release 
builds. Spec allows it.

Throwing exceptions should still result in compile-time error 
though, it is one of primary use cases of @nogc.


More information about the Digitalmars-d mailing list