Hacker News new | ask | show | jobs
by vaylian 20 days ago
One of the killer features of Clojure is it's seamless interop with the host platform. On the JVM you do something like

(Integer/parseInt my-variable); this calls Integer.parseInt(my_variable) in Java-land

I tried to find examples for how to call Rust code and the best I could find is:

https://github.com/csm/clojurust/blob/b847a29b46e2b6b3fbe624...

It looks like you need to do a lot of leg work to introduce Rust functions into Clojure namespaces. I guess there is no way around it and this is not a criticism of clj.rs. But it doesn't seem to be as seamless as on the JVM.

1 comments

spot on! we evaluated and chose regular Clojure for this reason. looking at jank now it seems very interesting for the interop. also I use a fair bit of Babashka because I like how fast it starts (good for clis and tools for agents).