-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Mark "unused binding" suggestion as maybe incorrect #120470
Conversation
r? @cjgillot (rustbot has picked a reviewer for you, use r? to override) |
@bors r+ rollup |
Should we do this with TryPrefixSugg too? |
yeah would prefer that one too @bors r- |
Done. @bors r=compiler-errors |
…rrors Mark "unused binding" suggestion as maybe incorrect Ignoring unused bindings should be a determination made by a human, `rustfix` shouldn't auto-apply the suggested change. Fix rust-lang#54196.
This comment has been minimized.
This comment has been minimized.
@bors r=compiler-errors |
…rrors Mark "unused binding" suggestion as maybe incorrect Ignoring unused bindings should be a determination made by a human, `rustfix` shouldn't auto-apply the suggested change. Fix rust-lang#54196.
…iaskrgr Rollup of 8 pull requests Successful merges: - rust-lang#120207 (check `RUST_BOOTSTRAP_CONFIG` in `profile_user_dist` test) - rust-lang#120321 (pattern_analysis: cleanup the contexts) - rust-lang#120346 (hir: Refactor getters for owner nodes) - rust-lang#120396 (Account for unbounded type param receiver in suggestions) - rust-lang#120435 (Suggest name value cfg when only value is used for check-cfg) - rust-lang#120470 (Mark "unused binding" suggestion as maybe incorrect) - rust-lang#120495 (Remove the `abi_amdgpu_kernel` feature) - rust-lang#120501 (rustdoc: Correctly handle attribute merge if this is a glob reexport) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 8 pull requests Successful merges: - rust-lang#120207 (check `RUST_BOOTSTRAP_CONFIG` in `profile_user_dist` test) - rust-lang#120321 (pattern_analysis: cleanup the contexts) - rust-lang#120346 (hir: Refactor getters for owner nodes) - rust-lang#120396 (Account for unbounded type param receiver in suggestions) - rust-lang#120435 (Suggest name value cfg when only value is used for check-cfg) - rust-lang#120470 (Mark "unused binding" suggestion as maybe incorrect) - rust-lang#120495 (Remove the `abi_amdgpu_kernel` feature) - rust-lang#120501 (rustdoc: Correctly handle attribute merge if this is a glob reexport) r? `@ghost` `@rustbot` modify labels: rollup
…rrors Mark "unused binding" suggestion as maybe incorrect Ignoring unused bindings should be a determination made by a human, `rustfix` shouldn't auto-apply the suggested change. Fix rust-lang#54196.
Rollup of 12 pull requests Successful merges: - rust-lang#120207 (check `RUST_BOOTSTRAP_CONFIG` in `profile_user_dist` test) - rust-lang#120321 (pattern_analysis: cleanup the contexts) - rust-lang#120323 (On E0277 be clearer about implicit `Sized` bounds on type params and assoc types) - rust-lang#120355 (document `FromIterator for Vec` allocation behaviors) - rust-lang#120396 (Account for unbounded type param receiver in suggestions) - rust-lang#120430 (std: thread_local::register_dtor fix proposal for FreeBSD.) - rust-lang#120435 (Suggest name value cfg when only value is used for check-cfg) - rust-lang#120470 (Mark "unused binding" suggestion as maybe incorrect) - rust-lang#120472 (Make duplicate lang items fatal) - rust-lang#120490 (Don't hash lints differently to non-lints.) - rust-lang#120495 (Remove the `abi_amdgpu_kernel` feature) - rust-lang#120501 (rustdoc: Correctly handle attribute merge if this is a glob reexport) Failed merges: - rust-lang#120346 (hir: Refactor getters for owner nodes) r? `@ghost` `@rustbot` modify labels: rollup
This is failing some cargo tests. Run
EDIT: raced while I was trying to reproduce x) |
Just looked into this. This is inconvenient. I found the test changes that I need to make, but I would have to land a disabling of the tests in the cargo repo, then update the cargo remote, merge this, and then reenable the tests, right? |
`rustc` will start marking the suggestions for prefacing unused bindings with underscores as "maybe incorrect", which makes them no longer auto applicable by `rustfix`. Change done at rust-lang/rust#120470.
Change tests to support changes to suggestion `rustc` will start marking the suggestions for prefacing unused bindings with underscores as "maybe incorrect", which makes them no longer auto applicable by `rustfix`. Change done at rust-lang/rust#120470.
Can't you commit the cargo changes in this PR directly? That's how we do it with clippy and rust-analyzer. |
@Nadrieril clippy and rust-analyzer both live in repo and get merged, while cargo is a sub-repo, so commits to it need to be upstreamed first. Thankfully, @weihanglo is on the case and already merged my test changes to the cargo repo and has a PR up to update the subrepo, so this PR shouldn't linger for too long. |
Ignoring unused bindings should be a determination made by a human, `rustfix` shouldn't auto-apply the suggested change. Fix rust-lang#54196.
@bors r=compiler-errors |
…rrors Mark "unused binding" suggestion as maybe incorrect Ignoring unused bindings should be a determination made by a human, `rustfix` shouldn't auto-apply the suggested change. Fix rust-lang#54196.
…iaskrgr Rollup of 8 pull requests Successful merges: - rust-lang#119162 (Add unstable `-Z direct-access-external-data` cmdline flag for `rustc`) - rust-lang#119592 (resolve: Unload speculatively resolved crates before freezing cstore) - rust-lang#120103 (Make it so that async-fn-in-trait is compatible with a concrete future in implementation) - rust-lang#120455 ( Add FileCheck annotations to MIR-opt SROA tests) - rust-lang#120470 (Mark "unused binding" suggestion as maybe incorrect) - rust-lang#120619 (Assert that params with the same *index* have the same *name*) - rust-lang#120633 (pattern_analysis: gather up place-relevant info) - rust-lang#120726 (Don't use bashism in checktools.sh) r? `@ghost` `@rustbot` modify labels: rollup
…rrors Mark "unused binding" suggestion as maybe incorrect Ignoring unused bindings should be a determination made by a human, `rustfix` shouldn't auto-apply the suggested change. Fix rust-lang#54196.
Rollup of 13 pull requests Successful merges: - rust-lang#110482 (Add armv8r-none-eabihf target for the Cortex-R52.) - rust-lang#119162 (Add unstable `-Z direct-access-external-data` cmdline flag for `rustc`) - rust-lang#120302 (various const interning cleanups) - rust-lang#120455 ( Add FileCheck annotations to MIR-opt SROA tests) - rust-lang#120470 (Mark "unused binding" suggestion as maybe incorrect) - rust-lang#120479 (Suggest turning `if let` into irrefutable `let` if appropriate) - rust-lang#120564 (coverage: Split out counter increment sites from BCB node/edge counters) - rust-lang#120633 (pattern_analysis: gather up place-relevant info) - rust-lang#120664 (Add parallel rustc ui tests) - rust-lang#120721 (fix `llvm_out` to use the correct LLVM root) - rust-lang#120726 (Don't use bashism in checktools.sh) - rust-lang#120733 (MirPass: make name more const) - rust-lang#120735 (Remove some `unchecked_claim_error_was_emitted` calls) Failed merges: - rust-lang#120727 (exhaustiveness: Prefer "`0..MAX` not covered" to "`_` not covered") r? `@ghost` `@rustbot` modify labels: rollup
Rollup of 13 pull requests Successful merges: - rust-lang#110482 (Add armv8r-none-eabihf target for the Cortex-R52.) - rust-lang#119162 (Add unstable `-Z direct-access-external-data` cmdline flag for `rustc`) - rust-lang#120302 (various const interning cleanups) - rust-lang#120455 ( Add FileCheck annotations to MIR-opt SROA tests) - rust-lang#120470 (Mark "unused binding" suggestion as maybe incorrect) - rust-lang#120479 (Suggest turning `if let` into irrefutable `let` if appropriate) - rust-lang#120564 (coverage: Split out counter increment sites from BCB node/edge counters) - rust-lang#120633 (pattern_analysis: gather up place-relevant info) - rust-lang#120664 (Add parallel rustc ui tests) - rust-lang#120726 (Don't use bashism in checktools.sh) - rust-lang#120733 (MirPass: make name more const) - rust-lang#120735 (Remove some `unchecked_claim_error_was_emitted` calls) - rust-lang#120746 (Record coroutine kind in coroutine generics) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#120470 - estebank:issue-54196, r=compiler-errors Mark "unused binding" suggestion as maybe incorrect Ignoring unused bindings should be a determination made by a human, `rustfix` shouldn't auto-apply the suggested change. Fix rust-lang#54196.
`rustc` will start marking the suggestions for prefacing unused bindings with underscores as "maybe incorrect", which makes them no longer auto applicable by `rustfix`. Change done at rust-lang/rust#120470.
`rustc` will start marking the suggestions for prefacing unused bindings with underscores as "maybe incorrect", which makes them no longer auto applicable by `rustfix`. Change done at rust-lang/rust#120470.
Ignoring unused bindings should be a determination made by a human,
rustfix
shouldn't auto-apply the suggested change.Fix #54196.