3 ms·
Every "FP 101 for JavaScripters" tutorial on the web starts with this same example: function adder (x) { return function (y) { return x + y;
by joeframbach 8y ago
Every "FP 101 for JavaScripters" tutorial on the web starts with this same example:
function adder (x) {
return function (y) {
return x + y;
}
}
Is this somehow a bad thing to do now, and how would I "lift" it? I don't quite understand.
Pretty much every modern KS library has tons of functions whose definitions look like `const foo = a => b => c => junk(a,b,c)`, and is that really better than just writing a normal foo method like it was 1996?
- wtetzner 8y agoLambda lifting is usually just a technique used by compilers.