Nice error reporting #36
Labels
No Label
accepted
bug
clj
documentation
enhancement
errors
infrastructure
later
next
now
optimization
proposal
question
research
semantics
syntax
ux
vm
wontfix
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: twc/ludus#36
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Stand up a system of presenting errors from the scanner, parser, validator, and interpreter that are useful for users (and me!).
Do these things:
Write an
errors.janet
that's responsible for outputting nice errorsProduce the offending line
With a caret underneath that shows where the error is
And a more helpful (gentle) error message than what is produced in error objects
Add suggestions where helpful:
Suggest bound names with an unbound name error
Show actual place a name is bound one a name rebinding error
Show function arities with arity mismatch
Try to give a helpful reason for pattern mismatches
Trace a
panic!
's return path (instead of a stack trace, which is erased with TCO)Consider producing issues for each of these things
On suggested names, this is what we want: https://en.wikipedia.org/wiki/Levenshtein_distance