This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/8355] befriending a template specialization in another namespace
- From: "gianni at mariani dot ws" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 1 Oct 2004 17:46:45 -0000
- Subject: [Bug c++/8355] befriending a template specialization in another namespace
- References: <20021025084602.8355.zach@cs.uni-bonn.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From gianni at mariani dot ws 2004-10-01 17:46 -------
gcc 3.4.2 complains about this as well:
namespace A {
template <typename T>
void func ()
{
static T instance;
}
}
namespace blah {
class MyClass {
friend void A::func<MyClass> ();
MyClass () {} // private
};
}
int main ()
{
A::func<blah::MyClass>();
}
friend_test.cpp:15: error: `void A::func()' should have been declared inside `A'
I suspect this is the same bug ?
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |gianni at mariani dot ws
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=8355