annotate gcc/testsuite/gcc.dg/uninit-14-O0.c @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* PR 24931 */
kono
parents:
diff changeset
2 /* { dg-do compile } */
kono
parents:
diff changeset
3 /* { dg-options "-Wuninitialized" } */
kono
parents:
diff changeset
4
kono
parents:
diff changeset
5 struct p {
kono
parents:
diff changeset
6 short x, y;
kono
parents:
diff changeset
7 };
kono
parents:
diff changeset
8
kono
parents:
diff changeset
9 struct s {
kono
parents:
diff changeset
10 int i;
kono
parents:
diff changeset
11 struct p p;
kono
parents:
diff changeset
12 };
kono
parents:
diff changeset
13
kono
parents:
diff changeset
14 struct s f()
kono
parents:
diff changeset
15 {
kono
parents:
diff changeset
16 struct s s;
kono
parents:
diff changeset
17 s.p = (struct p){};
kono
parents:
diff changeset
18 s.i = (s.p.x || s.p.y);
kono
parents:
diff changeset
19 return s;
kono
parents:
diff changeset
20 }