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

Use enum variants for errors #4

Closed
Ploppz opened this issue Mar 24, 2017 · 1 comment
Closed

Use enum variants for errors #4

Ploppz opened this issue Mar 24, 2017 · 1 comment
Labels

Comments

@Ploppz
Copy link
Member

Ploppz commented Mar 24, 2017

In the code, we often describe errors with &'static str, e.g. bail!("Read past boundary of given contents.");. I find this convenient when the code is unstable or under rewrite, as we have yet to decide on the enum variants of ErrorKind in err.rs.

At some point, we should go through the code and see what enum variants we need to have in ErrorKind, and use those instead of str, so as to accommodate for applications to do pattern matching on errors.

@s3bk
Copy link
Contributor

s3bk commented Jul 26, 2019

closing with #25

@s3bk s3bk closed this as completed Jul 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants