Rich Hickey on Clojure

Clojure’s design is to be hosted, this caught my attention, because as it was explained at the previous podcast, the Yahoo Store was designed in Lisp, so, this makes of Clojure a good option to develop embed systems as I see. Lisp’s compiler doesn’t compile text, it compiles data structures, I still didn’t understand how Clojure can compile, read or execute code at the “same time” but it seems that the work with data structures is the key to make this posible. In Clojure, programming and metaprogramming are the same thing. 

Macros in Clojure and Lisp are simple data structure processing code, is interesting this way to explain how to “write programs that later will write another program”. “Programming in large is a collective activity, it involves people, libraries, and it’s important to be able to interact with what other people have do in other languages”, this idea is especially interesting, due to the fact that is true, nowadays there are no just one programming language, there are many of them, and it’s necessary to be able to work without compatibility issues between languages or platforms (something like the JVM).

Macros are mini programs that can be integrated in the compiler, this is something that I want to explore a little bit more, because, first I don’t understand how fully works a compiler, and how a macro is added to it. Clojure’s target audience is every programmer with an open mind, it doesn’t have a specific target as Lisp. Protocols on Clojure serves to use features of Object-Oriented Programming, this explain the loose-ends of the previous podcast in certain way, explaining what mechanism is used to permit us to use this characteristics in Clojure. 

Concurrency means that the data structures are immutable, and when working with one, this means we’ll create a new version of it. Clojure’s data structures are trees of arrays. Atom is one of Clojure’s reference type. Refs are implemented using transactional memory. I don’t know how the reference types and the transactional memory work, and this is a subject that I would like to explore too.

Comentarios

Entradas populares de este blog

Triumph of the Nerds Part II

Dick Gabriel on Lisp