Created on 2011-08-18.00:00:00 last changed 130 months ago
[Voted into the WP at the February, 2012 meeting; moved to DR at the October, 2012 meeting.]
Proposed resolution (August, 2011):
Change the indicated bullet of 7.7 [expr.const] paragraph 2 as follows:
this (7.5 [expr.prim]
_N4567_.5.1.1 [expr.prim.general]) unless it appears as the
postfix-expression in a class member access expression,
including the result of the implicit transformation in the body of a
non-static member function (11.4.3 [class.mfct.non.static])
[Note: when evaluating a constant expression, function
invocation substitution (9.2.6 [dcl.constexpr]) replaces each
occurrence of this in a constexpr member function
with a pointer to the class object. —end
note];
Change 9.2.6 [dcl.constexpr] paragraph 5 as follows (converting the running text into a bulleted list):
Function invocation substitution for a call of a constexpr function or of a constexpr constructor means:
implicitly converting each argument to the corresponding parameter type as if by copy-initialization,91
substituting that converted expression for each use of the corresponding parameter in the function-body,
in a member function, substituting for each use of this (_N4868_.11.4.3.2 [class.this]) a prvalue pointer whose value is the address of the object for which the member function is called, and
forin a constexpr functions, implicitly converting the resulting returned expression or braced-init-list to the return type of the function as if by copy-initialization.Such substitution...
Function invocation substitution (9.2.6 [dcl.constexpr] paragraph 5) seems underspecified with respect to this.
History | |||
---|---|---|---|
Date | User | Action | Args |
2014-03-03 00:00:00 | admin | set | status: drwp -> cd3 |
2012-11-03 00:00:00 | admin | set | status: dr -> drwp |
2012-02-27 00:00:00 | admin | set | messages: + msg3801 |
2012-02-27 00:00:00 | admin | set | status: ready -> dr |
2011-09-06 00:00:00 | admin | set | messages: + msg3451 |
2011-08-18 00:00:00 | admin | create |