A graph data structure usable in @safe pure nothrow functions
w0rp via Digitalmars-d
digitalmars-d at puremagic.com
Mon May 26 04:47:56 PDT 2014
I just added @nogc support to the map and graph types, with
fallback behaviour for older D compiler versions. I used this.
static if(__VERSION__ < 2066) { enum nogc = 1; }
So as long as I write @nogc left of other attributes, it will
compile the library on both DMD 2.065 and DMD 2.066.
Now every range, get, and remove function on the maps and graphs
can be used in @nogc functions, because these functions never
allocate more memory on the garbage collected heap.
More information about the Digitalmars-d
mailing list