pr79732.c: Require alias support.
[official-gcc.git] / gcc / testsuite / gcc.dg / torture / pr51528.c
blobdb5f3e0cadd18d9bbddc7db0f1aeacfd95c944c3
1 /* { dg-do run } */
2 /* { dg-options "-fno-early-inlining" } */
4 extern void abort (void);
6 union U
8 int i;
9 _Bool b;
12 _Bool gb;
14 void __attribute__ ((noinline))
15 use_bool (union U u)
17 gb = u.b;
20 union U
21 bar (void)
23 union U u;
24 u.i = 0xFFFE;
25 return u;
28 union U __attribute__ ((noinline))
29 foo (void)
31 union U u,v;
33 u.b = 1;
34 use_bool (u);
35 u = bar ();
37 return u;
40 int main (int argc, char **argv)
42 union U u = foo ();
43 if (u.i != 0xFFFE)
44 abort ();
45 return 0;