4 ms·
I find the point-free function composition style so much more elegant then lambda functions. I acknowledge lambda functions are easier to read and work basicall
by ktpsns 4y ago
I find the point-free function composition style so much more elegant then lambda functions. I acknowledge lambda functions are easier to read and work basically the same way in most contemporary multi-paradigm programming languages.
- vore 4y agoPoint-free composition can be more expensive and hard to optimize compared to anonymous functions, since you're now having to carry a heap-allocated closure around if you've partially applied arguments. Anonymous functions by contrast in C++ are super explicit about what they're capturing and you can be more sure of the allocations.
- gpderetta 4y agoStd::bind, assuming that's what the parent was referring to, does no heap allocation.
- deleted 4y ago[deleted]
- l- 4y agoAs long as elegance is not solely length using certain combinatory representations like SKI: (S(K(SI))(S(KK)I)) :: λxy.yx