[−][src]Crate lisbeth_error
Lisbeth-error
A dead-simple error type for the lisbeth parser infrastructure.
The types in this crate should be used in that order:
- an
ErrorReporter
is created from input, - a
SpannedStr
is created from theErrorReporter
, - parsing happens on that
SpannedStr
, - tokens are produced, they store their position with a
Span
, - when an error occurs, an error is reported with an
AnnotatedError
, - this error is formatted by the
ErrorReporter
declared previously, which returns aFormattedError
, - the
FormattedError
is printed on the console.
An example of usage can be found in the handbook module.
Modules
error | An error report with annotations |
handbook | A simple example explaining how to parse input data and emit errors. |
reporter | Allows to report errors to the user. |
span | Some span data structures |