Hacker News new | ask | show | jobs
by FurrBall 4602 days ago
I'd suggest skipping Clojure altogether. The JVM cannot support tail call optimizations. Use of recursion will be muffled a bit. Not very lispy.

Newer is not always better. Try racket or common lisp.

1 comments

I would respectfully disagree and perhaps my reasoning is incomplete as I am a Clojure newbie. However, the absence of tail call optimization has not been a limiting factor in my case; I have been developing clojure code ,which I am sure is non-idiomatic, that is effectively doing the job.

On the other hand, JVM ecosystem is vast. It means acces to the latest database drivers ( Oracle, Sybase , etc.) as well as NOSQL drivers. Almost all third party REST API providers( ASW, Google, etc.) provide java wrappers that you could use in your Clojure code.

The loop/recur syntax gives you recursion in constant stack space.[0] It was a bit of a speed bump coming from Scheme but it's just part of being on the JVM. Personally, I'm more than happy to take some ugly TCO syntax if it comes with the all the good stuff Clojure inherits from Java.

[0] - http://clojure.org/special_forms#Special%20Forms--%28recur%2...