Skip to content

Commit

Permalink
[class.temporary, expr, dcl.ref] Fix incorrect cross-references for d…
Browse files Browse the repository at this point in the history
…ecltype (cplusplus#3918)
  • Loading branch information
sdkrystian authored and zygoloid committed Sep 22, 2020
1 parent a970767 commit 5c7b53e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion source/basic.tex
Original file line number Diff line number Diff line change
Expand Up @@ -4314,7 +4314,7 @@
This includes accessibility\iref{class.access} and whether it is deleted,
for the constructor selected and for the destructor. However, in the special
case of the operand of a
\grammarterm{decltype-specifier}\iref{expr.call}, no temporary is introduced,
\grammarterm{decltype-specifier}\iref{dcl.type.decltype}, no temporary is introduced,
so the foregoing does not apply to such a prvalue.
\end{note}

Expand Down
6 changes: 3 additions & 3 deletions source/declarations.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1999,7 +1999,7 @@
\opt{\grammarterm{type-constraint}} \tcode{decltype(auto)},
\tcode{T} shall be the
placeholder alone. The type deduced for \tcode{T} is
determined as described in~\ref{dcl.type.simple}, as though
determined as described in~\ref{dcl.type.decltype}, as though
$E$ had
been the operand of the \tcode{decltype}.
\begin{example}
Expand Down Expand Up @@ -2746,7 +2746,7 @@
Cv-qualified references are ill-formed except when the cv-qualifiers
are introduced through the use of a
\grammarterm{typedef-name}~(\ref{dcl.typedef}, \ref{temp.param}) or
\grammarterm{decltype-specifier}\iref{dcl.type.simple},
\grammarterm{decltype-specifier}\iref{dcl.type.decltype},
in which case the cv-qualifiers are ignored.
\begin{example}
\begin{codeblock}
Expand Down Expand Up @@ -2873,7 +2873,7 @@
\pnum
\indextext{reference collapsing}%
If a \grammarterm{typedef-name}~(\ref{dcl.typedef}, \ref{temp.param})
or a \grammarterm{decltype-specifier}\iref{dcl.type.simple} denotes a type \tcode{TR} that
or a \grammarterm{decltype-specifier}\iref{dcl.type.decltype} denotes a type \tcode{TR} that
is a reference to a type \tcode{T}, an attempt to create the type ``lvalue reference to \cv{}~\tcode{TR}''
creates the type ``lvalue reference to \tcode{T}'', while an attempt to create
the type ``rvalue reference to \cv{}~\tcode{TR}'' creates the type \tcode{TR}.
Expand Down
4 changes: 2 additions & 2 deletions source/expressions.tex
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@
and rvalues in other significant contexts.

\pnum
Unless otherwise indicated\iref{dcl.type.simple},
Unless otherwise indicated\iref{dcl.type.decltype},
a prvalue shall always have complete type or the \tcode{void} type;
if it has a class type or (possibly multi-dimensional) array of class type,
that class shall not be an abstract class\iref{class.abstract}.
Expand Down Expand Up @@ -417,7 +417,7 @@
\ref{expr.typeid},
\ref{expr.sizeof},
\ref{expr.unary.noexcept},
\ref{dcl.type.simple},
\ref{dcl.type.decltype},
\ref{temp.pre},
\ref{temp.concept}).
An unevaluated operand is not evaluated.
Expand Down

0 comments on commit 5c7b53e

Please sign in to comment.