Skip to content

Commit ab97a5a

Browse files
committed
[namespace.udecl] Demote normative duplication to notes
The effects of using-declarations naming member functions are discussed in other parts of the standard. The effects of initializing with an inherited constructor are discussed elsewhere, too.
1 parent 7066a90 commit ab97a5a

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

source/declarations.tex

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3017,25 +3017,29 @@
30173017

30183018
\pnum
30193019
\indextext{overloading!using-declaration and}%
3020+
\begin{note}
30203021
For the purpose of forming a set of candidates during overload resolution,
30213022
the functions that are
30223023
introduced by a \grammarterm{using-declaration} into a derived class
3023-
are treated as though they were members of the derived class. In
3024-
particular, the implicit \tcode{this} parameter shall be treated as if
3025-
it were a pointer to the derived class rather than to the base class.
3024+
are treated as though they were members of the derived class\iref{class.member.lookup}. In
3025+
particular, the implicit object parameter is treated as if
3026+
it were a reference to the derived class rather than to the base class\iref{over.match.funcs}.
30263027
This has no effect on the type of the function, and in all other
30273028
respects the function remains a member of the base class.
3028-
Likewise, constructors that are introduced by a \grammarterm{using-declaration}
3029+
A member of a derived class is sometimes preferred to a member of a base class
3030+
if they would otherwise be ambiguous\iref{over.match.best}.
3031+
\end{note}
3032+
3033+
\pnum
3034+
Constructors that are introduced by a \grammarterm{using-declaration}
30293035
are treated as though they were constructors of the derived class
30303036
when looking up the constructors of the derived class\iref{class.qual}
30313037
or forming a set of overload candidates~(\ref{over.match.ctor}, \ref{over.match.copy}, \ref{over.match.list}).
3038+
\begin{note}
30323039
If such a constructor is selected to perform the initialization
30333040
of an object of class type, all subobjects other than the base class
30343041
from which the constructor originated
30353042
are implicitly initialized\iref{class.inhctor.init}.
3036-
\begin{note}
3037-
A member of a derived class is sometimes preferred to a member of a base class
3038-
if they would otherwise be ambiguous\iref{over.match.best}.
30393043
\end{note}
30403044

30413045
\pnum

0 commit comments

Comments
 (0)