Re:C++ and the Culture of Complexity
by rayiner on Friday August 23, 2013 @06:52PM
(#6266676)
That code is wrong. Its obvious why its wrong when you think about the closure representation. Forcing a developer to understand the implementation is not inconsistent with the C++ mentality (see: everything having to do with inheritance and parameter passing).
[ Parent
| on HN ]
> That code is wrong. Its obvious why its wrong when you think about the closure representation.
I don't follow you. There's nothing inconsistent about allowing the closure representation to capture by reference. Indeed C++ allows this, if you write the appropriate capture clause.