URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.old-deja/] [g++.pt/] [friend3.C] - Rev 716
Go to most recent revision | Compare with Previous | Blame | View Log
// { dg-do assemble }
template <class T>
void f(T);
class C
{
friend void f<>(double);
int i; // { dg-error "" } private
};
template <class T>
void f(T)
{
C c;
c.i = 3; // { dg-error "" } f<double> is a friend, this is f<int>.
}
int main()
{
f(7);
}
Go to most recent revision | Compare with Previous | Blame | View Log