Commit graph

289084 commits

Author SHA1 Message Date
bors
6b00bc3880 Auto merge of #142918 - cuviper:stable-next, r=cuviper
[stable] Prepare Rust 1.88.0 release

- **Sync RELEASES.md from master**
- **Update channel to stable**

r? cuviper
2025-06-23 19:24:54 +00:00
Josh Stone
df9ee7c416 Update channel to stable 2025-06-23 10:03:40 -07:00
Josh Stone
1ed85419e3 Sync RELEASES.md from master 2025-06-23 10:03:01 -07:00
bors
32084cfdf6 Auto merge of #142791 - cuviper:beta-next, r=cuviper
[beta] backports

- Make the assertion in `Ident::new` debug-only. rust-lang/rust#140880
- Avoid creating an empty identifer in `Symbol::to_ident_string`. rust-lang/rust#141318
- Backport rust-lang/stdarch#1818 for 1.88 rust-lang/rust#142694
- [beta] Clippy backport rust-lang/rust#142725
    - ICE:
        - https://github.com/rust-lang/rust-clippy/pull/14776
    - Lint contradictions:
        - https://github.com/rust-lang/rust-clippy/pull/14703
        - https://github.com/rust-lang/rust-clippy/pull/14810
    - Smaller (in LoC changes) fixes:
        - https://github.com/rust-lang/rust-clippy/pull/14733
        - https://github.com/rust-lang/rust-clippy/pull/14730
-  [win][ci] Update LLVM toolchain used to build LLVM to 20 rust-lang/rust#140757

