mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-28 07:30:57 +00:00
53059792e9
Add new lint to warn when #[must_use] attribute should be used on a method This lint is somewhat similar to https://rust-lang.github.io/rust-clippy/master/index.html#must_use_candidate but also different: it emits a warning by default and only targets methods (so not functions nor associated functions). Someone suggested it to me after this tweet: https://twitter.com/m_ou_se/status/1466439813230477312 I think it would reduce the number of cases of API misuses quite a lot. What do you think? --- changelog: Added new [`return_self_not_must_use`] lint |
||
---|---|---|
.. | ||
cargo | ||
ui | ||
ui-cargo | ||
ui-internal | ||
ui-toml | ||
ui_test | ||
clippy.toml | ||
compile-test.rs | ||
dogfood.rs | ||
fmt.rs | ||
integration.rs | ||
lint_message_convention.rs | ||
missing-test-files.rs | ||
versioncheck.rs |