New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[over.match.oper] p2 It seems that p2 omits the function call operator #5401
Comments
The function call syntax is not handled by [over.match.oper]; it is not considered an "operator" in that sense. Instead, it is covered by [over.call.object]. The lack of () in table 17 clearly makes that subsection inapplicable for operator(). |
@jensmaurer If [over.match.oper] does not intend to cover What I want to say is we just have a note [expr.pre] p2 to reference to [over.oper] that covers subclause [over.call]. For example: {
S{}(1,2,3);
} when this expression-statement is used, it interpret |
Incidentally, [over.match.call.general] says
However, we have restricted that the postfix-expression in a function call shall
So, whether the transformation(transform the postfix-expression to a function call) or [expr.call] go first? |
@jensmaurer This #3957 precisely exposes what I am concerned about here. |
[over.oper.general] p11 says
()
has its own subclause [over.call], thus it is not intended to be covered by [over.binary]. In Table 17, it lists all operators mentioned in [over.unary] through [over.inc] except that()
in [over.call]. It is reasonable that Table 17 should also cover [over.call] , since it saysThe above example is exactly the case where the operand has a class type. Furthermore, [expr.pre] p3 says
The conversion should be applied before we fall into [expr.call] p1:
So, when we check [over.match.oper], we would seek the
()
function call operator in the subclause.The text was updated successfully, but these errors were encountered: