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

--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
The key here is:
https://timsong-cpp.github.io/cppwp/n4868/temp.names#4.sentence-4

Which says:
In these contexts, a < token is always assumed to introduce a
template-argument-list.

The context reffered to here is "typename-specifier ([temp.res]),
elaborated-type-specifier ([dcl.type.elab]), using-declaration
([namespace.udecl]), or class-or-decltype ([class.derived])" .

In case of comment #0, the context is a class-or-decltype context.

So yes this is invalid.

Reply via email to