summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/template/crash97.C
blob: 3d177f4e53412ffb74bba5a706bd858028e4c1fa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// PR c++/34272

template<typename> struct A {};

template<typename> struct A<int> // { dg-error "not used|template\\-parameter" }
{
  template<int> void foo();
};

void bar()
{
  A<int> a; // { dg-error "incomplete type" }
  a.foo<0>(); // { dg-error "expected" }
}