Clojure hosted on Go is something that I really hope gets more attention. Clojure being built on top of Java is a fine decision, but I would love to use clojure to compose the ever growing library of stable packages that exist in the Go ecosystem.
I really like Go as well, but the JVM is a lot better at hosting languages than any interpreter implemented in Go. You will likely pay a significant performance cost even for a very optimized Go interpreter. I wish this were not the case.
My latest favorite kid on the block is nbb. The REPL spins up instantaneously, and you can use all Node packages, it requires virtually zero setup.
But if I can rich out to Golang, why not? More Clojures is better. Imagine a single Polylith repo with blocks that talk to Node, JVM, Go, Python, etc.? Woah, that's sounds insanely cool, right?
I think most Clojure implementations take the lesson from the original that to be embedded in a platform rich with mature libraries is a great strength, but aren't dogmatic about some idea that only a few runtimes are worthy of such embedding. The idea is more 'make it practical to bring a Lisp to work and integrate it with your existing projects', rather than 'create one implementation to rule them all by choosing the biggest ecosystem to integrate with' (though a consideration aligned with the letter was doubtless a factor in the choice of platform for the first implementation).
So the thought is more like: because Go is popular, a good Clojure implemented in Go will let me bring all the Clojure goodies to many additional projects with tight integration for little fuss— not 'finally a big ecosystem, the JVM has no software'.
Another way to think about it is that different platforms often have their own 'killer libraries'. Maybe for working with some Docker or some IaC tools, a Go-hosted Clojure would be especially convenient, for example.
A little off topic, but as someone who has occasionally used Clojure since Rich released a beta version (on many professional gigs, and to support examples in my Clojure AI book), I used to make such a mistake by writing wrappers in Clojure for Java libraries I used.
A while back someone set me straight, and I no longer do that. So much better to call Java directly. Seeing the Glojure/Go interop examples reminded me of this.
Java is definitely not even close to being "highly expressive". It has been a very simple language, and was always very conscious of remaining that with a slow, but well-thought-out evolution, learning from others' mistakes.
Hmm maybe I'm too out of touch. You're talking about recent java (12+) vs go ?
I stopped working in java so maybe I'm too bruised by the J2EE 5 era, but what I saw from Go was an order of magnitude less verbose than my memories of java.
Please don’t take this rudely. But if you haven’t used a language or looked into in over a decade perhaps you shouldn’t comment on it?
That being said you should really check out how streams, records, switch expressions, pattern matching and all of the recent additions in the last 5 years have made Java a magnitude less verbose than Go.
- a ton of java is still legacy, ask works with java 7 vs java 17 and enjoy the laugh
- I assumed java culture was still too rotten by its roots. I've used streams but whenever I have to import BiFunction I feel very sad.
on the other side, the few go code I've seen was always very concise, or even when the code base wasn't very well designed it was, at worst, still below java
Only 2% [0] of runtimes are on Java 7. There is a large majority on 8 still and 45% are running Java 17. That being said Java 8 is still less verbose than Go. The number of lines needed to do basic programming like iterating collections or error handling is a magnitude larger in Go.
You’re basing your opinion on your feelings rather than objective facts of being in the ecosystem. Yes you may have to import BiFunction but that isn’t anymore verbose than having to write:
Java EE was/is a whole platform, framework, deployment model all in one.
Also, most of the verbosity of that early version was very high flexibility (everything could be replaced) plus an XML-based configuration. I wouldn't really count XML in Java's verbosity, nor do I think that comparing it to vanilla Go is meaningful.
For similarly scoped libraries Java is less verbose due to go's error handling being all over the place.
Maybe, but IME they tend to be lower quality than the Go ones. Java has some truly great libraries, but culturally has an entirely different approach to almost everything.
other related packages: https://joker-lang.org/ https://github.com/nooga/let-go