Comment on Implementation of GCC's Nested Functions (vs. C++ Lambdas)parentComments−lpribis4dSure, but in that case they are equivalent to a static function so there's no benefit of lambda other than syntax sugar.−moxxymiller3dCapturing lambdas in a language without a GC (or a borrow checker) are kinda fraught with footguns.−ueckerOP3dThis is not my experience.−6yyyyyy4dThe benefit is that you don't have to solve one of the hard problems in computer science (naming things).
Comments
Sure, but in that case they are equivalent to a static function so there's no benefit of lambda other than syntax sugar.
Capturing lambdas in a language without a GC (or a borrow checker) are kinda fraught with footguns.
This is not my experience.
The benefit is that you don't have to solve one of the hard problems in computer science (naming things).