Home | History | Annotate | Download | only in Parser
      1 // RUN: %clang_cc1 -fsyntax-only -verify %s
      2 
      3 // Note that this puts the expected lines before the directives to work around
      4 // limitations in the -verify mode.
      5 
      6 /* expected-warning {{missing '(' after '#pragma pack'}}*/ #pragma pack 10
      7 #pragma pack()
      8 #pragma pack(8)
      9 
     10 /*expected-warning {{unknown action for '#pragma pack'}}*/ #pragma pack(hello)
     11 #pragma pack(push)
     12 #pragma pack(pop)
     13 
     14 /* expected-warning {{expected integer or identifier in '#pragma pack'}}*/ #pragma pack(push,)
     15 /* expected-warning {{expected integer or identifier in '#pragma pack'}}*/ #pragma pack(push,)
     16 /* expected-warning {{expected integer or identifier in '#pragma pack'}}*/  #pragma pack(pop,)
     17 
     18 #pragma pack(push,i)
     19 /* expected-warning {{expected integer or identifier in '#pragma pack'}}*/ #pragma pack(push,i,
     20 /* expected-warning {{expected integer or identifier in '#pragma pack'}}*/ #pragma pack(push,i,)
     21 /* expected-warning {{expected integer or identifier in '#pragma pack'}}*/ #pragma pack(push,i,help)
     22 
     23 #pragma pack(push,8)
     24 /* expected-warning {{missing ')' after '#pragma pack'}}*/ #pragma pack(push,8,
     25 /* expected-warning {{missing ')' after '#pragma pack'}}*/ #pragma pack(push,8,)
     26 /* expected-warning {{missing ')' after '#pragma pack'}}*/ #pragma pack(push,i,8
     27 #pragma pack(push,i,8)
     28 
     29 /* expected-warning {{missing ')' after '#pragma pack'}}*/ #pragma pack(push
     30 
     31 _Pragma("pack(push)")
     32 /* expected-warning {{expected integer or identifier in '#pragma pack'}}*/ _Pragma("pack(push,)")
     33