Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Just to be picky.... Clojure doesn't have TCO, it has 'recur' as a substitute instead.


To add a finer point, Clojure doesn't have TCO per se because the JVM doesn't have tco. Recur optimizes the special case of "tail-recursive self-call and not the generalized tail call."[0] That is to say when the tail of A calls A, but not when A calls B which calls A.

[0] "The Joy of Clojure," Fogus and Houser




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: