-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Remove unused #[must_use]
#145274
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove unused #[must_use]
#145274
Conversation
r? @wesleywiser rustbot has assigned @wesleywiser. Use |
Some changes occurred in compiler/rustc_passes/src/check_attr.rs |
@@ -133,4 +135,5 @@ fn main() { | |||
} | |||
let s = PatternField { #[must_use] foo: 123 }; //~ ERROR `#[must_use]` has no effect | |||
let PatternField { #[must_use] foo } = s; //~ ERROR `#[must_use]` has no effect | |||
let _ = foo; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@run-rustfix
requires that all warnings are gone, and foo
is unused, so I'm suppressing it here.
Thenks!~ r? fmease @bors r+ rollup |
This comment has been minimized.
This comment has been minimized.
@bors r- |
Will bless when I am back at my computer |
6c571e7
to
2c0409c
Compare
@bors r+ |
Rollup of 11 pull requests Successful merges: - #143467 (Add ASCII-related methods from `u8` and `MIN`/`MAX` to `core::ascii::Char`) - #144519 (Constify `SystemTime` methods) - #144642 (editorconfig: don't trim trailing whitespace in tests) - #144870 (Stabilize `path_file_prefix` feature) - #145269 (Deprecate RUST_TEST_* env variables) - #145274 (Remove unused `#[must_use]`) - #145289 (chore(ci): upgrade checkout to v5) - #145303 (Docs: Link to payload_as_str() from payload().) - #145308 (Adjust documentation of `dangling`) - #145320 (Allow cross-compiling the Cranelift dist component) - #145325 (Add `cast_init` and `cast_uninit` methods for pointers) r? `@ghost` `@rustbot` modify labels: rollup
Self-explanatory
Fixes #145257