This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/23823] Is this right?
- From: "igodard at pacbell dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 11 Sep 2005 15:44:59 -0000
- Subject: [Bug c++/23823] Is this right?
- References: <20050911133359.23823.igodard@pacbell.net>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From igodard at pacbell dot net 2005-09-11 15:44 -------
Nah, tried:
struct foo {
template<bool b>
void f();
template<typename T, bool b>
void g();
};
template<>
void foo::f<true>() {}
template<>
void foo::f<false>() {}
template<typename T, bool b>
void foo::g<T, true>() {}
template<typename T, bool b>
void foo::g<T, false>() {}
which gets me:
~/ootbc/members/src$ g++ foo.cc
foo.cc:13: error: partial specialization `g<T, true>' of function template
foo.cc:15: error: partial specialization `g<T, false>' of function template
foo.cc:15: error: redefinition of `void foo::g()'
foo.cc:13: error: `void foo::g()' previously declared here
~/ootbc/members/src$ fg
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23823