struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / support / regression / tests / bug-2715.c
blob3bdf7b1ddd3842177b999afe84ca8da2ffbe10e9
1 /*
2 bug-2715.c
3 */
5 #include <testfwk.h>
7 #pragma disable_warning 85
9 struct foo;
10 typedef struct foo FILE;
12 void pc(FILE *fp, char c)
16 void pd(FILE *fp, int n)
18 int c;
20 c = n%10 + '0'; // This addition has operands smaller than the result, resulting in a crash in the z80 backend.
21 if (n != 0)
22 pd(fp, n);
23 pc(fp, c);
26 void testBug(void)
28 pd(0, 0);