News for hackers. Stuff that matters.
Re:ClojureC, a compiler for Clojure that targets C as a backend by timbaldridge on Saturday May 04, 2013 @07:08PM (#5656666)
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.
Re:ClojureC, a compiler for Clojure that targets C as a backend by swannodette on Saturday May 04, 2013 @07:17PM (#5656688)
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.
Re:ClojureC, a compiler for Clojure that targets C as a backend by uvtc on Sunday May 05, 2013 @12:15AM (#5657427)
> 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.)

Re:ClojureC, a compiler for Clojure that targets C as a backend by terhechte on Saturday May 04, 2013 @07:33PM (#5656747)
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.