Hacker News new | ask | show | jobs
by timbaldridge 4797 days ago
sadly, this doesn't seem to support any sort of multithreading. Even something as simple as swap! isn't thread-safe in this implementation. So that kills one of the main reasons to use Clojure in the first place.
3 comments

Lack of multithreading seems like a result of the implementation being heavily based on ClojureScript ;) (it's actually pretty cool to see how reusable core.cljs is IMO). I imagine ClojureC will have its uses like ClojureScript does when the JVM is not an option.
> sadly, this doesn't seem to support any sort of multithreading

Maybe multithreading is just not yet implemented?

> So that kills one of the main reasons to use Clojure in the first place.

I could see ClojureC being very useful for when you want:

  * small footprint
  * easy C-library interop
  * fast start-up time
and where you don't necessarily need multithreading.

(BTW, I'd be curious to hear what you think might be the differences in use cases between ClojureC and mjolnir/clojure-metal.)

It is quite interesting though as soon as you extend it with calls to C libraries. Like if you want to use Clojure for libavcodec, or many others.