0095-arrayselector.c - scc - simple c99 compiler
(HTM) git clone git://git.simple-cc.org/scc
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) Submodules
(DIR) README
(DIR) LICENSE
---
0095-arrayselector.c (216B)
---
1 int a[] = {5, [2] = 2, 3};
2
3 int
4 main()
5 {
6 if (sizeof(a) != 4*sizeof(int))
7 return 1;
8
9 if (a[0] != 5)
10 return 2;
11 if (a[1] != 0)
12 return 3;
13 if (a[2] != 2)
14 return 4;
15 if (a[3] != 3)
16 return 5;
17
18 return 0;
19 }