http://d.puremagic.com/issues/show_bug.cgi?id=6284
Summary: [Regression 2.054] 'pure' does not work with 'with' statement Product: D Version: D2 Platform: Other OS/Version: Mac OS X Status: NEW Keywords: rejects-valid Severity: regression Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: kenn...@gmail.com --- Comment #0 from kenn...@gmail.com 2011-07-10 13:23:23 PDT --- Test case ----------------------------- struct S { int a; } pure void bug6284() { S s; auto b = s.a; // ok with (s) { auto c = a; // error } } ----------------------------- x.d(8): Error: pure nested function 'bug6284' cannot access mutable data 'a' ----------------------------- The error does not happen in 2.053, probably due to the stricter pure check in 2.054. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------