summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.pt/crash28.C
blob: 2cfed93084de9e60390bb6570674f38712a0e3b4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// { dg-do assemble  }
// { dg-options "" }

template <class ARRY>
inline unsigned int asize(ARRY &a) // { dg-message "note" }
{
  return sizeof(a) / sizeof(a[0]);
}

void f(unsigned int n) {
  int x[n];

  asize(x); // { dg-error "" } no matching function
  // { dg-message "candidate" "candidate note" { target *-*-* } 13 }
}