blob: 9c0cee701d758be05c2b231ef75e2a165bcc36de [file] [log] [blame]
// { dg-do assemble }
template <class T>
void f(T);
class C
{
friend void f<>(double);
int i; // { dg-message "" } 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);
}