Replies: 1 comment
-
Sorry for the late response! The current decode/unmarshal API does provide location information on errors. When an error occurs, the parser tries to emit a The direct AST API does not provide this facility. It returns a I'm open to exposing it on the unstable API, even not just for errors (for any node). The easiest path is probably to extract the code that turns a computes the location from a Lines 238 to 252 in 58a592b Happy to review a PR! |
Beta Was this translation helpful? Give feedback.
-
Hello!
I'm building a rudimentary frontmatter linter for markdown and am using this library to support TOML. I am trying to provide additional context for users by giving the Line/Col numbers of the error. Looking through the issues I can see that this behavior was removed in v1
Looking through the existing code, it looks like even the AST that was recently exposed under unstable sub package doesn't even track that information.
I guess my two questions are:
Beta Was this translation helpful? Give feedback.
All reactions