It also seemed to require a lot of work to construct the code to make tail call optimization happen, but that’s par for the course in Haskell.
It also seemed to require a lot of work to construct the code to make tail call optimization happen, but that’s par for the course in Haskell.
Either way, optimization in any language often requires annotations. The main benefit of Haskell though is still equational reasoning, which this does not obviate. You can get rid of all the annotations and your code will still run, be correct, and can be reasoned about
Similarly, the existence of generators and zero-argument functions in Python doesn't undermine the idea that strictness by default could have benefits.
Though, I suppose you could then say that if the rules are different for low level optimization, they may as well have imported an external library written in Rust.