https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55639

Jason Merrill <jason at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED
   Target Milestone|---                         |8.0

--- Comment #5 from Jason Merrill <jason at gcc dot gnu.org> ---
(In reply to Paolo Carlini from comment #1)
> The issue is the 'template' keyword in:
> 
> SomeClass<number>::template Fun<E, 0>

Indeed, the keyword is not allowed in a class-head-name:

The keyword template is said to appear at the top level in a qualified-id if it
appears outside of a template-argument-list or decltype-specifier. In a
qualified-id of a declarator-id or in a qualified-id formed by a
class-head-name or enum-head-name, the keyword template shall not appear at the
top level.

For GCC 8, I've fixed G++ to accept it with a pedwarn.

Reply via email to