annotate gcc/testsuite/gcc.dg/pr17188-1.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 /* A redefinition of an empty struct should be diagnosed the same as a
kono
parents:
diff changeset
2 redefinition of any other tag, but formerly only s2 and s4 were
kono
parents:
diff changeset
3 diagnosed. Bug 17188. */
kono
parents:
diff changeset
4 /* Origin: Joseph Myers <jsm@polyomino.org.uk> */
kono
parents:
diff changeset
5 /* { dg-do compile } */
kono
parents:
diff changeset
6 /* { dg-options "" } */
kono
parents:
diff changeset
7
kono
parents:
diff changeset
8 struct s0 { }; /* { dg-message "note: originally defined here" } */
kono
parents:
diff changeset
9 struct s0;
kono
parents:
diff changeset
10 struct s0 { }; /* { dg-error "redefinition of 'struct s0'" } */
kono
parents:
diff changeset
11
kono
parents:
diff changeset
12 struct s1 { }; /* { dg-message "note: originally defined here" } */
kono
parents:
diff changeset
13 struct s1 { }; /* { dg-error "redefinition of 'struct s1'" } */
kono
parents:
diff changeset
14
kono
parents:
diff changeset
15 struct s2 { int a : 1; }; /* { dg-message "note: originally defined here" } */
kono
parents:
diff changeset
16 struct s2 { int a : 1; }; /* { dg-error "redefinition of 'struct s2'" } */
kono
parents:
diff changeset
17
kono
parents:
diff changeset
18 struct s3 { }; /* { dg-message "note: originally defined here" } */
kono
parents:
diff changeset
19 struct s3 { int a : 1; }; /* { dg-error "redefinition of 'struct s3'" } */
kono
parents:
diff changeset
20
kono
parents:
diff changeset
21 struct s4 { int a : 1; }; /* { dg-message "note: originally defined here" } */
kono
parents:
diff changeset
22 struct s4 { }; /* { dg-error "redefinition of 'struct s4'" } */
kono
parents:
diff changeset
23
kono
parents:
diff changeset
24 struct s5 { int a : 1; };
kono
parents:
diff changeset
25 struct s5;
kono
parents:
diff changeset
26
kono
parents:
diff changeset
27 struct s6;
kono
parents:
diff changeset
28 struct s6 { int a : 1; };
kono
parents:
diff changeset
29
kono
parents:
diff changeset
30 struct s7;
kono
parents:
diff changeset
31 struct s7 { };