This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/29767] partial specialization enclosed templates within the declaration of the enclosed class.
- From: "bangerth at dealii dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Nov 2006 05:35:30 -0000
- Subject: [Bug c++/29767] partial specialization enclosed templates within the declaration of the enclosed class.
- References: <bug-29767-7667@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #7 from bangerth at dealii dot org 2006-11-09 05:35 -------
(In reply to comment #0)
> gcc and msvc accept such code but produces different results.
> is this code (in)valid? i'm not sure what behaviour is correct.
The code is valid because it is a *partial* specialization of the member
template class. It would be invalid if it were a *complete* specialization.
In that case, the complete specialization would have to be declared outside
the outer class, i.e. at namespace scope.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29767