https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83160

Daniel Krügler <daniel.kruegler at googlemail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |daniel.kruegler@googlemail.
                   |                            |com

--- Comment #1 from Daniel Krügler <daniel.kruegler at googlemail dot com> ---
The example looks invalid to me according to [expr.prim.lambda.capture] p7 b
(7.1), because the local variable bj is odr-used in the lambda expression

[](int bk) { a::ac(bk, bj); };

This is so, because the called function template

template <typename b> void ac(b, const b &);

attempts to bind its second argument by reference.

Reply via email to