http://d.puremagic.com/issues/show_bug.cgi?id=5239
Summary: optimizer misreports an used before set error Product: D Version: D2 Platform: Other OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: bra...@puremagic.com --- Comment #0 from Brad Roberts <bra...@puremagic.com> 2010-11-18 22:34:20 PST --- (an excerpt from runnable/interpret.d) struct S { int x; } template Compileable(int z) { bool OK=true;} int goodfoo3() { S[4] w = void; // uninitialized array of structs w[$-2].x = 217; // initialize one member return w[2].x; // line 8 } $ dmd -c -O f.d f.d(8): Error: variable w used before set note: filed as d2, but might well exist on d1 as well.. untested -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------