Welcome to another issue of Clojure Weekly! Here I collect a few links, normally 4/5 urls, pointing at articles, docs, screencasts, podcasts and anything else that attracts my attention in the clojure-sphere. I add a small comment so you can decide if you want to look at the whole thing or not. That’s it, enjoy!
Expert to Expert: Rich Hickey and Brian Beckman - Inside Clojure - YouTube Good introduction to Clojure by Rich himself talking with Brian Beckman. It also goes beyond the basic introduction when Clojure is compared to other languages of the ML family (for example Miranda or ML itself). Rich also gives an overview of persistent data structures internals and concurrency mechanisms.
gensym - Clojure standard library gensym is a little function that generates an unique symbol name (in the current running process). It optionally takes a prefix that will be used along with a sequential number added to the name. The main use of gensym is to write hygienic macros because it prevents clashes with environment bindings that are already in place at expansion time.
locking - clojure.core Programmatic locking is not in Clojure. Thread synchronisation and concurrency are handled at a much higher level with atoms, vars, refs and agents. But just in case you need to go low level, the locking function is still less verbose than the Java version that requires the synchronised keyword around an object instance. One use of locking could be if you use deftype with an unsynchronized-mutable field and then you need to protect updates with a lock. Use if you know what you’re doing.
gasc/Clojuratica · GitHub This makes me wonder if there are still things that can be invented to work with Clojure! Also the Mathematica integration! If you are a Mathematica user but would like to code in it using your favourite language, this project is for you. Although I’m not sure is actually maintained anymore, it might make a good use case to revive it to bridge the Wolfram language instead.
Clojure Categorized Nice list of standard library categorized in a different way than the main website proposes. Is not up to date. I’m linking it here just in case one day I want to update it with the current stdlib fns. I can see a lot I never used or knew about.
What is Clojure-in-Clojure? Amazed how far “modern” Clojure efforts like Clojure in Clojure can be tracked back in time. Clojure in Clojure was on of the focus after release 1.0. For that to happen, Rich envisioned the need for a “newnew” something sitting on top of lower level gen-class that made it easier to port the Java side of clojure. “newnew” then became deftype/defrecord and protocols later that year. One critical design decision was to not support what in Java is supported with abstract classes (but there is definterface just fine and some other trick to get around it). Wonder if this is was determined that Clojure in Clojure is not happening as a straight Java port but more as a rewrite these days.5 days ago