Example grammar that parses JSON like JSON.parse? #2091
-
Hello, I'd like to benchmark my little parser generator against Chevrotain, but I can't find a first-party grammar for it that parses JSON. I see there's this one, but it parses JSON to a CST, in order to compare it against my grammar it would have to parse JSON in the Thanks. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
You can find the performance section of other peg-like parsers in chevrotain's gh-pages branch. |
Beta Was this translation helpful? Give feedback.
-
You will need to take this grammar: and modify it to include the actions to bulid the JSON object. |
Beta Was this translation helpful? Give feedback.
You will need to take this grammar:
and modify it to include the actions to bulid the JSON object.