Debian Codegraph @

gcc/testsuite/g++.dg/abi/abi-tag24.C

raw
1 // PR c++/98481
2 // { dg-do compile { target c++11 } }
3 inline namespace N __attribute ((__abi_tag__ ("myabi")))
4 {
5 struct A {};
6 }
7 template <typename T>
8 struct B { typedef int size_type; };
9 struct S1 { B<A>::size_type foo () const { return 1; } };
10 struct S2 { B<A>::size_type foo () const; };
11 int S2::foo () const { return 2; }
12 int (S1::*f1) () const = &S1::foo;
13 int (S2::*f2) () const = &S2::foo;
14
15 // { dg-final { scan-assembler "_ZNK2S13fooEv" } }
16 // { dg-final { scan-assembler "_ZNK2S23fooEv" } }
17 // { dg-final { scan-assembler-not "_ZNK2S13fooB5myabiEv" } }