http://d.puremagic.com/issues/show_bug.cgi?id=2935
Walter Bright <bugzi...@digitalmars.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |bugzi...@digitalmars.com --- Comment #7 from Walter Bright <bugzi...@digitalmars.com> 2010-04-27 08:49:55 PDT --- The problem is a semantic one. Default arguments are evaluated in the context of the function declaration, not where it's used. So, the temporary generated by the constructor is created in global space! The patch tries to force it back into the function scope, but that doesn't work as you can see if you change foo() to: void foo() { bar(); bar(); } as it fails trying to allocate the same symbol twice. Not sure what the correct solution is at the moment. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------