News for hackers. Stuff that matters.
Re:The Language-Language Matrix by mtrimpe on Tuesday December 03, 2013 @03:38AM (#6839274)
It's impressive to see how many runtimes Clojure has already been ported to.

I'm starting to get my hopes up for a world where a Clojure FRP core drives apps in a host of target languages.

Re:The Language-Language Matrix by juliangamble on Tuesday December 03, 2013 @05:50AM (#6839589)
What we see in Clojure (like other Lisps) is minimal syntax directed at the idea of homoiconicity. This means that the program's structure is similar to its syntax. It also means that we can represent the program as a data structure in the language itself.

So (1) Simple syntax, and (2) being able to represent the program structure in the language easily, both lead to making it easy to build compilers, interpreters and bytecode compilers. The barrier to entry for these tasks is lower in Clojure.

Many would also say that (1) and (2) make Clojure a joy to program in, but I'll leave that to the reader to judge for themselves.

Re:The Language-Language Matrix by nilliams on Tuesday December 03, 2013 @08:06AM (#6839973)
> Many would also say that (1) and (2) make Clojure a joy to program in, ...

Yep, the opposing view being that the lack of syntax that some see as a benefit actually makes it inexpressive, compared to a language with more syntax that expresses its ideas more like human language (e.g. Ruby, Python).

> but I'll leave that to the reader to judge for themselves.

Same! Not made my mind up yet, currently struggling through the Clojure book.

Re:The Language-Language Matrix by danenania on Tuesday December 03, 2013 @10:04AM (#6840634)
I recently came across this new Clojure book:

http://www.braveclojure.com/

Seems like potentially an accessible and entertaining intro to the language. Perhaps it could be a good way to get your feet wet before diving into one of the larger tomes.

Re:The Language-Language Matrix by nilliams on Tuesday December 03, 2013 @12:17PM (#6841615)
Thanks!
Re:The Language-Language Matrix by sesm on Tuesday December 03, 2013 @08:09AM (#6839983)
Clojure is designed as a hosted languages from the start and intentionally exposes platform semantics for many operations, such as math, strings, etc. This makes porting easier, since one doesn't have to implement "compatibility layer" for all those operations.

On a side note, Clojure concurrency primitives implement different ideas compared to FRP. A good source to learn about ideas behind Clojure concurrency is this talk by Rich Hickey: http://www.infoq.com/presentations/Are-We-There-Yet-Rich-Hic... . At 1:08:25 Rich tells his opinion about FRP.

Re:The Language-Language Matrix by mtrimpe on Tuesday December 03, 2013 @09:00AM (#6840239)
I haven't watched that part of the video yet, but I've always believed that Rich's biggest blind-spot seems to be about not realizing how Clojure's macro system can be used to rewrite regular code into FRP.

Just have a look at what a macro like Javelin [1] already enables [2] and imagine how powerful that would be when combined with 'live' Datolog queries where the query results in the browser will stay up to date with the results from the logic datalog query on Datomic.

I've tried explaining it to Rich at EuroClojure 2012 but I'm pretty sure he was still thinking in terms of 'classic FRP' back then.

[1] https://github.com/tailrecursion/javelin [2] http://www.infoq.com/presentations/ClojureScript-Javelin

Re:The Language-Language Matrix by mtrimpe on Tuesday December 03, 2013 @02:15PM (#6842400)
Just watched it and his response is definitely not about the kind of FRP I'm talking about here, but seems to be criticising a specific interpretation of continuous FRP.

When asked what is the right direction he explicitly mentions that it's when all your data is immutable, which definitely applies to Javelin.

Re:The Language-Language Matrix by lukev on Tuesday December 03, 2013 @10:04AM (#6840635)
It's not classic FRP, but you're basically describing core.async. Have you looked at that at all?
Re:The Language-Language Matrix by mtrimpe on Tuesday December 03, 2013 @10:43AM (#6840899)
Core async is also an example of a very powerful macro that rewrites execution flow; but they do decidedly different things.

While Core Async is about powerful non-threaded coordination of processes, Javelin is about creating self-updating non-cyclical function graphs.

Basically it's about automatically keeping a derived a view from a small set of data up to date when the source data changes.

It's the exact same thing a spreadsheet does for numbers, but becomes much more interesting when the derived view is a DOM tree derived from database+view state.

FWIW; I was inspired by the the work of Kenny Tilton (a.k.a. Smuglispweeny) and his Cells library and manifesto [1]. His work seems to be falling in disarray, but there's still some stuff up on the wayback machine [2][3]

[1] http://smuglispweeny.blogspot.nl/2008/02/cells-manifesto.htm...

[2] https://web.archive.org/web/20080925125040/http://www.tilton...

[3] https://web.archive.org/web/20080925113544/http://bc.tech.co...