Quantcast
Viewing latest article 2
Browse Latest Browse All 5

Re: Access from a lambda to a member of a class

Hello, B0FEE664, you wrote: BFE> In what sense of the prohibition of capture of members of a class in the capture list? So it was added. All members are captured through capture this. auto fn = [this] (int n) {m_n = n;};//ok BFE> Why then so it is possible: auto fn = [&m_n = m_n] (int n) {m_n = n;};//ok expressions in the capture list entered in With ++ 14 whereas capture of variables and this has been entered into a C ++ 11


Viewing latest article 2
Browse Latest Browse All 5

Trending Articles