An Early Exit Error happens when the parser cannot detect the first mandatory iteration of a repetition. It corresponds to a failed {@link Parser.AT_LEAST_ONE} or {@link Parser.AT_LEAST_ONE_SEP} in Chevrotain DSL terms.
The actual sequence of tokens encountered.
A user may provide custom error message descriptor in the {@link Parser.AT_LEAST_ONE} DSL method options parameter, this is that custom message.
The valid (expected) paths in the first iteration.
The previous Token "instance". This is useful if options.actual[0] is of type chevrotain.EOF and you need to know the last token parsed.
The rule in which the error occurred.
A No Viable Alternative Error happens when the parser cannot detect any valid alternative in an alternation. It corresponds to a failed {@link Parser.OR} in Chevrotain DSL terms.
The actual sequence of tokens encountered.
A user may provide custom error message descriptor in the {@link Parser.AT_LEAST_ONE} DSL method options parameter, this is that custom message.
First level of the array represents each alternative The next two levels represent valid (expected) paths in each alternative.
The previous Token "instance". This is useful if options.actual[0] is of type chevrotain.EOF and you need to know the last token parsed.
The rule in which the error occurred.
A Redundant Input Error happens when the parser has completed parsing but there is still unprocessed input remaining.
The first unprocessed token "instance".
The rule in which the error occurred.
Generated using TypeDoc
A set of methods used to customize parsing error messages. Call defaultParserErrorProvider to implement the default behavior