struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / support / regression / tests / gcc-torture-execute-20050131-1.c
blob9368b2fb93a8dd7de47c2a843a0d201f70677c67
1 /*
2 20050131-1.c from the execute part of the gcc torture suite.
3 */
5 #include <testfwk.h>
7 #ifdef __SDCC
8 #pragma std_c99
9 #endif
11 /* Verify that we do not lose side effects on a MOD expression. */
13 #include <stdlib.h>
14 #include <stdio.h>
16 int
17 foo (int a)
19 int x = 0 % a++;
20 return a;
23 void
24 testTortureExecute (void)
26 if (foo (9) != 10)
27 ASSERT (0);
28 return;