Merge branches/gcc-4_9-branch rev 225109.
[official-gcc.git] / gcc-4_9-branch / gcc / testsuite / c-c++-common / ubsan / pr65984.c
blob94ba0110b0b2e6e07ab2342c30fa75e2ac56be52
1 /* PR tree-optimization/65984 */
2 /* { dg-do compile } */
3 /* { dg-options "-fnon-call-exceptions -fsanitize=bool,enum" } */
5 #ifndef __cplusplus
6 #define bool _Bool
7 #endif
9 enum E { E0, E1, E2 };
10 enum E e[2];
11 bool *b;
13 int
14 foo (int i)
16 return e[i];
19 int
20 bar (int i)
22 return b[i];