testsuite: suppress mangling compatibility aliases
[official-gcc.git] / gcc / testsuite / g++.dg / abi / mangle48.C
blob3f86c516d13d2952e3eb0ad5c766c384dcfc51cc
1 // Testcase for 'this' mangling
2 // { dg-do compile { target c++11 } }
3 // { dg-additional-options -fabi-compat-version=0 }
5 struct B
7   template <class U> U f();
8 };
10 struct A
12   B b;
13   // { dg-final { scan-assembler "_ZN1A1fIiEEDTcldtdtdefpT1b1fIT_EEEv" } }
14   template <class U> auto f() -> decltype (b.f<U>());
15   // { dg-final { scan-assembler "_ZN1A1gIiEEDTcldtptfpT1b1fIT_EEEv" } }
16   template <class U> auto g() -> decltype (this->b.f<U>());
17   // { dg-final { scan-assembler "_ZN1A1hIiEEDTcldtdtdefpT1bsr1B1fIT_EEEv" } }
18   template <class U> auto h() -> decltype (b.B::f<U>());
19   // { dg-final { scan-assembler "_ZN1A1iIiEEDTcldtptfpT1bsr1B1fIT_EEEv" } }
20   template <class U> auto i() -> decltype (this->b.B::f<U>());
23 int main()
25   A a;
26   a.f<int>();
27   a.g<int>();
28   a.h<int>();
29   a.i<int>();