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.
4fe682794d
Before this commit, descriptions of literals used in error messages were built by applying JavaScript string escaping to their values, making the descriptions look like JavaScript strings. Descriptions of character classes were built using their raw text. These approaches were mutually inconsistent and lead to descriptions which were over-escaped and not necessarily human-friendly (in case of literals) or coupled with details of the grammar (in case of character classes). This commit changes description building code in both cases and unifies it. The intent is to generate human-friendly descriptions of matched expressions which are clean, unambiguous, and which don't escape too many characters, while handling special characters such as newlines well. Fixes #127. |
9 years ago | |
---|---|---|
.. | ||
compiler | 9 years ago | |
utils | 9 years ago | |
.eslintrc.json | 9 years ago | |
compiler.js | 9 years ago | |
grammar-error.js | 9 years ago | |
parser.js | 9 years ago | |
peg.js | 9 years ago |