parjs
Version:
Library for building parsers using combinators.
22 lines • 812 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Issues = void 0;
const errors_1 = require("../errors");
/** Some canned error throwers. */
exports.Issues = {
/**
* Throws an error saying that the parser is about to enter an infinite loop.
*
* @param name
*/
guardAgainstInfiniteLoop(name) {
throw new errors_1.ParserDefinitionError(name, `The combinator '${name}' expected one of its arguments to change the parser state.`);
},
delayedParserNotInit(name) {
throw new errors_1.ParserDefinitionError(name, `Delayed parser not initalized.`);
},
delayedParserAlreadyInit() {
throw new errors_1.ParserDefinitionError("", `Delayed parser has already been initialized`);
}
};
//# sourceMappingURL=issues.js.map