1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 -triple i686-apple-darwin9 %s -fsyntax-only -verify 2*f4a2713aSLionel Sambuc // expected-no-diagnostics 3*f4a2713aSLionel Sambuc 4*f4a2713aSLionel Sambuc // Pragma pack handling with tag declarations 5*f4a2713aSLionel Sambuc 6*f4a2713aSLionel Sambuc struct X; 7*f4a2713aSLionel Sambuc 8*f4a2713aSLionel Sambuc #pragma pack(2) 9*f4a2713aSLionel Sambuc struct X { int x; }; 10*f4a2713aSLionel Sambuc struct Y; 11*f4a2713aSLionel Sambuc #pragma pack() 12*f4a2713aSLionel Sambuc 13*f4a2713aSLionel Sambuc struct Y { int y; }; 14*f4a2713aSLionel Sambuc 15*f4a2713aSLionel Sambuc extern int check[__alignof(struct X) == 2 ? 1 : -1]; 16*f4a2713aSLionel Sambuc extern int check[__alignof(struct Y) == 4 ? 1 : -1]; 17*f4a2713aSLionel Sambuc 18