struct / union in initializer, RFE #901.
[sdcc.git] / sdcc / support / regression / tests / bug1496419.c
blob239c9b361876eba2e73e8cda523c75dc44287986
1 /*
2 bug1496419.c
3 */
5 #include <testfwk.h>
6 #include <stddef.h>
8 typedef struct _NODE
10 const struct _NODE * enter;
11 const struct _NODE * down;
12 }NODE;
14 const NODE node1 = {NULL, NULL};
16 //sdcc loops allocating space for new symbols node1 and
17 //zzz until there is no more memory, then segfaults
19 //The reference to zzz inside the declaration of zzz
20 //triggers a loop allocating space for symbols node1
21 //and zzz
22 const NODE zzz = {&node1, &zzz};
24 void testBug(void)