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 22cb123479 Expectation refactoring 3/7: Change expectation processing
Before this commit, expectations were sorted and de-duplicated before
they were passed to "buildMessage" and exposed in the "expected"
property of syntax errors. This commit moves this processing into
"buildMessage" and rewrites it to process only expectation descriptions.
This means expectations exposed in the "expected" property are "raw"
(not sorted and de-duplicated).

This change will allow us to get rid of the "description" property of
expectations and compute descriptions dynamically from structured
information in the expectations. This will make descriptions a
presentation-only concept. It will also make generated parsers smaller.

Note that to keep expectations in the "expected" property sorted even
without the "description" property, some sorting scheme based on
structured information in the expectations would have to be devised,
which would complicate things with only a little benefit. Therefore I
chose to keep the expectations there "raw".
9 years ago
..
compiler Expectation refactoring 3/7: Change expectation processing 9 years ago
utils Remove trailing commas in object literals 9 years ago
.eslintrc.json ESLint: Set environments better 9 years ago
compiler.js Rename the "PEG" variable to "peg" 9 years ago
grammar-error.js Merge pull request #347 from mbaumgartl/errorstack 9 years ago
parser.js Don't use the "i" suffix for case-insensitive class descriptions 9 years ago
peg.js Rename the "buildParser" function to "generate" 9 years ago