News for hackers. Stuff that matters.
Re:Why I Switched from Python to Clojure (2016) by john2x on Monday March 25, 2019 @02:26AM (#19480652)
I really don't understand this point about just using Java libraries in Clojure. Why not just use Java? Wouldn't the experience of writing Clojure that fits the Java library's model be horrible?
Re:Why I Switched from Python to Clojure (2016) by mschaef on Monday March 25, 2019 @06:02AM (#19481299)
Not really. Clojure has nice native syntax for Java interop (or JavaScript for ClojureScript). In fact, I'll occasionally use Clojure to explore a Java API while working in Java.

What happens in my experience is that Clojure programs do tend to encapsulate more extensive use of Java interop into their own modules. For more standard or commonly used packages, this means a canned library or similar. (But this notion of abstracting out APIs is just good software engineering in general, and not really specific to Clojure or anything else.)

Re:Why I Switched from Python to Clojure (2016) by bradcypert on Monday March 25, 2019 @09:35AM (#19482275)
The main points being:

1. If you need it, and there's not a Clojure alternative, you don't have to write your own. 2. If you have any proprietary .jars or anything like that, you can leverage those services, models, etc when building an existing Clojure app. This is mainly a transition-type thing, in my experience. "Well, we could try Clojure but then we cant reuse any of our existing models." Not entirely true. However, you probably will want to change those from mutable classes pretty quickly :)

Re:Why I Switched from Python to Clojure (2016) by Scarbutt on Monday March 25, 2019 @12:02PM (#19483706)
Yes, you are suddenly writing java with parentheses.

Don't get me wrong, Clojure is a great language in itself, but the lack of libs make you spent 90% of your time writing interop, you start to ask yourself if it's worth the trouble.

Re:Why I Switched from Python to Clojure (2016) by malvosenior on Monday March 25, 2019 @01:29PM (#19484542)
I actually find Clojure's `doto` notation to be the cleanest way to interact pure Java. It's like an improved syntax for Java that's native in Clojure.