summaryrefslogtreecommitdiffstats
path: root/contrib/netbsd-tests/usr.bin/xlint/lint1/d_c99_anon_struct.c
blob: 367b56fa1a851d2d43d93a0ce1ba4dd26f4476f2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/* Anonymous struct test */

typedef int type;

struct point {
	int x;
	int y;
};

struct bar {
	struct {
		struct point top_left;
		struct point bottom_right;
	};
	type z;
};


int
main(void)
{
	struct bar b;
	b.top_left.x = 1;
	return 0;
}
	
OpenPOWER on IntegriCloud