URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [parse/] [template25.C] - Rev 704
Go to most recent revision | Compare with Previous | Blame | View Log
// PR c++/22318. Improve diagnostic for local template declaration.
// { dg-do compile }
void f(void)
{
template<typename T> class A /* { dg-error "a template declaration cannot appear at block scope" } */
{
};
}
void g(void)
{
template f<int>(); /* { dg-error "expected primary-expression" } */
/* { dg-error "expected ';'" "" { target *-*-* } 12 } */
}
Go to most recent revision | Compare with Previous | Blame | View Log