You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error reporting. Everything is very handy. Even without the path.
Bad for?
Source mapping:
Requires path, and for start and end to be file offsets.
IR:
Not every error producing value has a known span.
(De)serialisation prefers path indices, does not want to (de)serialise source strings.
A solution?
Remove Pest span and make the path mandatory:
Source mapping is happy.
If no path is applicable then one cannot create a Span, so the whole Span must then be Option, or we have an 'official' or 'default' empty/null Span.
IR (de)serialisation is simplified.
Make spans optional for error reporting:
IR can create errors without Spans. Note, this would hopefully be pretty rare. The IR would try very hard to provide a Span when asked but can't guarantee a Span, and therefore must be optional.
Source mapping doesn't care.
The text was updated successfully, but these errors were encountered:
Why Span?
What does Span look like now?
What is this structure currently good for?
Bad for?
A solution?
The text was updated successfully, but these errors were encountered: