libcpp, c, middle-end: Optimize initializers using #embed in C
[official-gcc.git] / gcc / testsuite / gcc.dg / enum-alias-2.c
blob7ca3f3b2db8cfb9a4858a84d597193bcdd29bec9
1 /* { dg-do run } */
2 /* { dg-options "-O2" } */
4 typedef int A;
6 void* foo(void* a, void *b, void *c, void *d)
8 *(A**)a = c;
11 typedef enum E B;
12 enum E { E1 = -1, E2 = 0, E3 = 1 };
13 *(B**)b = d;
16 return *(A**)a;
19 int main()
21 A *a, b, c;
22 if (&c != (A*)foo(&a, &a, &b, &c))
23 __builtin_abort();