This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 114a. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.

2024-04-18


2468. Omission of the typename keyword in a member template parameter list

Section: 13.8.1  [temp.res.general]     Status: drafting     Submitter: Mark Hall     Date: 2020-12-03

According to 13.8.2 [temp.local] paragraph 5,

A qualified-id is assumed to name a type if

This specification would appear to allow an example like:

   template<typename T> struct Y {};
   template<typename T> struct S {
     Y<int(T::type)> m;  // Omitted typename okay because it is in a member-declaration?
  };

The affected parameter-declarations should be only those of the member declarator, not in a member template's template parameter list.

(Note: this issue was spun off from issue 2462 to allow the resolutions to proceed independently.)