3 // Origin: Steven Bosscher <steven@gcc.gnu.org>
4 // Serge Belyshev <belyshev@lubercy.com>
6 // PR c++/18825: ICE member as friend
8 template<class T> class A
10 void f (); // { dg-error "private" }
13 template<class T> class B
15 friend void A<T>::f (); // { dg-error "this context" }
20 B<int> b; // { dg-error "instantiated" }