-
Notifications
You must be signed in to change notification settings - Fork 13.3k
[beta] Clippy beta backport #140810
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
[beta] Clippy beta backport #140810
Conversation
[beta] Prepare Rust 1.87.0 r? ghost
[beta] bump stage0
…nglo [beta-1.87] Update cargo 1 commits in a6c604d1b8a2f2a8ff1f3ba6092f9fda42f4b7e9..202515849e943032d8fdd3eba57bf2c86e0da736 2025-03-26 18:11:00 +0000 to 2025-04-06 19:30:58 -0400 - [beta-1.87] chore: Bump cargo-util-schemas to 0.8.1 (rust-lang/cargo#15402) r? ghost
This reverts commit 60e4a1b.
[beta] Revert "Remove `prev_index_to_index` field from `CurrentDepGraph`" This reverts rust-lang#138824 on beta to fix issues with incremental compilation in that PR. rust-lang#139410 will fix these on master. r? `@oli-obk`
(cherry picked from commit a91e97c)
(cherry picked from commit fff2484)
(cherry picked from commit f9927ee)
(cherry picked from commit cfcc47e)
Signed-off-by: Petros Angelatos <[email protected]> (cherry picked from commit 9eb6a54)
This PR is fixing a regression introduced by rust-lang#121646 that can lead to a double free when dropping the channel. The details of the bug can be found in the corresponding crossbeam PR crossbeam-rs/crossbeam#1187 Signed-off-by: Petros Angelatos <[email protected]> (cherry picked from commit b9e2ac5)
[beta] backports - Fix 2024 edition doctest panic output rust-lang#139328 - make `Arguments::as_statically_known_str` doc(hidden) rust-lang#139389 - Revert "Deduplicate template parameter creation" rust-lang#139878 - sync::mpsc: prevent double free on `Drop` rust-lang#139553 r? cuviper
…g param-env for receiver_is_dispatchable (cherry picked from commit 4f2baaa)
This commit fixes a false positive of the warning triggered for rust-lang#138762 and the fix is to codify that zero-sized types are "safe" in both the old and new ABIs. (cherry picked from commit f9091e2)
This has other warnings if necessary and doesn't need extra warnings from this FCW. cc rust-lang#138762 (cherry picked from commit 19e44d4)
(cherry picked from commit 16da97b)
Beta-backporting rust-lang#140228 has the same effect on this test as rust-lang#139341 already had on master.
[beta] backports - Do not mix normalized and unnormalized caller bounds when constructing param-env for `receiver_is_dispatchable` rust-lang#138941 - Ignore zero-sized types in wasm future-compat warning rust-lang#139498 - Don't warn about `v128` in wasm ABI transition rust-lang#139809 - Revert overzealous parse recovery for single colons in paths rust-lang#140228 r? cuviper
[beta] Delay `hash_extract_if` stabilization from 1.87 to 1.88 This PR is a revert of: - rust-lang#134655 for use in the event that we are unable to get rust-lang#139764 into 1.87 (current beta).
(cherry picked from commit cc791eb)
(cherry picked from commit 56426db)
(cherry picked from commit b1a3831)
(cherry picked from commit 3536324)
(cherry picked from commit 81438c0)
(cherry picked from commit 714ea10)
Signed-off-by: onur-ozkan <[email protected]> (cherry picked from commit 7b25d4a)
[beta] backports - Don't allow flattened format_args in const. rust-lang#139624 - set subsections_via_symbols for ld64 helper sections rust-lang#139752 - Fix detection of `main` function if there are expressions around it rust-lang#140220 - rustdoc: Fix doctest heuristic for main fn wrapping rust-lang#140420 - extend the list of registered dylibs on `test::prepare_cargo_test` rust-lang#140563 r? cuviper
…nglo [beta-1.87] Update cargo 1 commits in 202515849e943032d8fdd3eba57bf2c86e0da736..99624be96e9d213b0e9b1e36451271f24e4a41d8 2025-04-06 19:30:58 -0400 to 2025-05-06 19:28:33 -0500 - [beta-1.87] fix(rustc): Don't panic on unknown bins (rust-lang/cargo#15500)
Fixes rust-lang/rust-clippy#14660 changelog: none
…st-lang#14568) Fixes rust-lang/rust-clippy#14449, introduced in rust-lang#14314 changelog: [`map_entry`]: fix a false positive where the lint would trigger without any insert calls present
We do not want to remove casts done inside macros. Also, when printing the suggestion, take it from the same context as the origin expression (the root context). Problems found while working on rust-lang#14526, but should be merged even if rust-lang#14526 is not. changelog: none
`ptr_eq` was recently enhanced to lint on more cases of raw pointers comparison: - lint on all raw pointer comparison, by proposing to use `[core|std]::ptr::eq(lhs, rhs)` instead of `lhs == rhs`; - removing one symetric `as usize` on each size if needed - peeling any level of `as *[const|mut] _` if the remaining expression can still be coerced into the original one (i.e., is a ref or raw pointer to the same type as before) The current change restricts the lint to the cases where at least one level of symetric `as usize`, or any conversion to a raw pointer, could be removed. For example, a direct comparaison of two raw pointers will not trigger the lint anymore. changelog: [`ptr_eq`]: do not lint when comparing two raw pointers directly with no casts involved Fixes rust-lang/rust-clippy#14525
Some changes occurred in src/tools/clippy cc @rust-lang/clippy |
☔ The latest upstream changes (presumably #140838) made this pull request unmergeable. Please resolve the merge conflicts. |
I'll directly include this in the stable PR (doing it earlier than usual this cycle). The next beta just branched: will this need to be backported in 1.88 beta too? |
No, all those commits were already on |
Ok, folded this into #140859 |
[stable] Prepare the 1.87.0 release Preparing the stable artifacts as described in the release process. This PR also includes the following last minute backports: * rust-lang#140810 * rust-lang#140601 * rust-lang#140684 r? `@ghost`
[stable] Prepare the 1.87.0 release Preparing the stable artifacts as described in the release process. This PR also includes the following last minute backports: * rust-lang#140810 * rust-lang#140601 * rust-lang#140684 r? `@ghost`
Backports:
manual_ok_err
: don't lint subpatterns rust-clippy#14661ptr_eq
triggers rust-clippy#14526The first 2 PRs are 2 small fixes. Those alone would probably not warrant a backport, but we would rather fix those sooner than later.
The main backport is the last PR, with the prior PR introducing more improvements on top. This fixes rust-lang/rust-clippy#14525, an issue that got introduced by a too eager lint that was added in beta 1.87. This would be annoying for Clippy users, if this would hit stable.
r? @Mark-Simulacrum