• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // RUN: %clang_cc1 -fsyntax-only -verify -pedantic %s
2 class C;
3 class C {
4 public:
5 protected:
6   typedef int A,B;
7   static int sf(), u;
8 
9   struct S {};
10   enum {}; // expected-warning{{declaration does not declare anything}}
11   int; // expected-warning {{declaration does not declare anything}}
12   int : 1, : 2;
13 
14 public:
m()15   void m() {
16     int l = 2;
17   };
18 
mt(T)19   template<typename T> void mt(T) { };
20   ; // expected-warning{{extra ';' inside a class}}
21 
22   virtual int vf() const volatile = 0;
23 
24 private:
25   int x,f(),y,g();
26   inline int h();
27   static const int sci = 10;
28   mutable int mi;
29 };
glo()30 void glo()
31 {
32   struct local {};
33 }
34 
35 // PR3177
36 typedef union {
37   __extension__ union {
38     int a;
39     float b;
40   } y;
41 } bug3177;
42 
43