http://d.puremagic.com/issues/show_bug.cgi?id=3378
Summary: [tdpl] ++x should be an lvalue Product: D Version: unspecified Platform: Other OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: and...@metalanguage.com --- Comment #0 from Andrei Alexandrescu <and...@metalanguage.com> 2009-10-08 14:12:33 PDT --- This doesn't compile: ref int bump(ref int x) { return ++x; } The error message reveals two other issues: Error: x += 1 is not an lvalue 1. The increment is rewritten as x += 1, but it shouldn't as it's a fundamentally different operation 2. x += 1 is not a value itself. Indeed this doesn't compile either: ref int bump(ref int x) { return x += 1; } -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------