C++, 2.95: Maybe bug with nested template specialization (variant)
Alexandre Oliva
oliva@dcc.unicamp.br
Tue Aug 31 22:45:00 GMT 1999
On Aug 12, 1999, Wolfgang Bangerth <wolf@gaia.iwr.uni-heidelberg.de> wrote:
> // this is something for which I have no clue what the compiler
> // explains about:
First, you can't specialize in non-namespace scope, as I explained in
my previous message.
But then, moving the template out of X gets you:
template <class Y> template <> class X<Y>::T<1> { int i1; };
This is not valid, because you can only specialize template-members of
full specializations of a template. I.e., you can do:
template <> template <> class X<some_type>::T<1> ...
because X<some_type> is fully specialized.
--
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
oliva@{dcc.unicamp.br,guarana.{org,com}} aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
** I may forward mail about projects to mailing lists; please use them
More information about the Gcc-bugs
mailing list