This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/36645] New: Friend class template declaration does not check for matching template parameters
- From: "jhs at edg dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 26 Jun 2008 20:51:20 -0000
- Subject: [Bug c++/36645] New: Friend class template declaration does not check for matching template parameters
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The friend declaration should be rejected because the template parameter list
does not match the template definition in __detail. If the friend declaration
appears in the same namespace as the original template and does not use a
qualified name, the expected error is issued.
namespace __detail
{
template<typename _Key, typename _Value, typename _Ex, bool __unique,
typename _Hashtable> struct _Map_base { };
}
struct _Hashtable
{
template<typename _Key2, typename _Pair, typename _Hashtable>
friend struct __detail::_Map_base;
};
--
Summary: Friend class template declaration does not check for
matching template parameters
Product: gcc
Version: 4.2.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: jhs at edg dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36645