in reply to Re^2: How would you parse this?
in thread How would you parse this?
Um, I think it can :)
See https://metacpan.org/source/RSAVAGE/MarpaX-Demo-JSONParser-1.03/share/json.1.bnf and https://metacpan.org/source/RSAVAGE/MarpaX-Demo-JSONParser-1.03/share/json.2.bnf
no need to convert it to Regexp::Grammars format like the other examples
And the JSON bnf looks pretty pretty pretty similar to what you're trying to parse here
looks to be line; oriented ( ^ and ;$ ) parens ( ) don't look to span lines leftstuff = rightstuff; brackets [ ] span lines braces { } span lines keyname : somekindvalue , leftstuff rightstuff linestuff
|
|---|