struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / support / regression / tests / gcc-torture-execute-20000412-2.c
blob256d75f0c7f27f56899e23d03a52ba837e6d77ae
1 /*
2 20000412-2.c from the execute part of the gcc torture tests.
3 */
5 #include <testfwk.h>
7 #ifdef __SDCC
8 #pragma std_c99
9 #endif
11 #if !(defined (__SDCC_hc08) || defined (__SDCC_s08) || defined (__SDCC_mos6502) || defined (__SDCC_mos65c02) )
12 int f(int a,int *y)
14 int x = a;
16 if (a==0)
17 return *y;
19 return f(a-1,&x);
21 #endif
23 void
24 testTortureExecute (void)
26 #ifndef __SDCC_pic16
27 #if !(defined (__SDCC_mcs51) || defined (__SDCC_hc08) || defined (__SDCC_s08) || defined (__SDCC_mos6502) || defined (__SDCC_mos65c02) || defined (__SDCC_ds390) || defined (__SDCC_pdk13) || defined (__SDCC_pdk14) || defined (__SDCC_pdk15))
28 #if !defined(__SDCC_pic14) // Unsupported reentrancy
29 if (f (10, (int *) 0) != 1)
30 ASSERT (0);
31 return;
32 #endif
33 #endif
34 #endif