temporary objects are not allowed to be pass by ref anymore

Denis Koroskin 2korden at gmail.com
Sun Apr 19 05:41:44 PDT 2009


What's a rationale behind an issue described bug 2621?
http://d.puremagic.com/issues/show_bug.cgi?id=2621

Why isn't it allowed anymore?

It broke quite a lot of my code. And while it is fixable by doing

auto tmp = someFunctionThatRetunsStruct();
someMethodThatAcceptsStructByReference(tmp);

it looks ugly and unnecessary.



More information about the Digitalmars-d mailing list