[Bug c++/17080] internal compiler error on template class in template class;

reichelt at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Wed Aug 18 12:57:00 GMT 2004


------- Additional Comments From reichelt at gcc dot gnu dot org  2004-08-18 12:57 -------
Your code is invalid. You should write

template <class U>
class Collection : public SubClass<CollectionServices<U>::template CoreService>

instead of 

template <class U>
class Collection : public SubClass<CollectionServices<U>::CoreService>

The code then compiles fine (since gcc 3.1).

The ICE for the invalid code was fixed in gcc 3.4.0,
and since it's not a regression I'm closing the PR.

(I'm sure it's a duplicate of some other PR, but I can't find which one.)


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |reichelt at gcc dot gnu dot
                   |                            |org
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |3.4.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17080



More information about the Gcc-bugs mailing list