Skip to content

Rebase Motion 5 #4395

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

Merged
merged 4 commits into from
Nov 28, 2020
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion source/basic.tex
Original file line number Diff line number Diff line change
Expand Up @@ -2654,7 +2654,7 @@
\end{itemize}
\begin{note}
There are other circumstances in which declarations declare the same entity
(\ref{dcl.link}, \ref{temp.type}, \ref{temp.class.spec}).
(\ref{dcl.link}, \ref{temp.type}, \ref{temp.spec.partial}).
\end{note}

\pnum
Expand Down
4 changes: 2 additions & 2 deletions source/classes.tex
Original file line number Diff line number Diff line change
Expand Up @@ -4423,7 +4423,7 @@

\pnum
\begin{note}
A member of a private base class might be inaccessible as inherited,
A member of a private base class can be inaccessible as inherited,
but accessible directly.
Because of the rules on pointer conversions\iref{conv.ptr} and
explicit casts~(\ref{expr.type.conv}, \ref{expr.static.cast}, \ref{expr.cast}),
Expand Down Expand Up @@ -6755,7 +6755,7 @@

\pnum
Access to the deallocation function is checked statically,
even though a different one might actually be executed.
even if a different one is actually executed.
\begin{example}
For the call on line ``// 1'' above,
if
Expand Down
7 changes: 4 additions & 3 deletions source/declarations.tex
Original file line number Diff line number Diff line change
Expand Up @@ -4687,7 +4687,7 @@
this is the defining declaration\iref{basic.def} of the variable,
but the initializing declaration
of a non-inline static data member\iref{class.static.data}
might be the declaration within the class definition
can be the declaration within the class definition
and not the definition (if any) outside it.
\end{note}

Expand Down Expand Up @@ -6660,7 +6660,7 @@
that is a function template whose first template parameter
is a non-type parameter,
the initializer is
\tcode{\exposid{e}.get<i>()}. Otherwise, the initializer is \tcode{get<i>(\exposid{e})},
\tcode{\exposidnc{e}.get<i>()}. Otherwise, the initializer is \tcode{get<i>(\exposid{e})},
where \tcode{get} undergoes argument-dependent lookup\iref{basic.lookup.argdep}.
In either case, \tcode{get<i>} is interpreted as a \grammarterm{template-id}.
\begin{note}
Expand Down Expand Up @@ -8090,7 +8090,8 @@
\indextext{class!linkage specification}%
A C language linkage is ignored
in determining the language linkage of
class members and the
class members,
friend functions with a trailing \grammarterm{requires-clause}, and the
function type of class member functions.
\begin{example}
\begin{codeblock}
Expand Down
4 changes: 2 additions & 2 deletions source/expressions.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1560,7 +1560,7 @@
$H$ shall be equivalent to
the \grammarterm{template-head} of $T$\iref{temp.over.link}.
\item
Otherwise, $N$ nominates the partial specialization\iref{temp.class.spec} of $T$
Otherwise, $N$ nominates the partial specialization\iref{temp.spec.partial} of $T$
whose template argument list is equivalent to $A$\iref{temp.over.link};
the program is ill-formed if no such partial specialization exists.
\end{itemize}
Expand Down Expand Up @@ -4368,7 +4368,7 @@
The address of an overload set\iref{over} can be taken
only in a context that uniquely determines
which function is referred to (see~\ref{over.over}).
Since the context might determine whether the operand is a static or
Since the context can affect whether the operand is a static or
non-static member function, the context can also affect whether the
expression has type ``pointer to function'' or ``pointer to member
function''.
Expand Down
34 changes: 16 additions & 18 deletions source/templates.tex
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,8 @@
In a function template declaration, the \grammarterm{unqualified-id} of the
\grammarterm{declarator-id} shall be a name.
\begin{note}
In a class template declaration, if the \grammarterm{class-name}
In a class or variable template declaration, if the
declared name
is a
\grammarterm{simple-template-id},
the declaration declares a partial specialization\iref{temp.spec.partial}.
Expand All @@ -135,8 +136,8 @@
\indextext{template name!linkage of}%
A specialization (explicit or implicit) of one template is
distinct from all specializations of any other template.
A template, a template explicit specialization\iref{temp.expl.spec}, and a class
template partial specialization shall not have C language linkage.
A template, an explicit specialization\iref{temp.expl.spec}, and a
partial specialization shall not have C language linkage.
\begin{note}
Default arguments for function templates and for member functions of
class templates are considered definitions for the purpose of template
Expand All @@ -149,7 +150,7 @@
name bound in the same scope\iref{basic.scope.scope}, except
that a function template can share a name with non-template
functions\iref{dcl.fct} and/or function templates\iref{temp.over}.
Specializations, including partial specializations\iref{temp.class.spec},
Specializations, including partial specializations\iref{temp.spec.partial},
do not reintroduce or bind names.
Their target scope is the target scope of the primary template,
so all specializations of a template belong to the same scope as it does.
Expand Down Expand Up @@ -2161,7 +2162,7 @@
A template declaration in which the name of the template is followed by
a \grammarterm{template-argument-list} is
a partial specialization of
the template named in the declaration\iref{temp.class.spec}.
the template named in the declaration\iref{temp.spec.partial}.

