1 /* PR c/61053 */
2 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
3 /* { dg-options "-std=c11 -pedantic-errors" } */
4 
5 _Alignas (char) char cc;
6 _Alignas (short int) char cs;
7 _Alignas (int) char ci;
8 _Alignas (long int) char cl;
9 _Alignas (long long int) char cll;
10 _Alignas (float) char cf;
11 _Alignas (double) char cd;
12 _Alignas (long double) char cld;
13 
14 _Alignas (char) short int sc; /* { dg-error "cannot reduce alignment" } */
15 _Alignas (short int) short int ss;
16 _Alignas (int) short int si;
17 _Alignas (long int) short int sl;
18 _Alignas (long long int) short int sll;
19 _Alignas (float) short int sf;
20 _Alignas (double) short int sd;
21 _Alignas (long double) short int sld;
22 
23 _Alignas (char) int ic; /* { dg-error "cannot reduce alignment" } */
24 _Alignas (short int) int is; /* { dg-error "cannot reduce alignment" } */
25 _Alignas (int) int ii;
26 _Alignas (long int) int il;
27 _Alignas (long long int) int ill;
28 _Alignas (float) int if_;
29 _Alignas (double) int id;
30 _Alignas (long double) int ild;
31 
32 _Alignas (char) long int lic; /* { dg-error "cannot reduce alignment" } */
33 _Alignas (short int) long int lis; /* { dg-error "cannot reduce alignment" } */
34 _Alignas (int) long int lii; /* { dg-error "cannot reduce alignment" "" { target { ! { ilp32 } } } } */
35 _Alignas (long int) long int lil;
36 _Alignas (long long int) long int lill;
37 _Alignas (float) long int lif; /* { dg-error "cannot reduce alignment" "" { target { ! { ilp32 } } } } */
38 _Alignas (double) long int lid;
39 _Alignas (long double) long int lild;
40 
41 _Alignas (char) long long int llic; /* { dg-error "cannot reduce alignment" } */
42 _Alignas (short int) long long int llis; /* { dg-error "cannot reduce alignment" } */
43 _Alignas (int) long long int llii; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
44 _Alignas (long int) long long int llil; /* { dg-error "cannot reduce alignment" "" { target { x32 } } } */
45 _Alignas (long long int) long long int llill;
46 _Alignas (float) long long int llif; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
47 _Alignas (double) long long int llid;
48 _Alignas (long double) long long int llild;
49 
50 _Alignas (char) float fc; /* { dg-error "cannot reduce alignment" } */
51 _Alignas (short int) float fs; /* { dg-error "cannot reduce alignment" } */
52 _Alignas (int) float fi;
53 _Alignas (long int) float fl;
54 _Alignas (long long int) float fll;
55 _Alignas (float) float ff;
56 _Alignas (double) float fd;
57 _Alignas (long double) float fld;
58 
59 _Alignas (char) double dc; /* { dg-error "cannot reduce alignment" } */
60 _Alignas (short int) double ds; /* { dg-error "cannot reduce alignment" } */
61 _Alignas (int) double di; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
62 _Alignas (long int) double dl; /* { dg-error "cannot reduce alignment" "" { target { x32 } } } */
63 _Alignas (long long int) double dll;
64 _Alignas (float) double df; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
65 _Alignas (double) double dd;
66 _Alignas (long double) double dld;
67 
68 _Alignas (char) long double ldc; /* { dg-error "cannot reduce alignment" } */
69 _Alignas (short int) long double lds; /* { dg-error "cannot reduce alignment" } */
70 _Alignas (int) long double ldi; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
71 _Alignas (long int) long double ldl; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
72 _Alignas (long long int) long double ldll; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
73 _Alignas (float) long double ldf; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
74 _Alignas (double) long double ldd; /* { dg-error "cannot reduce alignment" "" { target { ! { ia32 } } } } */
75 _Alignas (long double) long double ldld;
76