PATCH for friend/template/inline link-failure

Alexandre Oliva oliva@dcc.unicamp.br
Tue Sep 1 22:04:00 GMT 1998


Mark Mitchell <mark@markmitchell.com> writes:

> template <class P1> struct S1 { struct SS1 { };
>   friend void Foo (const SS1& ss1) { } };

In this case, I think Foo is a non-template function, so it must be
explicitly defined for each type S1<P1>::SS1.  A template definition
won't do.

-- 
Alexandre Oliva
mailto:oliva@dcc.unicamp.br mailto:aoliva@acm.org
http://www.dcc.unicamp.br/~oliva
Universidade Estadual de Campinas, SP, Brasil




More information about the Gcc-patches mailing list