grmtools icon indicating copy to clipboard operation
grmtools copied to clipboard

Error span improvements

Open ratmice opened this issue 3 years ago • 0 comments

In pr #299 which adds spans to various Error types, the Spans returned are based off of the existing offset data from which we can derive a line & column. As it is we currently always return a span where start == end, since it is just getting us to the desired semver ABI.

  1. SemVer compatible changes (after we add Spans to Errors): After that PR we could include in the error more information from the parse functions into YaccParserError and LexBuildError. This may require some reorganization of the various private parse functions.
  2. Potential SemVer incompatible changes (after we add Spans to Errors): YaccErrorKind, and LexErrorKind could sometimes have useful additional spans, for instance LexErrorKind::DuplicateName Could have a span pointing to the first occurrence of the duplicate entry.
  • [ ] SemVer compatible improvements
  • [x] SemVer incompatible improvements

ratmice avatar Jun 05 '22 15:06 ratmice