Removed confusing comments (#2076) (#2179)

This commit is contained in:
Paul Jansen
2024-04-11 19:14:02 +02:00
committed by GitHub
parent c91ea43aba
commit d76efeb645

View File

@@ -4151,8 +4151,6 @@ It's confusing. Writing `[=]` in a member function appears to capture by value,
// ...
auto lambda = [=] { use(i, x); }; // BAD: "looks like" copy/value capture
// [&] has identical semantics and copies the this pointer under the current rules
// [=,this] and [&,this] are not much better, and confusing
x = 42;
lambda(); // calls use(0, 42);