This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/29615] Class can't be friends of itself?



------- Comment #4 from potswa at mac dot com  2010-03-26 21:08 -------
The error doesn't occur if the friend is a template instance, so it really
doesn't hurt anyone. But it's weird.

template< int z >
class F {
    friend class F<0>; // error only if <0> removed
};

template class F<0>;


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29615


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]