3 ms·
I find clojure's current approach to tail recursion to work very well. Maybe I'm just not functional enough, but I'm not sure why function calls that don't pus
by rikthevik 17y ago
I find clojure's current approach to tail recursion to work very well. Maybe I'm just not functional enough, but I'm not sure why function calls that don't push a stack frame should be done the same way as a regular function call. Doing a tail call explicitly is fine, and seems to work okay.
Why is the demand for tail calls so great?
- hga 17y agoIt has a certain elegance and conciseness and having different syntax for recur and the mutual recursion trampoline is perhaps more than inelegant. Every little thing you add to a language makes it that much more difficult to remember and correctly use everything. The closer Clojure stays to Scheme in the Scheme to Common Lisp continuum the better.