Skip to content

Rollup of 16 pull requests - #161399

Closed
JonathanBrouwer wants to merge 49 commits into
rust-lang:mainfrom
JonathanBrouwer:rollup-pgMyu6e
Closed

Rollup of 16 pull requests#161399
JonathanBrouwer wants to merge 49 commits into
rust-lang:mainfrom
JonathanBrouwer:rollup-pgMyu6e

Conversation

@JonathanBrouwer

Copy link
Copy Markdown
Member

Successful merges:

r? @ghost

Create a similar rollup

Axel Rousselot and others added 30 commits July 6, 2026 18:21
Adds the `desktop` method to the Windows `CommandExt` trait to enable
setting the `lpDesktop` field of the STARTUPINFO passed to the Windows
`CreateProcess` API call.
I wasn't able to find a test that verifies different behavior based on
whether or not overflow checks are available, so add one here.
This would have been useful to have while debugging a problem in cg_clif.
When a macro call like `vec![]` appears in type position, the compiler's
"use `=` if you meant to assign" suggestion was pointing into the macro
definition in stdlib instead of the user's own code.

The suggestion span was computed as `stmt.pat.span.between(hir_ty.span)`.
After expansion `hir_ty.span` lies inside the macro body, so that span
crossed syntax contexts and the renderer displayed the stdlib location.

Compute the span via `find_ancestor_in_same_ctxt` instead, so the pattern
and the type are compared in a common syntax context. When no common
context exists -- e.g. the `let` comes from a macro body while the pattern
is a call-site metavariable -- no suggestion is emitted at all.
There are only three impls of `Qualif`, and the extra explicitness is
clearer.
Items with implicit `pub(self)` visibility in the crate root are effectively
`pub(crate)`, which causes friction when trying to move them elsewhere.
This intermediate commit helps to preserve line history.
Change from the existing behavior of panicking unconditionally to
panicking only if debug assertions are enabled, wrapping otherwise. This
is more consistent with other operations, and gives slightly better
codegen [1].

Suggested in the stabilization PR, RUST-161015.

[1]: https://rust.godbolt.org/z/Yz81zhbno
Configure LLM policy URL for triagebot

Implemented in rust-lang/triagebot#2486, documented in rust-lang/rust-forge#1099.

CC @jyn514

r? Urgau
@rust-bors rust-bors Bot added the rollup A PR which is a rollup label Aug 20, 2026
@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) A-bootstrap-stamp Area: bootstrap stamp logic A-CI Area: Our Github Actions CI A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-meta Area: Issues & PRs about the rust-lang/rust repository itself A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-unix Operating system: Unix-like O-windows Operating system: Windows S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue. labels Aug 20, 2026
@JonathanBrouwer

Copy link
Copy Markdown
Member Author

@bors r+ p=5

Trying commonly failed jobs
@bors try jobs=dist-various-1,test-various,x86_64-gnu-aux,x86_64-gnu-llvm-21-3,x86_64-msvc-1,aarch64-apple-1,aarch64-apple-2,x86_64-mingw-1,i686-msvc-1,i686-msvc-2

@rust-bors

rust-bors Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 9f8402b has been approved by JonathanBrouwer

It is now in the queue for this repository.

🌲 The tree is currently closed for pull requests below priority 10. This pull request will be tested once the tree is reopened.

Reason for tree closure: Main branch is broken

@rust-bors rust-bors Bot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 20, 2026
@rust-bors

rust-bors Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

⌛ Trying commit 9f8402b with merge 7fa0181

To cancel the try build, run the command @bors try cancel.

Workflow: https://github.com/rust-lang/rust/actions/runs/32377677788

rust-bors Bot pushed a commit that referenced this pull request Aug 20, 2026
Rollup of 16 pull requests


try-job: dist-various-1
try-job: test-various
try-job: x86_64-gnu-aux
try-job: x86_64-gnu-llvm-21-3
try-job: x86_64-msvc-1
try-job: aarch64-apple-1
try-job: aarch64-apple-2
try-job: x86_64-mingw-1
try-job: i686-msvc-1
try-job: i686-msvc-2
@rust-log-analyzer

Copy link
Copy Markdown
Collaborator

The job test-various failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
[RUSTC-TIMING] core test:false 17.842
error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:235:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 235 | |             let _ = <$T>::funnel_shl(A, B, A);
     | |                     ----------------       ^ expected `u32`, found `u128`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u128.rs:1:1
     |
   1 |   uint_module!(u128);
     |   ------------------ in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:567:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 567 | |         pub const fn funnel_shl(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
1380 | |     }
     | |_____- in this macro invocation
help: you can convert a `u128` to a `u32` and panic if the converted value doesn't fit
     |
 235 |             let _ = <$T>::funnel_shl(A, B, A.try_into().unwrap());
     |                                             ++++++++++++++++++++

error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:241:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 241 | |             let _ = <$T>::funnel_shr(A, B, B);
     | |                     ----------------       ^ expected `u32`, found `u128`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u128.rs:1:1
     |
   1 |   uint_module!(u128);
     |   ------------------ in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:638:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 638 | |         pub const fn funnel_shr(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
1380 | |     }
     | |_____- in this macro invocation
