Monday, July 07, 2014

Java 8 and Clojure

Originally published April 5, 2014

I have to admit that I have often been lazy about converting Java code to Clojure. Several of my side projects have :java-source-paths set in my project.clj file and I just copy in the bits of old Java code that I am too lazy to convert. In some way I justify this because it is so easy to mix and match Clojure and Java code and the lein build process works well and I have never had any problems.

One thing that does not work, as far as I know, is mixing Java 8 lambdas with Clojure. That may happen sometime, but not a big deal for me. Mixing in my favorite Java 8 addition (streams) with Clojure is also not so important to me since it would not bring much to the table for Clojure developers.

I am far from being a "Clojure purist" (or any other single language) but one thing that really strikes me after using Clojure for about one third of my development over the last 4 or 5 years is that it is such a practical language for getting stuff done.

No comments: