diff --git a/lib/parser.js b/lib/parser.js index 451d022..7677c3f 100644 --- a/lib/parser.js +++ b/lib/parser.js @@ -381,30 +381,10 @@ function peg$parse(input, options) { return input.substring(peg$savedPos, peg$currPos); } - function offset() { - return peg$savedPos; - } - - function range() { - return [peg$savedPos, peg$currPos]; - } - function location() { return peg$computeLocation(peg$savedPos, peg$currPos); } - function expected(description, location) { - location = location !== undefined - ? location - : peg$computeLocation(peg$savedPos, peg$currPos); - - throw peg$buildStructuredError( - [peg$otherExpectation(description)], - input.substring(peg$savedPos, peg$currPos), - location - ); - } - function error(message, location) { location = location !== undefined ? location diff --git a/src/pegjs.config.js b/src/pegjs.config.js index d3750fd..ad69748 100644 --- a/src/pegjs.config.js +++ b/src/pegjs.config.js @@ -12,4 +12,12 @@ module.exports = { }, + features: { + + offset: false, + range: false, + expected: false, + + }, + };