Closed bcmyers closed 5 years ago
Is there a reason apart from failure
that Error
and ErrorKind
are distinct types?
Splitting Error and ErrorKind is a very common pattern because it permits flexibility on the internal representation of an Error.
Since
failure
is a public dependency, you might consider dropping it. While the future is a bit unclear, I'm pretty sure it doesn't involvefailure 0.1
, so dropping it now will be easier for you than dropping it later. I don't think you need to replace it with anything either. You don't have that many error types, so writing out the impls by hand shouldn't be a burden.(You might also consider flattening your module structure. A deeply nested crate with such a small API doesn't seem worth it IMO.)