In fact, this PR changes nothing for users but removes some boilerplate code. Therefore, it is okay to close this PR. It is rather a minor recommendation for the future.
The change uses the trick from rustdoc's documentation: As of Rust 1.34 we can omit the fn main() -> Result<...> when an Ok::<...>(()) is returned.
Note:Box<dyn std::error::Error> is already semantically equal to CatchAll.
In fact, this PR changes nothing for users but removes some boilerplate code. Therefore, it is okay to close this PR. It is rather a minor recommendation for the future.
The change uses the trick from
rustdoc
's documentation: As of Rust 1.34 we can omit thefn main() -> Result<...>
when anOk::<...>(())
is returned.Note:
Box<dyn std::error::Error>
is already semantically equal toCatchAll
.