PR c++/86728 - C variadic generic lambda.
[official-gcc.git] / gcc / testsuite / g++.dg / abi / abi-tag3.C
blob13cb3c2f2e91a2697b61421963a4c7a19574a97c
1 // An explicit specialization gets the tag from its template.
3 // { dg-final { scan-assembler "_ZN3FooB5cxx11IcE1fEv" } }
4 template<typename T>
5 struct __attribute ((abi_tag("cxx11"))) Foo
7   int f();
8 };
10 // { dg-final { scan-assembler "_ZN3FooB5cxx11IiE1fEv" } }
11 template<>
12 struct
13 __attribute ((abi_tag("cxx11")))
14 Foo<int>                        // { dg-warning "attribute" }
16   int f();
19 // { dg-final { scan-assembler "_ZN3FooB5cxx11IdE1fEv" } }
20 template<>
21 struct
22 Foo<double>
24   int f();
27 int main()
29   Foo<int> f;
30   f.f();
31   Foo<char> f1;
32   f1.f();
33   Foo<double> f2;
34   f2.f();