You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
David Majda 435bb8f2df Error handling: Structured expectations
Before this commit, the |expected| property of an exception object
thrown when a generated parser encountered an error contained
expectations as strings. These strings were in a human-readable format
suitable for displaying in the UI but not suitable for machine
processing. For example, expected string literals included quotes and a
string "any character" was used when any character was expected.

This commit makes expectations structured objects. This makes the
machine processing easier, while still allowing to generate a
human-readable representation if needed.

Implements part of #198.

Speed impact
------------
Before:     1180.41 kB/s
After:      1165.31 kB/s
Difference: -1.28%

Size impact
-----------
Before:     863523 b
After:      950817 b
Difference: 10.10%

(Measured by /tools/impact with Node.js v0.6.18 on x86_64 GNU/Linux.)
11 years ago
..
generate-bytecode.js Error handling: Structured expectations 11 years ago
generate-javascript.js Error handling: Structured expectations 11 years ago
remove-proxy-rules.js Move options handling from passes to |PEG.compiler.compile| 12 years ago
report-left-recursion.js Make |GrammarError| require work also in the browser version 12 years ago
report-missing-rules.js Make |GrammarError| require work also in the browser version 12 years ago