Some time back, I tried to take JSON as the AST and see if I can build a Scheme-like programming language with it. I did it just for kicks, but if it interests anyone .. [1].<p>It's lacking in docs, but this might be of interest - you get a Scheme-like language (without tail recursion), keyword arguments, lambda, macro, quote & quasi-quote, let expression, where clauses, generators, and some degree of code isolation. The compiler is a very simple one and is written in "stream of thought" style [2] and so might be quite easy to follow.<p>[1] <a href="http://github.com/srikumarks/jexpr" rel="nofollow">http://github.com/srikumarks/jexpr</a>
[2] <a href="http://srikumarks.github.com/jexpr/" rel="nofollow">http://srikumarks.github.com/jexpr/</a>
Add "SweetExpressions" and I wonder how far from coffeescript it would get.<p>"SweetExpressions" is probably the best method so far to get rid of excessive parentheses in lisp. See <a href="http://readable.sourceforge.net/" rel="nofollow">http://readable.sourceforge.net/</a>
This is just a light lisp-like syntactic layer, as the docs say "LispyScript is not a dialect of Lisp. There is no list processing in LispyScript ." It's just enough to allow nice macros, which adds quite a bit, IMO. There's no CONS, etc. It adds a couple nice things, like an "each" function that does the right thing, and (= foo bar) becomes foo === bar.
I experience a kind of jolt when I read lispy syntax mixed with constructs like [1, 2, 3]. It shouldn't be a big step to make a syntax for #(1 2 3) or (make-array 1 2 3) instead. Get rid of that infix comma syntax! Then there is the record syntax... {foo: 3, bar: 4}... Infix commas and colons! How about (make-object foo 3 bar 4) or #O(foo 3 bar 4)? Or support reader macros so that you can override []s and {}s to do something a little prettier.