On Friday, 8 February 2013 at 20:10:32 UTC, Nrgyzer wrote:
void main() {
   int[string] b;
   b["hello"] = 3;
}

This works for both versions... but I don't know why using a method with ref-return value doesn't work anymore.

Thanks for your suggestion.

This works because an element is assigned if absent (expression is treated as lvalue). In case of return an element is not assigned (rvalue), so exception is thrown. I do not now why it worked in 2.060.

Reply via email to