by gsserge · 5y ago · 0 comments
This could be a problem if you want to use a third-party API where generic functions or structs use std::error::Error in their trait bounds. For example, fn use_error<E: std::error::Error>(e: E) { ... } will not compile with a boxed error as the parameter.
[1] https://users.rust-lang.org/t/shouldnt-box-t-where-t-error-i...
No comments yet.