* template1.C: New test.
[gcc.git] / gcc / testsuite / g++.old-deja / g++.oliva / template1.C
1 // Build don't link:
2
3 // by Alexandre Oliva <oliva@dcc.unicamp.br>
4 // based on bug report by Stefan Wetzel <Stefan_Wetzel@Physik.TU-Muenchen.DE>
5
6 // crash test - XFAIL *-*-*
7
8 template<int P = 0> struct foo {
9 static void bar(double (*)[dim]) {} // ERROR - dim not declared
10 };
11
12 void bar() {
13 foo<>::bar(0); // ERROR - instantiated from here
14 }