This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 110d. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.
[Applied to WP at the February, 2014 meeting.]
The access of the non-static data member corresponding to an init-capture is not specified. The question would be moot if the member were unnamed like the other non-static data members of the closure class.
Proposed resolution (September, 2013):
For every init-capture a non-static data member named by the identifier of the init-capture is declared in the closure type. This member is not a bit-field and not mutable. The type of that member corresponds to the type of a hypotheticalvariable declarationof the form “auto init-capture ;” , except that the variable name (i.e., the identifier of the init-capture) is replaced by a unique identifier.
[Note: This enables an init-capture like “x = std::move(x)”; the second “x” must bind to a declaration in the surrounding context. —end note]
No entity is captured by an init-capture. Within the lambda-expressions lambda-declarator and compound-statement, the identifier in the init-capture hides any declaration of the same name in scopes enclosing the lambda-expression.[Example:...
Change 7.5.5 [expr.prim.lambda] paragraph 15 as follows:
An entity is captured by copy if it is implicitly captured and the capture-default is = or if it is explicitly captured with a capture that
does not include an &. For each entity...
Change 7.5.5 [expr.prim.lambda] paragraph 18 as follows:
Every id-expression that is an odr-use (6.3 [basic.def.odr]) of an entity captured by copy is transformed into an access to the corresponding unnamed data member of the closure type. [Note:...
This resolution also resolves issue 1681.