The "no gc" crowd

Adam D. Ruppe destructionator at gmail.com
Tue Oct 8 09:18:48 PDT 2013


On Tuesday, 8 October 2013 at 16:02:05 UTC, Tourist wrote:
> On Tuesday, 8 October 2013 at 15:53:47 UTC, Adam D. Ruppe wrote:
>> 2) have a flag where you can make gc allocations throw an 
>> assert error at runtime for debugging critical sections
>
> Why handle it at runtime and not at compile time?

One is I can implement a runtime check pretty easily so it'd just 
be the first step because it would go quickly.

The other reason though would be D doesn't really have an 
attributed section. You can't do:

void foo() {
    // stuff
    @nogc {
       // your performance sensitive loop code
    }
}

But on the function level, that could be done at compile time if 
implemented.


More information about the Digitalmars-d mailing list