Debian Codegraph @

testsuite/small/inheritance-2.cpp

raw
1 /* { dg-options "-DCE_EXTRACT_FUNCTIONS=f -DCE_NO_EXTERNALIZATION" }*/
2
3 struct A {
4 int a;
5 };
6
7 struct B : public A {
8 int b;
9 };
10
11 int f(void)
12 {
13 B b;
14 return b.b;
15 }
16
17 /* { dg-final { scan-tree-dump "struct A \{" } } */
18 /* { dg-final { scan-tree-dump "struct B : public A \{" } } */
19 /* { dg-final { scan-tree-dump "b\.b" } } */