Skip analyzer strndup test on hppa*-*-hpux*
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.jason / local.C
blob18d810a33ba34b071403b2bc63f11ad57236789f
1 // { dg-do assemble  }
2 // General testcase for local classes.
4 int x;
5 void f ()
7   static int s;
8   int x;                        // { dg-message "" } referenced below
9   extern int q();
11   struct local {
12     int g() { return x; }       // { dg-error "" } automatic variable
13     int h() { return s; }       // { dg-bogus "" } local class
14     int k() { return ::x; }     // OK
15     int l() { return q(); }     // OK
16     int m();                    // OK - not defined
17     static int foo;             // { dg-error "" } static data member of local class
18   };
21 local* p = 0;                   // { dg-error "" } no such type in scope