scc

simple C compiler
git clone git://git.2f30.org/scc
Log | Files | Refs | README | LICENSE

0094-arrayinit.c (197B)


      1 typedef struct {
      2 	int v;
      3 	int sub[2];
      4 } S;
      5 
      6 S a[1] = {{1, {2, 3}}};
      7 
      8 int
      9 main()
     10 {
     11 	if (a[0].v != 1)
     12 		return 1;
     13 	if (a[0].sub[0] != 2)
     14 		return 2;
     15 	if (a[0].sub[1] != 3)
     16 		return 3;
     17 	
     18 	return 0;
     19 }