The paragraph that allowes place holder for deduced class type in template parameter is [dcl.type.class.deduc]/§2

>A placeholder for a deduced class type can also be used in the type-specifier-seq in the new-type-id or type-id of a new-expression, as the simple-type-specifier in an explicit type conversion (functional notation), or as the type-specifier in the parameter-declaration of a template-parameter.

I had not read non normative "Notes", and apparently the behavior seems to be recognize by the standard [temp.func.order]/§3

The type replacing the placeholder in the type of the value synthesized for a non-type template parameter is also a unique synthesized type.
 — end note]

This is a frustrating limitation because at least it makes impossible to partially specialize any class template with a non-type template parameter that uses a placeholder for deduced class type. Should not this be changed?

Le lun. 3 août 2020 à 00:44, Ville Voutilainen via Std-Discussion <> a écrit :
On Mon, 3 Aug 2020 at 01:33, Jason McKesson via Std-Discussion
<> wrote:
> On Sun, Aug 2, 2020 at 2:30 PM Olivier Kannengieser via Std-Discussion
> <> wrote:
> >
> > No this is what I meant. 'A x' is a C++20 feature: place holder for deduced class type for the declaration of non type template parameter.
> No, "place holder for deduced class type for the declaration of non
> type template parameter" is the C++17 feature that allows `auto x` to
> work in template arguments. A template name by itself is not a
> placeholder.
> C++20 allows `ConceptName auto x`, which does the above except with a
> concept constraint as to `x`'s type.
> At no point does C++ permit `TemplateName x` to work in a template
> parameter list. There were some Concept ideas that `TemplateName<auto>
> x` might work, and maybe Concepts TS allowed you to drop the argument.
> But C++20 does not.

I'm not sure what you mean by "TemplateName x", but this certainly does work:

template <class T> concept foo = /* whatever */;

template <foo T> void f(); // or struct, class, etc.

That foo is probably not what you mean by TemplateName, because it's a
Std-Discussion mailing list