source:
CIVL/examples/languageFeatures/compoundInit2.c
| Last change on this file was 8ed8eba, checked in by , 3 years ago | |
|---|---|
|
|
| File size: 134 bytes | |
| Line | |
|---|---|
| 1 | #include <assert.h> |
| 2 | struct Node { |
| 3 | int x, y; |
| 4 | }; |
| 5 | int main() { |
| 6 | struct Node node = { 1 }; |
| 7 | assert(node.x==1); |
| 8 | assert(node.y==0); |
| 9 | } |
Note:
See TracBrowser
for help on using the repository browser.
