Created on 2013-05-31.00:00:00 last changed 126 months ago
Rationale (June, 2014):
After further consideration, CWG agreed that this example should extend the lifetime of the temporary (because the notional variable is a reference) and that the existing text is clear enough in this regard.
Notes from the September, 2013 meeting:
CWG agreed that there is no lifetime extension in this example.
If an init-capture binds a const reference to a temporary, is the lifetime of the temporary extended to match that of the lambda? For example,
struct S { ~S(); };
const S f();
auto &&lambda = [&x(f())] () -> auto& { return x; };
auto &y = lambda(); // ok?
History | |||
---|---|---|---|
Date | User | Action | Args |
2014-07-07 00:00:00 | admin | set | messages: + msg5115 |
2014-07-07 00:00:00 | admin | set | status: drafting -> nad |
2013-10-14 00:00:00 | admin | set | messages: + msg4630 |
2013-10-14 00:00:00 | admin | set | status: open -> drafting |
2013-05-31 00:00:00 | admin | create |