From Jason Turner

[class.derived]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpbc14tegk/{from.md → to.md} +11 -9
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 members they
248
- designate, and type declarations (including injected-class-names) are
249
- replaced by the types they designate. S(f,C) is calculated as follows:
 
 
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 return type of `D::f` differs from the return type of `B::f`, the
558
- class type in the return type of `D::f` shall be complete at the point
559
- of declaration of `D::f` or shall be the class type `D`. When the
560
- overriding function is called as the final overrider of the overridden
561
- function, its result is converted to the type returned by the
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 {