1 /* Test C11 alignment support. Test valid code. */
2 /* { dg-do compile } */
3 /* { dg-options "-std=c11 -pedantic-errors" } */
7 _Alignas (_Alignof (max_align_t
)) char c
;
8 extern _Alignas (max_align_t
) char c
;
11 extern _Alignas (max_align_t
) short s
;
12 _Alignas (max_align_t
) short s
;
17 _Alignas (max_align_t
) long l
;
19 _Alignas (max_align_t
) long long ll
;
21 _Alignas (max_align_t
) float f
;
23 _Alignas (max_align_t
) double d
;
25 _Alignas (max_align_t
) _Complex
long double cld
;
27 _Alignas (0) _Alignas (int) _Alignas (char) char ca
[10];
29 _Alignas ((int) _Alignof (max_align_t
) + 0) int x
;
31 enum e
{ E
= _Alignof (max_align_t
) };
37 _Alignas (max_align_t
) long long auto_ll
;
40 /* Valid, but useless. */
41 _Alignas (0) struct s
; /* { dg-warning "useless" } */