tmp/tmp_opzbkqo/{from.md → to.md}
RENAMED
|
@@ -112,16 +112,16 @@ the following criteria:
|
|
| 112 |
- both pointers or references have the same cv-qualification and the
|
| 113 |
class type in the return type of `D::f` has the same cv-qualification
|
| 114 |
as or less cv-qualification than the class type in the return type of
|
| 115 |
`B::f`.
|
| 116 |
|
| 117 |
-
If the
|
| 118 |
-
class type in the return type of `D::f` shall be
|
| 119 |
-
of declaration of `D::f` or shall be the class
|
| 120 |
-
overriding function is called as the final overrider
|
| 121 |
-
function, its result is converted to the type returned
|
| 122 |
-
(statically chosen) overridden function ([[expr.call]]).
|
| 123 |
|
| 124 |
``` cpp
|
| 125 |
class B { };
|
| 126 |
class D : private B { friend class Derived; };
|
| 127 |
struct Base {
|
|
|
|
| 112 |
- both pointers or references have the same cv-qualification and the
|
| 113 |
class type in the return type of `D::f` has the same cv-qualification
|
| 114 |
as or less cv-qualification than the class type in the return type of
|
| 115 |
`B::f`.
|
| 116 |
|
| 117 |
+
If the class type in the covariant return type of `D::f` differs from
|
| 118 |
+
that of `B::f`, the class type in the return type of `D::f` shall be
|
| 119 |
+
complete at the point of declaration of `D::f` or shall be the class
|
| 120 |
+
type `D`. When the overriding function is called as the final overrider
|
| 121 |
+
of the overridden function, its result is converted to the type returned
|
| 122 |
+
by the (statically chosen) overridden function ([[expr.call]]).
|
| 123 |
|
| 124 |
``` cpp
|
| 125 |
class B { };
|
| 126 |
class D : private B { friend class Derived; };
|
| 127 |
struct Base {
|