4 ms·
loop/recur handles only a tiny part of TCO. TCO means all calls in tail position are optimised, not just the self-recursive ones. Personally I find loop/recur
by lispm 10y ago
loop/recur handles only a tiny part of TCO.
TCO means all calls in tail position are optimised, not just the self-recursive ones.
Personally I find loop/recur ugly. It's a partial hack around the lack of TCO.
Though I prefer looping statements like Common Lisp's ITERATE, whose design I like a lot...
https://common-lisp.net/project/iterate/doc/index.html https://common-lisp.net/project/iterate/doc/index.html