4 ms·
> On the other hand, Wadler himself in "Why Functional Programming Matters" argues that laziness is essential to achieve modularity and composability. I just r
by p0nce 12y ago
> On the other hand, Wadler himself in "Why Functional Programming Matters" argues that laziness is essential to achieve modularity and composability.
I just read the part about it, I agree that lazy computation is a powerful tool for modularity and composability.
But it's nothing specific to FP languages.
Python and Nimrod do that through generators (yield keyword), D through "ranges" (no language support).
Also not all algorithms you would want to write only once are easily expressible in a lazy way (eg. push parsers).