http://d.puremagic.com/issues/show_bug.cgi?id=4556
--- Comment #1 from Andrej Mitrovic 2010-08-01
14:46:50 PDT ---
See also the 8th example under "Nested Functions" on this page
http://www.digitalmars.com/d/2.0/function.html. Pasted here:
void test()
{ int j;
static int s;
struct Foo
{ int a;
int bar()
{ int c = s;// ok, s is static
int d = j;// error, no access to frame of test()
int foo()
{
int e = s;// ok, s is static
int f = j;// error, no access to frame of test()
return c + a;// ok, frame of bar() is accessible,
// so are members of Foo accessible via
// the 'this' pointer to Foo.bar()
}
return 0;
}
}
}
This compiles without errors.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---