This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/20174] New: rejects valid partial template function specialization
- From: "sstrasser at systemhaus-gruppe dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 23 Feb 2005 17:56:59 -0000
- Subject: [Bug c++/20174] New: rejects valid partial template function specialization
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
...and I have another one, this is gcc bug finding day.
it's again related to partial template function specializations, but I open a
new report because this time it is rejects-valid:
(at least I think so)
template<typename AT>
struct A{
template<typename T>
void function(){}
};
template<>
template<typename TTT>
void A<int>::function<TTT>(){}
error: partial specialization `function<TTT>' of function template
that's right, but why is this an error?
if function has a parameter of type T, so you can specialize it without
explicitly giving a template parameter, it works.
(...::function(TTT){})
Comeau accepts both.
--
Summary: rejects valid partial template function specialization
Product: gcc
Version: 3.4.4
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: sstrasser at systemhaus-gruppe dot de
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20174