help: you can convert a `u128` to a `u32` and panic if the converted value doesn't fit
     |
 241 |             let _ = <$T>::funnel_shr(A, B, B.try_into().unwrap());
     |                                             ++++++++++++++++++++

error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:235:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 235 | |             let _ = <$T>::funnel_shl(A, B, A);
     | |                     ----------------       ^ expected `u32`, found `u16`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u16.rs:1:1
     |
   1 |   uint_module!(u16);
     |   ----------------- in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:567:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 567 | |         pub const fn funnel_shl(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
1258 | |     }
     | |_____- in this macro invocation
help: you can convert a `u16` to a `u32`
     |
 235 |             let _ = <$T>::funnel_shl(A, B, A.into());
     |                                             +++++++

error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:241:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 241 | |             let _ = <$T>::funnel_shr(A, B, B);
     | |                     ----------------       ^ expected `u32`, found `u16`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u16.rs:1:1
     |
   1 |   uint_module!(u16);
     |   ----------------- in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:638:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 638 | |         pub const fn funnel_shr(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
1258 | |     }
     | |_____- in this macro invocation
help: you can convert a `u16` to a `u32`
     |
 241 |             let _ = <$T>::funnel_shr(A, B, B.into());
     |                                             +++++++

error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:235:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 235 | |             let _ = <$T>::funnel_shl(A, B, A);
     | |                     ----------------       ^ expected `u32`, found `u64`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u64.rs:1:1
     |
   1 |   uint_module!(u64);
     |   ----------------- in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:567:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 567 | |         pub const fn funnel_shl(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
1346 | |     }
     | |_____- in this macro invocation
help: you can convert a `u64` to a `u32` and panic if the converted value doesn't fit
     |
 235 |             let _ = <$T>::funnel_shl(A, B, A.try_into().unwrap());
     |                                             ++++++++++++++++++++

error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:241:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 241 | |             let _ = <$T>::funnel_shr(A, B, B);
     | |                     ----------------       ^ expected `u32`, found `u64`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u64.rs:1:1
     |
   1 |   uint_module!(u64);
     |   ----------------- in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:638:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 638 | |         pub const fn funnel_shr(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
1346 | |     }
     | |_____- in this macro invocation
help: you can convert a `u64` to a `u32` and panic if the converted value doesn't fit
     |
 241 |             let _ = <$T>::funnel_shr(A, B, B.try_into().unwrap());
     |                                             ++++++++++++++++++++

error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:235:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 235 | |             let _ = <$T>::funnel_shl(A, B, A);
     | |                     ----------------       ^ expected `u32`, found `u8`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u8.rs:1:1
     |
   1 |   uint_module!(u8);
     |   ---------------- in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:567:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 567 | |         pub const fn funnel_shl(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
 610 | |     }
     | |_____- in this macro invocation
help: you can convert a `u8` to a `u32`
     |
 235 |             let _ = <$T>::funnel_shl(A, B, A.into());
     |                                             +++++++

error[E0308]: mismatched types
    --> library/coretests/tests/num/uint_macros.rs:241:44
     |
   1 | / macro_rules! uint_module {
   2 | |     ($T:ident) => {
   3 | |         use core::num::ParseIntError;
   4 | |         use core::ops::{BitAnd, BitOr, BitXor, Not, Shl, Shr};
...    |
 241 | |             let _ = <$T>::funnel_shr(A, B, B);
     | |                     ----------------       ^ expected `u32`, found `u8`
     | |                     |
     | |                     arguments to this function are incorrect
...    |
 840 | |     };
 841 | | }
     | |_- in this expansion of `uint_module!`
     |
    ::: library/coretests/tests/num/u8.rs:1:1
     |
   1 |   uint_module!(u8);
     |   ---------------- in this macro invocation
     |
note: method defined here
    --> library/core/src/num/uint_macros.rs:638:22
     |
   1 | / macro_rules! uint_impl {
   2 | |     (
   3 | |         Self = $SelfT:ty,
   4 | |         ActualT = $ActualT:ident,
...    |
 638 | |         pub const fn funnel_shr(self, right: Self, n: u32) -> Self {
     | |                      ^^^^^^^^^^
...    |
4410 | | }
     | |_- in this expansion of `uint_impl!`
     |
---
 610 | |     }
     | |_____- in this macro invocation
help: you can convert a `u8` to a `u32`
     |
 241 |             let _ = <$T>::funnel_shr(A, B, B.into());
     |                                             +++++++

For more information about this error, try `rustc --explain E0308`.
[RUSTC-TIMING] coretests test:true 41.157
error: could not compile `coretests` (test "coretests") due to 8 previous errors

@rust-bors rust-bors Bot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Aug 20, 2026
@rust-bors

rust-bors Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

PR #161204, which is a member of this rollup, was unapproved.

This rollup was thus unapproved.

@rustbot rustbot removed the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Aug 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-attributes Area: Attributes (`#[…]`, `#![…]`) A-bootstrap-stamp Area: bootstrap stamp logic A-CI Area: Our Github Actions CI A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-meta Area: Issues & PRs about the rust-lang/rust repository itself A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-unix Operating system: Unix-like O-windows Operating system: Windows rollup A PR which is a rollup T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.