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 thiserror for implementing custom error types #44

Closed
ngutech21 opened this issue Nov 8, 2023 · 2 comments
Closed

Use thiserror for implementing custom error types #44

ngutech21 opened this issue Nov 8, 2023 · 2 comments

Comments

@ngutech21
Copy link
Contributor

Instead of implementing the From-trait manually, I would recommend using thiserror crate https://docs.rs/thiserror/latest/thiserror/
This would get rid of most of the boilerplate code in the error types.

@thesimplekid
Copy link
Collaborator

Initially I did this to avoid a dependency, however I think you're right that using thiserror makes sense to avoid the boilerplate. So I will change this.

@thesimplekid
Copy link
Collaborator

Complete in:

61cfd5d
99dd07e
660c767
f85df73

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants