summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp0x/explicit11.C
blob: 06d607f1a98c529d6464cf5d07b863c3ec988d46 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// Test that we treat defaulted-in-class members like implicitly declared
// members for explicit instantiation.

// { dg-do compile { target c++11 } }

template<typename T>
struct A
{
  T x;
  A() = default;
  A(const A &other) = default;
  A& operator=(const A&) = default;
};

template class A<int>;

// { dg-final { scan-assembler-not "_ZN1AIiEC1Ev" } }
// { dg-final { scan-assembler-not "_ZN1AIiEC1ERKS0_" } }
// { dg-final { scan-assembler-not "_ZN1AIiEaSERKS0_" } }