4 ms·
The upside of `recur` is that: * just by looking at the code you can tell if it's a tail call or not * easy to debug; no trampoline magic * guaranteed to work o
by the-alchemist 5y ago
The upside of `recur` is that:
* just by looking at the code you can tell if it's a tail call or not
* easy to debug; no trampoline magic
* guaranteed to work on any platform, whether it supports TCO or not
* Javascript is a very popular target, via ClojureScript
* who wants to test and remember if Chrome or Firefox or Safari implement TCO? or implement it properly? and which version(s) of those browsers implement TCO properly?
* if you wanna want a trampoline, you got it! (https://clojuredocs.org/clojure.core/trampoline https://clojuredocs.org/clojure.core/trampoline)