http://d.puremagic.com/issues/show_bug.cgi?id=3167
Summary: Passing result of a function call as ref argument no longer works Product: D Version: 1.046 Platform: All OS/Version: All Status: NEW Severity: regression Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: nfx...@gmail.com The following code works with dmd 1.045, but not with 1.046. It seems you can no longer pass the result of a function call as argument to ref parameters. While it's debatable if the old or new behavior is better, the chan ge breaks existing code. >> struct X { } X i() { return X.init; } void foo(ref X x) { } void foo() { foo(i()); //line 12 } << This fails with test.d(12): Error: cannot assign to function call -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------