Date
2009-03-23.00:00:00
Message id
1843

Content

N2800 comment DE 5
N2800 comment DE 10
N2800 comment DE 12

There are several places in the Standard that were overlooked when reference qualification of member functions was added. For example, 7.6.1.5 [expr.ref] paragraph 4, bullet 3, sub-bullet 2 says,

...if E1.E2 refers to a non-static member function, and the type of E2 is “function of parameter-type-list cv returning T”, then...

This wording incorrectly excludes member functions declared with a ref-qualifier.

Another place that should consider reference qualification is 7.6.4 [expr.mptr.oper]; it should not be possible to invoke an &-qualified member function with an rvalue object expression.

A third place is 9.10 [namespace.udecl] paragraph 15, which does not mention reference qualification in connection with the hiding/overriding of member functions brought in from a base class via a using-declaration.