News for hackers. Stuff that matters.
Re:JSONSelect by prodigal_erik on Saturday May 21, 2011 @07:16PM (#2572044)
You could easily invent a programming language expressed in JSON literals, it just wouldn't be quite the same as javascript. I'd argue that sexprs are simpler because they only use one container type (alists and plists are merely conventions, not baked into the grammar). However, JSON's omission of the symbol/string distinction is one argument the other way.
Re:JSONSelect by pnathan on Sunday May 22, 2011 @12:02AM (#2572577)
That might be a slightly amusing syntactical overlay on Common Lisp. Hash-tables are a bit manky to deal with directly IMO; setting up a reader macro in JSON-esque syntax might be quite usable.
Re:JSONSelect by prodigal_erik on Sunday May 22, 2011 @03:27AM (#2572848)
Oddly enough, Steele pretty much already did this as a readtable example in his classic manual (based on xappings and xets from Connection Machine Lisp): http://www.cs.cmu.edu/Groups/AI/html/cltl/clm/node192.html#X...
Re:JSONSelect by pnathan on Monday May 23, 2011 @02:09AM (#2575112)
yeah, I noticed that as I worked on implementing the idea last night. :-)
Re:JSONSelect by Ixiaus on Saturday May 21, 2011 @10:31PM (#2572439)
Yes, you can, probably not too different in nature to Racket's syntactical sugar with using "[" (square brackets) to make reading the LISP code easier... And yes, your argument for their simplicity is actually what I was trying to express (much less successfully than you did).