Title
Lookup for conversion-function-ids
Status
cd5
Section
7.5.4.3 [expr.prim.id.qual]
Submitter
John Spicer

Created on 2018-07-31.00:00:00 last changed 40 months ago

Messages

Date: 2019-02-15.00:00:00

Proposed resolution (February, 2019):

Change 7.5.4.3 [expr.prim.id.qual] paragraph 4 as follows:

In a qualified-id, if the unqualified-id is a conversion-function-id, its conversion-type-id shall denote the same type in both the context in which the entire qualified-id occurs and in the context of the class denoted by the nested-name-specifier is first looked up in the class denoted by the nested-name-specifier of the qualified-id and the name, if found, is used. Otherwise, it is looked up in the context in which the entire qualified-id occurs. In each of these lookups, only names that denote types or templates whose specializations are types are considered.
Date: 2019-02-15.00:00:00

[Accepted as a DR at the February, 2019 meeting.]

According to 7.5.4.3 [expr.prim.id.qual] paragraph 5,

In a qualified-id, if the unqualified-id is a conversion-function-id, its conversion-type-id shall denote the same type in both the context in which the entire qualified-id occurs and in the context of the class denoted by the nested-name-specifier.

However, _N4868_.6.5.6 [basic.lookup.classref] paragraph 7 says,

If the id-expression is a conversion-function-id, its conversion-type-id is first looked up in the class of the object expression and the name, if found, is used. Otherwise it is looked up in the context of the entire postfix-expression. In each of these lookups, only names that denote types or templates whose specializations are types are considered.

The latter was changed by issue 1111. It seems the former may have been overlooked in that change.

History
Date User Action Args
2020-12-15 00:00:00adminsetmessages: + msg6376
2018-07-31 00:00:00admincreate