tmp/tmpbc14tegk/{from.md → to.md}
RENAMED
|
@@ -242,13 +242,15 @@ The following steps define the result of name lookup for a member name
|
|
| 242 |
|
| 243 |
The *lookup set* for `f` in `C`, called S(f,C), consists of two
|
| 244 |
component sets: the *declaration set*, a set of members named `f`; and
|
| 245 |
the *subobject set*, a set of subobjects where declarations of these
|
| 246 |
members (possibly including *using-declaration*s) were found. In the
|
| 247 |
-
declaration set, *using-declaration*s are replaced by the
|
| 248 |
-
|
| 249 |
-
|
|
|
|
|
|
|
| 250 |
|
| 251 |
If `C` contains a declaration of the name `f`, the declaration set
|
| 252 |
contains every declaration of `f` declared in `C` that satisfies the
|
| 253 |
requirements of the language construct in which the lookup occurs.
|
| 254 |
Looking up a name in an *elaborated-type-specifier* (
|
|
@@ -552,16 +554,16 @@ the following criteria:
|
|
| 552 |
- both pointers or references have the same cv-qualification and the
|
| 553 |
class type in the return type of `D::f` has the same cv-qualification
|
| 554 |
as or less cv-qualification than the class type in the return type of
|
| 555 |
`B::f`.
|
| 556 |
|
| 557 |
-
If the
|
| 558 |
-
class type in the return type of `D::f` shall be
|
| 559 |
-
of declaration of `D::f` or shall be the class
|
| 560 |
-
overriding function is called as the final overrider
|
| 561 |
-
function, its result is converted to the type returned
|
| 562 |
-
(statically chosen) overridden function ([[expr.call]]).
|
| 563 |
|
| 564 |
``` cpp
|
| 565 |
class B { };
|
| 566 |
class D : private B { friend class Derived; };
|
| 567 |
struct Base {
|
|
|
|
| 242 |
|
| 243 |
The *lookup set* for `f` in `C`, called S(f,C), consists of two
|
| 244 |
component sets: the *declaration set*, a set of members named `f`; and
|
| 245 |
the *subobject set*, a set of subobjects where declarations of these
|
| 246 |
members (possibly including *using-declaration*s) were found. In the
|
| 247 |
+
declaration set, *using-declaration*s are replaced by the set of
|
| 248 |
+
designated members that are not hidden or overridden by members of the
|
| 249 |
+
derived class ([[namespace.udecl]]), and type declarations (including
|
| 250 |
+
injected-class-names) are replaced by the types they designate. S(f,C)
|
| 251 |
+
is calculated as follows:
|
| 252 |
|
| 253 |
If `C` contains a declaration of the name `f`, the declaration set
|
| 254 |
contains every declaration of `f` declared in `C` that satisfies the
|
| 255 |
requirements of the language construct in which the lookup occurs.
|
| 256 |
Looking up a name in an *elaborated-type-specifier* (
|
|
|
|
| 554 |
- both pointers or references have the same cv-qualification and the
|
| 555 |
class type in the return type of `D::f` has the same cv-qualification
|
| 556 |
as or less cv-qualification than the class type in the return type of
|
| 557 |
`B::f`.
|
| 558 |
|
| 559 |
+
If the class type in the covariant return type of `D::f` differs from
|
| 560 |
+
that of `B::f`, the class type in the return type of `D::f` shall be
|
| 561 |
+
complete at the point of declaration of `D::f` or shall be the class
|
| 562 |
+
type `D`. When the overriding function is called as the final overrider
|
| 563 |
+
of the overridden function, its result is converted to the type returned
|
| 564 |
+
by the (statically chosen) overridden function ([[expr.call]]).
|
| 565 |
|
| 566 |
``` cpp
|
| 567 |
class B { };
|
| 568 |
class D : private B { friend class Derived; };
|
| 569 |
struct Base {
|