this code:

class X{
    string[string] s;
    this() {
        s["s"] = "S";
    }
    ~this() {
        s.remove("s");

    }
}

void main() {
    X x = new X();
}

produces this:

core.exception.InvalidMemoryOperationError

because the aa is calling gc_free during a collection, apparently.

Should I be expecting the above code to run without error or not?

thanks

Reply via email to