annotate gcc/testsuite/g++.dg/ext/label13a.C @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children 84e7813d76e9
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 // PR c++/41090
kono
parents:
diff changeset
2 // { dg-do run }
kono
parents:
diff changeset
3 // { dg-options "-save-temps" }
kono
parents:
diff changeset
4 // { dg-final { scan-assembler "_ZN1CC4Ev" } }
kono
parents:
diff changeset
5
kono
parents:
diff changeset
6 int i;
kono
parents:
diff changeset
7 struct A { A() {} };
kono
parents:
diff changeset
8 struct C: virtual A
kono
parents:
diff changeset
9 {
kono
parents:
diff changeset
10 C();
kono
parents:
diff changeset
11 };
kono
parents:
diff changeset
12
kono
parents:
diff changeset
13 C::C()
kono
parents:
diff changeset
14 {
kono
parents:
diff changeset
15 static void *labelref = &&label;
kono
parents:
diff changeset
16 goto *labelref;
kono
parents:
diff changeset
17 label: i = 1;
kono
parents:
diff changeset
18 }
kono
parents:
diff changeset
19
kono
parents:
diff changeset
20 int main()
kono
parents:
diff changeset
21 {
kono
parents:
diff changeset
22 C c;
kono
parents:
diff changeset
23 return (i != 1);
kono
parents:
diff changeset
24 }