1 typedef int ptr1() const; // no error
2 
foo()3 void foo ()
4 {
5   typedef int ptr2() const; // no error
6 }
7 
8 class C
9 {
10     typedef int ptr3() const;  // error
11 
bar()12     void bar ()
13       {
14         typedef int ptr4() const; // no error
15       }
16 };
17 
wibble()18 void wibble () const { } // { dg-error "non-member function" }
19