diff options
Diffstat (limited to 'clang/test/Sema/pragma-ms_struct.c')
-rw-r--r-- | clang/test/Sema/pragma-ms_struct.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/clang/test/Sema/pragma-ms_struct.c b/clang/test/Sema/pragma-ms_struct.c index 61047c03098..b2c2684c619 100644 --- a/clang/test/Sema/pragma-ms_struct.c +++ b/clang/test/Sema/pragma-ms_struct.c @@ -17,3 +17,18 @@ struct foo char c; }; + +struct { + unsigned long bf_1 : 12; + unsigned long : 0; + unsigned long bf_2 : 12; +} __attribute__((__ms_struct__)) t1; + +struct S { + double __attribute__((ms_struct)) d; // expected-warning {{'ms_struct' attribute ignored}} + unsigned long bf_1 : 12; + unsigned long : 0; + unsigned long bf_2 : 12; +} __attribute__((ms_struct)) t2; + + |