I saw someone do this on a try_from today, so I figured I'd make an issue.
Repro:
#[must_use]
pub fn foo() -> Result<(), ()> { Ok(()) }
https://play.rust-lang.org/?version=nightly&mode=debug&edition=2018&gist=c03ca4925a9ac4ce9fdda4d2165e6892
The #[must_use] on the function there is unnecessary because it always returns Result, which is itself #[must_use]. So we might consider linting about that.
I saw someone do this on a
try_fromtoday, so I figured I'd make an issue.Repro:
https://play.rust-lang.org/?version=nightly&mode=debug&edition=2018&gist=c03ca4925a9ac4ce9fdda4d2165e6892
The
#[must_use]on the function there is unnecessary because it always returnsResult, which is itself#[must_use]. So we might consider linting about that.