Skip to content

[temp.class.spec.match] Strengthen wording for matching partial specializations #3922

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions source/templates.tex
Original file line number Diff line number Diff line change
Expand Up @@ -3393,11 +3393,13 @@
\end{itemize}

\pnum
A partial specialization matches a given actual template argument
list if the template arguments of the partial specialization can be
deduced from the actual template argument list\iref{temp.deduct},
and the deduced template arguments satisfy the associated constraints
A class template partial specialization \defnx{matches}{specialization!matches}
the template argument list of a class template specialization \tcode{A} if, given the type \tcode{P}
formed by the \grammarterm{simple-template-id} of the partial specialization,
template argument deduction\iref{temp.deduct.type} for \tcode{P} from \tcode{A} would succeed
and the deduced template arguments would satisfy the associated constraints
Comment on lines +3399 to +3400
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
template argument deduction\iref{temp.deduct.type} for \tcode{P} from \tcode{A} would succeed
and the deduced template arguments would satisfy the associated constraints
template argument deduction\iref{temp.deduct.type} for \tcode{P} from \tcode{A} succeeds
and the deduced template arguments satisfy the associated constraints

No need for the hypothetical here.

of the partial specialization, if any\iref{temp.constr.decl}.

\begin{example}
\begin{codeblock}
template<class T1, class T2, int I> class A { }; // \#1
Expand Down