[Issue 12018] New: More descriptive message for frame access error
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Tue Jan 28 08:15:04 PST 2014
https://d.puremagic.com/issues/show_bug.cgi?id=12018
Summary: More descriptive message for frame access error
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Keywords: diagnostic
Severity: enhancement
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: bearophile_hugs at eml.cc
--- Comment #0 from bearophile_hugs at eml.cc 2014-01-28 08:14:58 PST ---
This is wrong code:
void main() {
int x;
static void bar() {
x++;
}
}
dmd 2.065beta correctly gives an error message:
test.d(4): Error: static function test.main.bar cannot access frame of function
D main
But I'd like the name 'x' to be present in the error message. Because in a
complex line of code it's not easy to see what variable comes from the outer
scope.
--
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list