lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


I come from the _javascript_ community and remember when JSON was born, it's just a defined subset of _javascript_ that Crockford came up and standardized one day. 
I'm started something similar for lua called LTIN (Lua Table Interop Notation). https://github.com/luvit/luvit/wiki/Lua-Table-Interop-Notation

The biggest selling points for me is it has comments, multi-line strings, keys don't have to be quoted, and non-string values can be strings.

I haven't done this yet, but a standalone parser could be written in C that would be pretty minimal I think.  My implemention is in lua since that's where I would be using it. https://github.com/luvit/ltin/blob/master/ltin.lua


On Sat, Jan 5, 2013 at 10:38 AM, steve donovan <steve.j.donovan@gmail.com> wrote:
On Sat, Jan 5, 2013 at 5:55 PM, Duncan Cross <duncan.cross@gmail.com> wrote:
> For readability, my least favourite things about canonical JSON are
> that it does not support comments, and there's no way to break a long
> string literal over multiple lines. Apart from that it's pretty good.

OK, so what we need is LON (Lua Object Notation). Just a little less simple.

(With a multiline no-commas optional format for config files)