3 ms·
It is not a limitation of Clojure but a limitation of the JVM. And you can use the recur keyword to actually do TCO.
by edem 10y ago
It is not a limitation of Clojure but a limitation of the JVM. And you can use the recur keyword to actually do TCO.
- PuercoPop 10y agoRecur only handles a limited case of tail call elimination, not when the function calls another function on the tail position. Also you can implement TCE on the JVM Kawa Scheme does, just not efficiently. It is a limitation resulting from the design decision of Clojure.