struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / support / regression / tests / gcc-torture-execute-arith-1.c
blob659e2934b4d42e540dd8c79b2531a5de36169c0e
1 /*
2 arith-1.c from the execute part of the gcc torture tests.
3 */
5 #include <testfwk.h>
7 #ifdef __SDCC
8 #pragma std_c89
9 #endif
11 unsigned
12 sat_add (unsigned i)
14 unsigned ret = i + 1;
15 if (ret < i)
16 ret = i;
17 return ret;
20 void
21 testTortureExecute (void)
23 if (sat_add (~0U) != ~0U)
24 ASSERT (0);
25 return;