r? cuviper
2025-06-21 02:05:24 +00:00
Daniel Paoliello
1a6321405a [win] Update LLVM toolchain used to build LLVM to 20
(cherry picked from commit 036b5fcb02)
2025-06-20 16:18:49 -07:00
Alejandra González
124ec117a9 Fix ICE in missing_const_for_fn (rust-lang/rust-clippy#14776)
The `mir_drops_elaborated_and_const_checked` query result has been
stolen already and cannot be borrowed again. Use the `optimized_mir`
query result instead.

changelog: [`missing_const_for_fn`]: fix ICE with some compilation
options

Fixes rust-lang/rust-clippy#14774

r? @Jarcho
2025-06-20 10:01:19 -07:00
Alejandra González
2ec328fec2 needless_borrow: do not contradict dangerous_implicit_autorefs (rust-lang/rust-clippy#14810)
Rust 1.88 introduces the `dangerous_implicit_autorefs` lint which warns
about using implicit autorefs on a place obtained from a raw pointer, as
this may create aliasing issues.

Prevent `clippy::needless_borrow` from triggering in this case, by
disabling the lint when taking a reference on a raw pointer dereference.
There might be a better way for doing this in the long run with a finer
way of distinguish the problematic cases, but this will prevent Clippy
from contradicting the compiler in the meantime.

Fixes rust-lang/rust-clippy#14743

changelog: [`needless_borrow`]: do not contradict the compiler's
`dangerous_implicit_autorefs` lint even though the refererences are not
mandatory

@rustbot label +beta-nominated

<!-- TRIAGEBOT_START -->

<!-- TRIAGEBOT_SUMMARY_START -->


- [Beta nomination for
1.88](https://github.com/rust-lang/rust-clippy/pull/14810#issuecomment-2883753957)
by [samueltardieu](https://github.com/samueltardieu)

Generated by triagebot, see
[help](https://forge.rust-lang.org/triagebot/note.html) for how to add
more
<!--
TRIAGEBOT_SUMMARY_DATA_START$${"entries_by_url":{"https://github.com/rust-lang/rust-clippy/pull/14810#issuecomment-2883753957":{"title":"Beta
nomination for
1.88","comment_url":"https://github.com/rust-lang/rust-clippy/pull/14810#issuecomment-2883753957","author":"samueltardieu"}}}$$TRIAGEBOT_SUMMARY_DATA_END
-->

<!-- TRIAGEBOT_SUMMARY_END -->
<!-- TRIAGEBOT_END -->
2025-06-20 10:01:19 -07:00
Samuel Tardieu
fd334c7d6b remove superseded lints (rust-lang/rust-clippy#14703)
changelog: [`transmute_float_to_int, transmute_int_to_char,
transmute_int_to_float`, `transmute_num_to_bytes`]: remove lints, now in
rustc

these lints are now mostly in rustc, so they dont need to be in clippy
anymore

https://github.com/rust-lang/rust/pull/136083#discussion_r2009897120

pending https://github.com/rust-lang/rust/pull/140431:
transmute_int_to_bool

<!-- TRIAGEBOT_START -->

<!-- TRIAGEBOT_SUMMARY_START -->

- ["Rust version of new lints should be checked" by
@samueltardieu](https://github.com/rust-lang/rust-clippy/pull/14703#issuecomment-2861982576)

Generated by triagebot, see
[help](https://forge.rust-lang.org/triagebot/note.html) for how to add
more
<!--
TRIAGEBOT_SUMMARY_DATA_START$${"entries_by_url":{"https://github.com/rust-lang/rust-clippy/pull/14703#issuecomment-2861982576":{"title":"Rust
version of new lints should be
checked","comment_url":"https://github.com/rust-lang/rust-clippy/pull/14703#issuecomment-2861982576","author":"samueltardieu"}}}$$TRIAGEBOT_SUMMARY_DATA_END
-->

<!-- TRIAGEBOT_SUMMARY_END -->
<!-- TRIAGEBOT_END -->
2025-06-20 10:01:19 -07:00
Samuel Tardieu
569e9ec628 Fix collapsible_if FP on block stmt before expr (rust-lang/rust-clippy#14730)
Closes rust-lang/rust-clippy#14722

changelog: [`collapsible_if`] fix FP on block stmt before expr
2025-06-20 10:01:19 -07:00
Alex Macleod
9fec7f0c94 Don't warn about unloaded crates (rust-lang/rust-clippy#14733)
Fixes
https://github.com/rust-lang/rust-clippy/pull/14397#issuecomment-2848328221

r? @samueltardieu

changelog: Don't warn about clippy.toml disallowed paths for crates that
were not loaded
2025-06-20 10:01:19 -07:00
Amanieu d'Antras
c0900b8919 Backport rust-lang/stdarch#1818 for 1.88 2025-06-20 09:36:25 -07:00
Nicholas Nethercote
e5fe68da52 Avoid creating an empty identifer in Symbol::to_ident_string.
Because that causes an assertion failure in debug builds.

Fixes #140884.

(cherry picked from commit 1cc0e38fdc)
2025-06-17 10:30:39 -07:00
Nicholas Nethercote
281a202470 Make the assertion in Ident::new debug-only.
This fixes a perf regression introduced in #140252.

(cherry picked from commit 4cb9f0309d)
2025-06-17 10:30:33 -07:00
bors
f5534dad0e Auto merge of #142423 - cuviper:beta-next, r=cuviper
[beta] backports

- x86 (32/64): go back to passing SIMD vectors by-ptr rust-lang/rust#141309
- use correct edition when warning for unsafe attributes rust-lang/rust#142261

r? cuviper
2025-06-13 08:10:18 +00:00
Folkert de Vries
6f3443d5db use correct edition when warning for unsafe attributes
If an attribute is re-emitted by a macro, the incorrect edition was used to emit warnings for unsafe attributes

(cherry picked from commit 2c8257493d)
2025-06-12 09:41:53 -07:00
Ralf Jung
490bc3e154 abi_check: tweak some comments
(cherry picked from commit f01bbfc5e7)
2025-06-12 09:41:46 -07:00
Ralf Jung
f84d99cf09 x86 (32/64): go back to passing SIMD vectors by-ptr
(cherry picked from commit 321db85fb4)
2025-06-12 09:41:44 -07:00
bors
645b44edd3 Auto merge of #141745 - cuviper:beta-next, r=cuviper
[beta] backports

- Update to LLVM 20.1.5 rust-lang/rust#141063

r? cuviper
2025-06-01 21:43:29 +00:00
dianqk
1460957ff1 Update to LLVM 20.1.5
(cherry picked from commit c7a2694a80)
2025-05-29 12:34:21 -07:00
bors
95597e848d Auto merge of #141412 - cuviper:beta-next, r=Mark-Simulacrum
[beta] backports and stage0 bump

- bump stage0 to 1.87.0
- Update the edition guide for let chains rust-lang/rust#140852
- Fix download of GCC from CI on non-nightly channels rust-lang/rust#140901
- Revert "Fix linking statics on Arm64EC rust-lang/rust#140176" rust-lang/rust#141024
- [win][arm64] Remove 'Arm64 Hazard' undocumented MSVC option and instead disable problematic test rust-lang/rust#141045
- Do not call name() on rpitit assoc_item rust-lang/rust#141308
- Temporarily use Windows Server 2022 instead of Windows Server 2025 images rust-lang/rust#141023
- Use Docker cache from the current repository rust-lang/rust#141280
- Move dist-x86_64-linux CI job to GitHub temporarily rust-lang/rust#141388
- ci: prepare aws access keys for migration rust-lang/rust#141389
- Add bors environment to CI rust-lang/rust#141323
-  ci: split dist-arm-linux job rust-lang/rust#141078

r? cuviper
2025-05-25 17:56:48 +00:00
MarcoIeni
5257f89f89 ci: split dist-arm-linux job 2025-05-25 09:02:29 -04:00
Jakub Beránek
1718bb2037 Add bors environment to CI
This will be used to access secrets once we move off rust-lang-ci.
2025-05-24 20:10:51 -04:00
MarcoIeni
53458c89ce ci: prepare aws access keys for migration
(cherry picked from commit 806cd12f56)
2025-05-24 09:34:05 -07:00
Jakub Beránek
b3094a53bd Move dist-x86_64-linux CI job to GitHub temporarily
To make it easier to migrate off the `rust-lang-ci/rust` repository.

(cherry picked from commit 7d32303574)
2025-05-24 09:33:42 -07:00
Jakub Beránek
eafa0f9b23 Use Docker cache from the current repository
This is needed to make the cache work after moving CI from the `rust-lang-ci` org to `rust-lang`.

(cherry picked from commit eb530325f0)
2025-05-24 09:33:30 -07:00
Jieyou Xu
1272ff814f Temporarily use Windows Server 2022 instead of Windows Server 2025 images
At the moment, it seems like Windows Server 2025 20250504.1.0 is
misconfigured causing insufficient disk space failures. Temporarily go
back to Windows Server 2022 in the hope that those are not also
misconfigured.

(cherry picked from commit f4ce73ede2)
2025-05-23 08:13:37 -07:00
Santiago Pastorino
14acce0cb6 Do not call name() on rpitit assoc_item
(cherry picked from commit 66d47c1687)
2025-05-22 15:42:11 -07:00
Daniel Paoliello
542e61c21b [win][arm64] Remove 'Arm64 Hazard' undocumented MSVC option and instead disable problematic test
(cherry picked from commit 6128fca0b0)
2025-05-22 15:39:23 -07:00
Jieyou Xu
fcdcea758e Revert "Fix linking statics on Arm64EC #140176"
Unfortunately, multiple people are reporting linker warnings related to
`__rust_no_alloc_shim_is_unstable` after this change. The solution isn't
quite clear yet, let's revert to green for now, and try a reland with a
determined solution for `__rust_no_alloc_shim_is_unstable`.

This reverts commit c8b7f32434, reversing
changes made to 667247db71.

(cherry picked from commit 734a5b1aa7)
2025-05-22 15:39:14 -07:00
Jakub Beránek
e39669866a Fix download of GCC from CI on non-nightly channels
(cherry picked from commit 448b7afb32)
2025-05-22 15:39:08 -07:00
est31
e6d3581214 Update the edition guide for let chains
(cherry picked from commit 577e82f71b)
2025-05-22 15:39:04 -07:00
Josh Stone
e5f05b964c bump stage0 2025-05-22 15:38:46 -07:00
bors
5dadfd5c41 Auto merge of #140918 - pietroalbini:pa-backport-140902, r=pietroalbini
Backport #140902 to beta

This PR backports #140902 to the beta branch, to unblock the stage0 bump.

r? `@ghost`
2025-05-11 12:31:37 +00:00
Andrew Zhogin
b166e65184
Async drop fix for async_drop_in_place<T> layout calculated for unspecified T 2025-05-11 10:42:22 +02:00
bors
1960d28b1c Auto merge of #140897 - weihanglo:update-beta-cargo, r=weihanglo
[beta-1.88] Update cargo

1 commits in 7918c7eb59614c39f1c4e27e99d557720976bdd7..873a0649350c486caf67be772828a4f36bb4734c
2025-04-27 09:44:23 +0000 to 2025-05-10 06:10:32 -0500
- [beta-1.88] fix(rustc): Don't panic on unknown bins (rust-lang/cargo#15515)

r? ghost
2025-05-10 23:53:31 +00:00
Weihang Lo
add3d33678
[beta-1.88] Update cargo 2025-05-10 11:21:25 -04:00
bors
be8721b77b Auto merge of #140861 - pietroalbini:pa-beta, r=pietroalbini
[beta] Prepare 1.88.0 beta

https://forge.rust-lang.org/release/process.html#beta-pr

r? `@ghost`
2025-05-09 17:18:29 +00:00
Pietro Albini
d63d8e5b77
bump channel to beta 2025-05-09 18:20:18 +02:00
Pietro Albini
43ba3ae70a
update version placeholders 2025-05-09 18:20:01 +02:00
bors
da1e442ebd Auto merge of #140838 - Zalathar:rollup-13hybry, r=Zalathar
Rollup of 5 pull requests

Successful merges:

 - #140801 (Use span before macro expansion in lint for-loops-over-falibles)
 - #140804 (add signed ints to unn- transmutes to ensure feature parity)
 - #140812 (Fix `tests/rustdoc-json` triagebot message path)
 - #140817 (bootstrap: more consistent use of `...` when citing configuration snippets)
 - #140828 (Enable non-leaf Frame Pointers for Arm64 Windows)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-05-09 08:31:19 +00:00
Stuart Cook
d91e86e963
Rollup merge of #140828 - dpaoliello:arm64fp, r=workingjubilee
Enable non-leaf Frame Pointers for Arm64 Windows

Microsoft recommends enabling frame pointers for Arm64 Windows as it enables fast stack walking, from <https://learn.microsoft.com/en-us/cpp/build/arm64-windows-abi-conventions?view=msvc-170#integer-registers>:

> The frame pointer (x29) is required for compatibility with fast stack walking used by ETW and other services. It must point to the previous {x29, x30} pair on the stack.

I'm setting this to "non-leaf" as leaf functions shouldn't be spilling registers and so won't touch the frame pointer.
2025-05-09 16:25:06 +10:00
Stuart Cook
e3873f51a1
Rollup merge of #140817 - RalfJung:bootstrap-msg, r=jieyouxu
bootstrap: more consistent use of `...` when citing configuration snippets
2025-05-09 16:25:05 +10:00
Stuart Cook
c922eb9a9d
Rollup merge of #140812 - jieyouxu:typo-fix, r=aDotInTheVoid
Fix `tests/rustdoc-json` triagebot message path

r? ```@aDotInTheVoid```
2025-05-09 16:25:05 +10:00
Stuart Cook
16ca18d1da
Rollup merge of #140804 - bend-n:signed, r=lcnr
add signed ints to unn- transmutes to ensure feature parity

i forgot a few cases https://github.com/rust-lang/rust-clippy/pull/14703/#pullrequestreview-2824194994

adds

- char -> i32
-  i32 -> char
- float -> size ()
-  size -> float
-   i32 -> float
``@rustbot`` label L-unnecessary_transmutes
2025-05-09 16:25:04 +10:00
Stuart Cook
b165a4c280
Rollup merge of #140801 - xizheyin:issue-140747, r=SparrowLii
Use span before macro expansion in lint for-loops-over-falibles

Fixes #140747

I think there are going to be a lot of cases where macros are expanded in the compiler resulting in span offsets, and I'd like to know how that's typically handled. Does it have to be handled specially every time?
2025-05-09 16:25:03 +10:00
bors
a7b1b24587 Auto merge of #140252 - nnethercote:rm-Ident-empty, r=oli-obk
Remove `Ident::empty`

All uses have been removed. And it's nonsensical: an identifier by definition has at least one char.

r? `@oli-obk`
2025-05-09 05:16:40 +00:00
Nicholas Nethercote
0984db553d Remove Ident::empty.
All uses have been removed. And it's nonsensical: an identifier by
definition has at least one char.

The commits adds an is-non-empty assertion to `Ident::new` to enforce
this, and converts some `Ident` constructions to use `Ident::new`.
Adding the assertion requires making `Ident::new` and
`Ident::with_dummy_span` non-const, which is no great loss.

The commit amends a couple of places that do path splitting to ensure no
empty identifiers are created.
2025-05-09 13:57:49 +10:00
bors
c8b7f32434 Auto merge of #140176 - dpaoliello:arm64ecdec, r=wesleywiser
Fix linking statics on Arm64EC

Arm64EC builds recently started to fail due to the linker not finding a symbol:
```
symbols.o : error LNK2001: unresolved external symbol #_ZN3std9panicking11EMPTY_PANIC17hc8d2b903527827f1E (EC Symbol)
          C:\Code\hello-world\target\arm64ec-pc-windows-msvc\debug\deps\hello_world.exe : fatal error LNK1120: 1 unresolved externals
```

It turns out that `EMPTY_PANIC` is a new static variable that was being exported then imported from the standard library, but when exporting LLVM didn't prepend the name with `#` (as only functions are prefixed with this character), whereas Rust was prefixing with `#` when attempting to import it.

The fix is to have Rust not prefix statics with `#` when importing.

Adding tests discovered another issue: we need to correctly mark static exported from dylibs with `DATA`, otherwise MSVC's linker assumes they are functions and complains that there is no exit thunk for them.

CI found another bug: we only apply `DllImport` to non-local statics that aren't foreign items (i.e., in an `extern` block), that is we want to use `DllImport` for statics coming from other Rust crates. However, `__rust_no_alloc_shim_is_unstable` is a static generated by the Rust compiler if required, but downstream crates consider it a foreign item since it is declared in an `extern "Rust"` block, thus they do not apply `DllImport` to it and so fails to link if it is exported by the previous crate as `DATA`. The fix is to apply `DllImport` to foreign items that are marked with the `rustc_std_internal_symbol` attribute (i.e., we assume they aren't actually foreign and will be in some Rust crate).

Fixes #138541

---
try-job: dist-aarch64-msvc
try-job: dist-x86_64-msvc
try-job: x86_64-msvc-1
try-job: x86_64-msvc-2
2025-05-09 00:43:28 +00:00
bors
667247db71 Auto merge of #140818 - matthiaskrgr:rollup-5eaotr2, r=matthiaskrgr
Rollup of 8 pull requests

Successful merges:

 - #140095 (Eliminate `word_and_empty` methods.)
 - #140341 (Clarify black_box warning a bit)
 - #140684 (Only include `dyn Trait<Assoc = ...>` associated type bounds for `Self: Sized` associated types if they are provided)
 - #140707 (Structurally normalize in range pattern checking in HIR typeck)
 - #140716 (Improve `-Zremap-path-scope` tests with dependency)
 - #140800 (Make `rustdoc-tempdir-removal` run-make tests work on other platforms than linux)
 - #140802 (Add release notes for 1.87.0)
 - #140811 (Enable triagebot note functionality for rust-lang/rust)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-05-08 21:32:19 +00:00
Daniel Paoliello
d951c41a68 Enable non-leaf Frame Pointers for Arm64 Windows 2025-05-08 13:18:18 -07:00