\pnum
For purposes of name lookup and instantiation,
Expand Down Expand Up @@ -3129,23 +3130,21 @@

\pnum
\indextext{specialization!class template partial}%
A partial specialization of a class template provides an alternative definition
A partial specialization of a template provides an alternative definition
of the template that is used instead of the primary definition when the
arguments in a specialization match those given in the partial
specialization\iref{temp.class.spec.match}.
specialization\iref{temp.spec.partial.match}.
A declaration of the primary template shall precede any specialization of
that template.
A partial specialization shall be reachable from any use of a class template
A partial specialization shall be reachable from any use of a template
specialization that would make use of the partial specialization as the result of
an implicit or explicit instantiation; no diagnostic is required.

\pnum
Two partial specialization declarations declare the same entity
if they are partial specializations of the same template and have equivalent
\grammarterm{template-head}s and template argument lists\iref{temp.over.link}.
Each class template partial specialization is a distinct template and
definitions shall be provided for the members of a template partial
specialization\iref{temp.class.spec.mfunc}.
Each partial specialization is a distinct template.

\pnum
\begin{example}
Expand Down Expand Up @@ -3181,10 +3180,10 @@
\end{example}

\pnum
The template parameters are specified in the angle bracket enclosed list
The template parameters of a template are specified in the angle bracket enclosed list
that immediately follows the keyword \keyword{template}.
The template argument list of a partial specialization is
the \grammarterm{template-argument-list} of the \grammarterm{ class-name}.
the \grammarterm{template-argument-list} of the \grammarterm{class-name}.

\pnum
A partial specialization may be declared in any
Expand Down Expand Up @@ -3452,7 +3451,6 @@
\rSec3[temp.spec.partial.member]{Members of class template partial specializations}

\pnum
A class template partial specialization is a distinct template.
The members of the class template partial specialization are
unrelated to the members of the primary template.
Class template partial specialization members that are used in a way that
Expand Down Expand Up @@ -4789,10 +4787,10 @@
the name of the nested class referenced as a member of the
current instantiation, or
\item
in the definition of a partial specialization
or a member of a partial specialization, the name of
in the definition of a class template partial specialization
or a member of a class template partial specialization, the name of
the class template followed by a template argument list
equivalent to that of the partial specialization\iref{temp.class.spec}
equivalent to that of the partial specialization\iref{temp.spec.partial}
enclosed in \tcode{<>} (or an equivalent template alias specialization).
\end{itemize}

Expand Down Expand Up @@ -5724,7 +5722,7 @@
}
\end{codeblock}
\end{example}
If the template selected for the specialization\iref{temp.class.spec.match}
If the template selected for the specialization\iref{temp.spec.partial.match}
has been declared, but not defined,
at the point of instantiation\iref{temp.point},
the instantiation yields an incomplete class type\iref{basic.types}.
Expand Down