Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

distinguish between our bugs and the user's bugs #237

Open
gelisam opened this issue Apr 21, 2024 · 0 comments
Open

distinguish between our bugs and the user's bugs #237

gelisam opened this issue Apr 21, 2024 · 0 comments
Labels
error-messages improve the error messages

Comments

@gelisam
Copy link
Owner

gelisam commented Apr 21, 2024

We use the same type EvalError for bugs in the Haskell implementation of Klister and for bugs in the user's .kl code. It would probably make more sense to separate them, for example by making the implementation's bug print "the impossible happened, please report this as a bug", or just calling error :: string -> a to make it clear that they should never happen.

Currently, EvalError contains a mix of both kinds of errors:

  • EvalErrorUnbound: impossible
  • EvalErrorType: impossible
  • EvalErrorCase: user error, e.g. (case (nil))
  • EvalErrorUser: user error, e.g. (error '"oops")
  • EvalErrorIdent: impossible
@gelisam gelisam added the error-messages improve the error messages label Apr 21, 2024
@gelisam gelisam mentioned this issue Apr 22, 2024
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
error-messages improve the error messages
Projects
None yet
Development

No branches or pull requests

1 participant