URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc3/] [gcc/] [testsuite/] [g++.dg/] [template/] [error42.C] - Rev 516
Compare with Previous | Blame | View Log
// PR c++/40372
// { dg-do compile }
template <int> struct A
{
int i; // { dg-error "invalid use of non-static data member" }
friend void foo ()
{
int x[i]; // { dg-error "from this location" }
}
};
struct B
{
int j; // { dg-error "invalid use of non-static data member" }
friend int bar ()
{
return j; // { dg-error "from this location" }
}
};