kschiess / parslet

A small PEG based parser library. See the Hacking page in the Wiki as well.
kschiess.github.com/parslet
MIT License
805 stars 95 forks source link

json parser example not work when a array inside like [{ "b": true, "c": false , "d": [1, 2, 3]}] #210

Closed bravywang closed 1 year ago

bravywang commented 3 years ago

try this: [{ "b": true, "c": false , "d": [1, 2, 3]}] will get: ./xsim:74:in `key': wrong number of arguments (given 0, expected 1) (ArgumentError)

kschiess commented 1 year ago

The json parser (which one?) would be an example of a parser, not a production version parser. There are plenty alternatives in the Ruby ecosystem. This issue - AFAIK - does not relate to parslet itself - let me know if you think otherwise; also a pointer to which json parser would be welcome.