struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / support / regression / tests / gcc-torture-execute-pr39233.c
blob584e0d5df999eba17a5336ae4776d1d3cf62d8e8
1 /*
2 pr39233.c from the execute part of the gcc torture tests.
3 */
5 #include <testfwk.h>
7 #ifdef __SDCC
8 #pragma std_c99
9 #pragma disable_warning 127
10 #endif
12 void
13 foo (void *p)
15 long l = (long) p;
16 if (l < 0 || l > 6)
17 ASSERT (0);
20 void
21 testTortureExecute (void)
23 short i;
24 for (i = 6; i >= 0; i--)
25 #if defined(__SDCC_pic14) // FIXME: maybe a bug in sdcc
26 foo (i);
27 #else
28 foo ((void *) (long) i);
29 #endif
30 return;