xref: /freebsd/contrib/netbsd-tests/usr.bin/xlint/lint1/d_compound_literals2.c (revision c66ec88fed842fbaad62c30d510644ceb7bd2d71)
1 /* compound literals */
2 
3 struct p {
4 	short a, b, c, d;
5 } zz = {
6 	1, 2, 3, 4
7 };
8 
9 struct p *bar(int i)
10 {
11 	static struct p q[10];
12 	return &q[i];
13 }
14 
15 foo()
16 {
17 	*bar(1) = (struct p) { 1, 2, 3, 4 };
18 }
19