-vgc Info ok?
Namespace via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Tue May 19 02:10:49 PDT 2015
On Monday, 18 May 2015 at 14:30:43 UTC, Chris wrote:
> The following
>
> string[string] myarray = ["key":"value"];
> string entry;
> entry = myarray["key"]; // => vgc: indexing an associative
> array may cause GC allocation
>
> Why is _accessing_ an assoc treated as indexing it?
No error if you use myarray.get("key", null); or string* entry =
"key" in myarray;
More information about the Digitalmars-d-learn
mailing list