Ahh, the siren song of Lisp
I wrote Lisp (Clojure) professionally for several years. It was the most fun I ever had.
My only problem was it was an ongoing battle to convince people - especially management - that I wasn't crazy.
Sure, I was crazy-productive, but they also thought that there was some nutjob in the corner that was quietly adding risk to the business.
If someone could give me the ergonomics of Clojure, but without the JVM and the ability to easily target 1/ native (incl easy bidirectional C iterop), 2/ wasm, and 3/ support both in aot and runtime + JIT modes, I would switch in a heartbeat.
Is that too much to ask?
What is wrong with the JVM? The JVM is utterly amazing and you know very well that you can target native, even with Clojure.
I agree that the JVM is an amazing piece of technology.
But the ecosystem that exists around the JVM also comes with both a bunch of awesome libraries, and a whole bunch of cruft and ceremony.
If, like Clojure, you're trying to pull in compatibility with JVM libraries, then you pull all that in. So now if you want a little C in your Clojure, you have to go through JNA or something.
I would like the option of going native with a Clojure dialect, without passing through either JVM (Clojure) or JS (ClojureScript).
Now there is Panama, and then GraalVM as well.
Plus OpenJ9, PTC, Aicas, Azul, and even the Java like MicroEJ and ART.
Many don't have an idea of breath and depth of Java ecosystem, and what guest languages can profit from.
Not to mention that you can
Compile JVM bytecode to Wasm https://github.com/cretz/asmble
or
Run the JVM on Wasm https://cheerpj.com/docs/overview
Now is always the great time to be using JVM tech.
Yeah, for a reason I have always wandered around JVM, and its counterpart CLR, unless requested otherwise, since 2002.
Have you seen Jank? It’s a Clojure dialect being written in C++ and designed for interop with C++ instead of the JVM.
https://jank-lang.org/
It's almost perfect.
If it were strict C in stead of C++ I would probably be in love.
You should meet this nice https://github.com/babashka/babashka !
It is Clojure written in Clojure compiled to native via GraalVM.
Speaking as someone who was using Clojure pre-1.0 through... 1.2? because I was so interested in Lisps and one with access to a modern library ecosystem excited me, I did not enjoy my time with Maven at all. It felt very janky. A second issue that I hear they finally fixed was Clojure still gave all of the low level parts of the error that were basically the guts of Clojure and had nothing to do with my code which I got tired of dealing with. Probably other issues I'm forgetting as I have not used it in a decade or so, but I just did not enjoy my time dealing with the JVM ecosystem.
Might want to look at Jank (https://jank-lang.org/, https://github.com/jank-lang/jank). It's still in it's early stages but it's basically all you're hoping for!
The name might be hard to push to management, but I love that it is s-expr based.
I'll definitely check it out, but if you don't mind me asking: how good is the REPL side on Jank? If it is remotely close to SBCL, then I might become a fan.
jank will have full nREPL support, so the REPL story should be at parity with Clojure. I'm working on the nREPL server now We're JIT compiling C++ code, so there are indeed more dragons.
Hi,
Late to the party, do you think you could give me a comparison of Jank vs Janet ? I'm just starting to look at janet, and just found out about jank at this point.
How usable is Jank for greenfield projects, The comparison page isnt that useful as I don't know what I'm missing.
Thanks in advance.
Will check it out!
Nim.
Not joking. I use it at work. Former Clojure crazy. All the referential transparency/immutable data you could want from a non-Clojure language.
Super easy bidirectional C interop.
Native compiled but does have a compile-time script engine. Is the absolute most powerful compile-time evaluation I've seen outside of Lisp.
Creator calls it a "quirky Lisp".
Just curious, what kind of companies do you find that are open to using Nim professionally? It's always hard with more niche languages.
Smaller ones where you're the sole dev on a given component, there are no cross-language dependencies in your systems (it's a CLI-invoked tool and/or communicates through stdout or JSON data, etc.), and your boss has had such poor experiences with freelancers and Microsoft lock-in in the past that he's open to you choosing the best tool for the job within reason.
I'll check it out, thanks!
The JVM is exactly why Clojure is one of the most successful Lisp variants since the AI Winter.
I agree! And I still love it because it's what allowed me to sneak a Lisp into not just a Java shop, but the Java shop: Oracle.
What made it more productive than the usual mainstream languages?
I'm coming from 10 years of OOP leaning C++/Java/Python, and have been seeing the beauty of functional programming in the latter half of that time. It's just far easier to test than OOP in my experience.
you might like https://janet-lang.org/ !
Some good progress on Jank lately:
https://jank-lang.org/
Take a look at Gerbil Scheme
https://cons.io/