http://d.puremagic.com/issues/show_bug.cgi?id=6362
Summary: Can't return const reference to member Product: D Version: unspecified Platform: Other OS/Version: Windows Status: NEW Severity: regression Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: yarrluben+db...@googlemail.com --- Comment #0 from Pierre <yarrluben+db...@googlemail.com> 2011-07-22 03:57:48 PDT --- The problem started with dmd 2.054. I've had no problems with this in earlier versions. struct foo { public: const ref int get() const { return bar[0]; } private: int bar[1]; } void main(){ auto a = foo(); } ==> Error: cast(int)this.bar[0u] is not an lvalue -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------