Pick three bugfixes from next branch to trunk for inclusion in 4.5.0 RC2, as discusse...
[sdcc.git] / sdcc / support / regression / tests / gcc-torture-execute-921112-1.c
blobf4277986d4e47ee0baae726687d469c0498215fa
1 /*
2 921112-1.c from the execute part of the gcc torture suite.
3 */
5 #include <testfwk.h>
7 #ifdef __SDCC
8 #pragma std_c99
9 #pragma disable_warning 93
10 #endif
12 // TODO: Enable when sdcc supports struct!
13 #if 0
14 union u {
15 struct { int i1, i2; } t;
16 double d;
17 } x[2], v;
19 void f (union u *x, union u *v)
21 *++x = v;
23 #endif
25 void
26 testTortureExecute (void)
28 #if 0
29 x[1].t.i1 = x[1].t.i2 = 0;
30 v.t.i1 = 1;
31 v.t.i2 = 2;
32 f (x, v);
33 if (x[1].t.i1 != 1 || x[1].t.i2 != 2)
34 ASSERT (0);
35 return;
36 #endif