Re:Overview of Rust error handling libraries
by nemothekid on Friday November 22, 2019 @03:50PM
(#21609927)
I used to do this as well, but I came across thiserror (which is featured in the article), which is just macros that do exactly this and nothing more.
It's certainly less transparent, but I prefer this method of error handling, and writing out the Impls manually can get out of hand (as well as having to adding new fields to the enum).
It's usually not much more code than I would have written with an error handling library and it's fully transparent, understandable for anyone with a rudimentary understanding of Rust. And I get to have one less dependency.