Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Rollup of 11 pull requests#155552

Merged
rust-bors[bot] merged 25 commits into
rust-lang:mainrust-lang/rust:mainfrom
JonathanBrouwer:rollup-JKIpTuWJonathanBrouwer/rust:rollup-JKIpTuWCopy head branch name to clipboard
Apr 20, 2026
Merged

Rollup of 11 pull requests#155552
rust-bors[bot] merged 25 commits into
rust-lang:mainrust-lang/rust:mainfrom
JonathanBrouwer:rollup-JKIpTuWJonathanBrouwer/rust:rollup-JKIpTuWCopy head branch name to clipboard

Conversation

@JonathanBrouwer

Copy link
Copy Markdown
Contributor

Successful merges:

r? @ghost

Create a similar rollup

lms0806 and others added 25 commits March 24, 2026 15:56
resolve :  mark repr_simd as internal

resolve : move repr_simd

resolve : move repr_simd
under linkage

resolve : move repr_simd
under pattern_types

resolve :  mark repr_simd as internal

resolve : move repr_simd

resolve : move repr_simd
under linkage

resolve : move repr_simd
under pattern_types
No change in behavior. Only renames and a couple of added comments.
Certain links will not be valid when moved into `core::io`
* Checking exhaustion will no longer be possible for `repr_bitpacked`. Moving `kind_from_prim` into an associated function, and setting it up to be moved into `core::io` as well.
* `ErrorKind::as_str` is private, but it's only usage is trivially replaced with `Display::fmt`
* The features io_error_inprogress, io_error_more, and io_error_uncategorized will all need to be enabled
…stc_type_ir::inherent`

This is a new attribute that instructs rust-analyzer to prefer importing the trait `as _`. It is useful for these traits
since their names often clashes with the type.
Move `std::io::ErrorKind` to `core::io`
* Update `rustdoc-html` tests for the new path
* Add `core_io` feature to control stability. This replaces the use of `core_io_borrowed_buf` on the `core::io` module itself.
* Re-export `core::io::ErrorKind` in `std::io::error`
We have a number of structs with more lifetimes than necessary. This
commit removes them.

LLM disclosure: I asked Claude Code to check for unnecessary lifetimes
in all types with three or more lifetimes, and it produced a list of
candidates (half of which were invalid). I did the modifications for the
valid cases myself, and found a couple more cases along the way.
The logic determining whether the relevant function is marked as `#[track_caller]`
only worked with functions that could be resolved to a concrete instance, which default
trait methods cannot. We need to check the codegen attribute on the default method itself.

Co-authored-by: Folkert de Vries <folkert@folkertdev.nl>
That they are all ordered inside the module and not more private than the module itself
The `import_decl_vis` logic is reused when reporting `ambiguous_import_visibilities` lint
Some asserts are hardened
Some relevant tests are added
…r=Mark-Simulacrum

Move `std::io::ErrorKind` to `core::io`

ACP: rust-lang/libs-team#755
Tracking issue: rust-lang#154046
Related: rust-lang#152918

## Description

I consider rust-lang#154046 to be really important for `no_std`, but I'm concerned rust-lang#152918 might be too controversial. As an alternative, I'd like to propose starting small with `ErrorKind`, since it can be moved somewhat trivially. It has no dependencies on functionality in `std`, no platform specific behaviour, and could provide an excellent bridging point for `no_std` IO libraries.

Since `std::io::Error` implements `From<ErrorKind>`, libraries could write functions which return `Result<T, core::io::ErrorKind>`, and therefore be usable in `std`-using libraries with the `?` operator. For that reason, I'd consider this to be a worthwhile change even if the rest of `std::io` couldn't be moved to `core`/`alloc`, and entirely compatible with any efforts to make such a change in the future.

## Notes

* This is my first PR against Rust, please let me know if there's anything I should be doing that I have not done. I tried reading through the library contributors guide but I'm sure I've missed _something_.
* No AI tooling of any kind was used in the creation of this PR.
* I believe it's appropriate that this be a part of the linked tracking issue, but please let me know if that's not the case!
…apkin

Fix an ICE observed with an explicit tail-call in a default trait method

Right now, explicit tail-calls cannot be used in functions that hold the `#[track_caller]` attribute. This check is performed on a resolved concrete instance of a function, which would be absent for a tail-call performed from the body of a default trait method. This PR fixes the issue by checking for the relevant attribute in default trait methods separately, without expecting a specific resolved instance.

Closes rust-lang#144985.
…mann

borrowck: Apply `user_arg_index` nomenclature more broadly

No change in behavior. Only renames and a couple of added comments.

As requested here: rust-lang#154674 (comment)

r? jdonszelmann
resolve: Make sure visibilities of import declarations make sense

That they are all ordered inside the module and not more private than the module itself.

The `import_decl_vis` logic is also reused when reporting `ambiguous_import_visibilities` lint.
Some asserts are hardened.
Some relevant tests are added.

Extracted from rust-lang#154149.
… r=jdonszelmann

`single_use_lifetimes`: respect `anonymous_lifetime_in_impl_trait`

Tracking issue: rust-lang#44752 (for the `single_use_lifetimes` lint; the `anonymous_lifetime_in_impl_trait` feature seems to have no tracking issue).

Closes rust-lang#129255
Closes rust-lang#135550

@rustbot label A-diagnostics A-lifetimes A-lints D-incorrect L-single_use_lifetimes
…trs, r=bjorn3

Add a test for Mach-O `#[link_section]` API inherited from LLVM

The format of the `#[link_section]` attribute is under-documented, but on Mach-O, I think it's roughly the following BNF:
```
LinkSection -> Segment `,` Section (`,` (SectionType (`,` (SectionAttributes)?)?)?)?
Segment -> <0 to 16 bytes>
Section -> <0 to 16 bytes>
SectionType -> `regular` | `zerofill` | `cstring_literals` | `4byte_literals` | `8byte_literals` | `literal_pointers` | `non_lazy_symbol_pointers` | `lazy_symbol_pointers` | `symbol_stubs` | `mod_init_funcs` | `mod_term_funcs` | `coalesced` | `interposing` | `16byte_literals` | `thread_local_regular` | `thread_local_zerofill` | `thread_local_variables` | `thread_local_variable_pointers` | `thread_local_init_function_pointers`
SectionAttributes -> SectionAttribute (`+` SectionAttribute)*
SectionAttribute -> `pure_instructions` | `no_toc` | `strip_static_syms` | `no_dead_strip` | `live_support`, `self_modifying_code` | `debug`
```

This PR adds a small test for a little part of this.

Once rust-lang#154429 is resolved, this should make it possible to test rust-lang/rustc_codegen_cranelift#1648 end-to-end.

r? bjorn3
Remove some unnecessary lifetimes.

We have a number of structs with more lifetimes than necessary. This commit removes them.

LLM disclosure: I asked Claude Code to check for unnecessary lifetimes in all types with three or more lifetimes, and it produced a list of candidates (half of which were invalid). I did the modifications for the valid cases myself, and found a couple more cases along the way.

r? @JohnTitor
resolve :  mark repr_simd as internal

I changed ```repr_simd``` to ```internal``` and changed the position to ```feature-group-start: internal feature gates```.

close rust-lang#154034
…dwinwhite

slightly optimize the `non-camel-case-types` lint

This is just removing a needless `collect()` and a bit of simplification.
… r=TaKO8Ki

Add `#[rust_analyzer::prefer_underscore_import]` to the traits in `rustc_type_ir::inherent`

This is a new attribute (rust-lang/rust-analyzer#21740) that instructs rust-analyzer to prefer importing the trait `as _`. It is useful for these traits since their names often clashes with the type.
@rust-bors rust-bors Bot added the rollup A PR which is a rollup label Apr 20, 2026
@rustbot rustbot added A-run-make Area: port run-make Makefiles to rmake.rs F-explicit_tail_calls `#![feature(explicit_tail_calls)]` 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) labels Apr 20, 2026
@rustbot rustbot added T-compiler Relevant to the compiler 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-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustdoc-frontend Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output. labels Apr 20, 2026
@JonathanBrouwer

Copy link
Copy Markdown
Contributor Author

@bors r+ rollup=never 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,x86_64-mingw-1,i686-msvc-2

@rust-bors

rust-bors Bot commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 02dda73 has been approved by JonathanBrouwer

It is now in the queue for this repository.

@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 Apr 20, 2026
@rust-bors

This comment has been minimized.

rust-bors Bot pushed a commit that referenced this pull request Apr 20, 2026
Rollup of 11 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
try-job: x86_64-mingw-1
try-job: i686-msvc-2
@rust-bors

rust-bors Bot commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

☀️ Try build successful (CI)
Build commit: 0a8e76c (0a8e76c170df273e3eaa1a1e02164cf9af82da76, parent: e22c616e4e87914135c1db261a03e0437255335e)

@rust-bors

This comment has been minimized.

@rust-bors rust-bors Bot added merged-by-bors This PR was explicitly merged by bors. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Apr 20, 2026
@rust-bors

rust-bors Bot commented Apr 20, 2026

Copy link
Copy Markdown
Contributor

☀️ Test successful - CI
Approved by: JonathanBrouwer
Duration: 3h 19m 12s
Pushing c28e303 to main...

@rust-bors
rust-bors Bot merged commit c28e303 into rust-lang:main Apr 20, 2026
13 checks passed
@rust-timer

Copy link
Copy Markdown
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#145270 Fix an ICE observed with an explicit tail-call in a default… 3038ca4b48923435e4b34b8d441f6aff224459a5 (link)
#154248 resolve : mark repr_simd as internal 5ea6dbc43545ccd5a2d10eabbf97f23a5a104c90 (link)
#154654 Move std::io::ErrorKind to core::io 3f77a8fe5d41abf26bcbd7764ee0a53bb89195e5 (link)
#154772 slightly optimize the non-camel-case-types lint 23a75dc63581ebc881f013bb13cb1cea75608f0a (link)
#154895 borrowck: Apply user_arg_index nomenclature more broadly db1324b20498edd60e7eb3a1b5d66d98f3790e26 (link)
#155213 resolve: Make sure visibilities of import declarations make… 55a3042120babd9399c4fea05985ee23a35fb630 (link)
#155346 single_use_lifetimes: respect `anonymous_lifetime_in_impl… 210daf7c1bdd24ca995db0f96c140ec3993fab24 (link)
#155517 Add a test for Mach-O #[link_section] API inherited from … cc2fe00995767917a0bdf9e2d19dd83ffd07ea09 (link)
#155541 Add #[rust_analyzer::prefer_underscore_import] to the tra… 32b448d3db8c1b90be9ff1dfb6321af697cb80a9 (link)
#155544 bootstrap: Make "detected modifications" for download-rustc… d170852720decc2e09ba727be8e461d67d7e530e (link)
#155549 Remove some unnecessary lifetimes. d159940a2261d844ec8fa6f0363d882b2ec73b27 (link)

previous master: 91367b0f73

In the case of a perf regression, run the following command for each PR you suspect might be the cause: @rust-timer build $SHA

@github-actions

Copy link
Copy Markdown
Contributor
What is this? This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.

Comparing 91367b0 (parent) -> c28e303 (this PR)

Test differences

Show 740 test diffs

Stage 1

  • [run-make] tests/run-make/macho-link-section: [missing] -> ignore (only executed when the target vendor is Apple) (J0)
  • [ui] tests/ui/explicit-tail-calls/default-trait-method.rs: [missing] -> pass (J0)
  • [ui] tests/ui/feature-gates/feature-gate-io_error_kind_in_core.rs: [missing] -> pass (J0)
  • [ui] tests/ui/imports/ambiguous-import-visibility-globglob-priv-pass.rs: [missing] -> pass (J0)
  • [ui] tests/ui/imports/ambiguous-import-visibility-globglob-priv.rs: [missing] -> pass (J0)
  • [ui] tests/ui/imports/ambiguous-import-visibility-globglob.rs: [missing] -> pass (J0)
  • [ui] tests/ui/imports/private-from-decl-macro.rs#fail: [missing] -> pass (J0)
  • [ui] tests/ui/imports/private-from-decl-macro.rs#pass: [missing] -> pass (J0)
  • [ui] tests/ui/privacy/restricted/decl-macros.rs: [missing] -> pass (J0)
  • [ui] tests/ui/single-use-lifetime/anonymous_lifetime_in_impl_trait.rs#with-gate: [missing] -> pass (J0)
  • [ui] tests/ui/single-use-lifetime/anonymous_lifetime_in_impl_trait.rs#without-gate: [missing] -> pass (J0)

Stage 2

  • [ui] tests/ui/explicit-tail-calls/default-trait-method.rs: [missing] -> pass (J1)
  • [ui] tests/ui/feature-gates/feature-gate-io_error_kind_in_core.rs: [missing] -> pass (J2)
  • [ui] tests/ui/imports/ambiguous-import-visibility-globglob-priv-pass.rs: [missing] -> pass (J2)
  • [ui] tests/ui/imports/ambiguous-import-visibility-globglob-priv.rs: [missing] -> pass (J2)
  • [ui] tests/ui/imports/ambiguous-import-visibility-globglob.rs: [missing] -> pass (J2)
  • [ui] tests/ui/imports/private-from-decl-macro.rs#fail: [missing] -> pass (J2)
  • [ui] tests/ui/imports/private-from-decl-macro.rs#pass: [missing] -> pass (J2)
  • [ui] tests/ui/privacy/restricted/decl-macros.rs: [missing] -> pass (J2)
  • [ui] tests/ui/single-use-lifetime/anonymous_lifetime_in_impl_trait.rs#with-gate: [missing] -> pass (J2)
  • [ui] tests/ui/single-use-lifetime/anonymous_lifetime_in_impl_trait.rs#without-gate: [missing] -> pass (J2)
  • [run-make] tests/run-make/macho-link-section: [missing] -> ignore (only executed when the target vendor is Apple) (J3)
  • [ui] tests/ui/explicit-tail-calls/default-trait-method.rs: [missing] -> ignore (gcc backend is marked as ignore) (J4)
  • [run-make] tests/run-make/macho-link-section: [missing] -> pass (J5)

Additionally, 716 doctest diffs were found. These are ignored, as they are noisy.

Job group index

Test dashboard

Run

cargo run --manifest-path src/ci/citool/Cargo.toml -- \
    test-dashboard c28e3037785af39226f5751294ed1c6cf4698e10 --output-dir test-dashboard

And then open test-dashboard/index.html in your browser to see an overview of all executed tests.

Job duration changes

  1. x86_64-gnu-tools: 50m 23s -> 1h 7m (+34.1%)
  2. dist-ohos-armv7: 1h 21m -> 59m 56s (-26.7%)
  3. x86_64-mingw-2: 2h 10m -> 2h 45m (+26.6%)
  4. x86_64-gnu-gcc: 1h 9m -> 52m 52s (-23.5%)
  5. test-various: 2h 9m -> 1h 41m (-21.6%)
  6. armhf-gnu: 1h 29m -> 1h 10m (-21.2%)
  7. dist-i686-linux: 1h 47m -> 1h 25m (-20.7%)
  8. x86_64-gnu-stable: 2h 21m -> 1h 53m (-20.1%)
  9. dist-riscv64-linux: 1h 31m -> 1h 13m (-20.0%)
  10. dist-android: 27m 58s -> 22m 25s (-19.8%)
How to interpret the job duration changes?

Job durations can vary a lot, based on the actual runner instance
that executed the job, system noise, invalidated caches, etc. The table above is provided
mostly for t-infra members, for simpler debugging of potential CI slow-downs.

@rust-timer

Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (c28e303): comparison URL.

Overall result: ❌✅ regressions and improvements - please read:

Our benchmarks found a performance regression caused by this PR.
This might be an actual regression, but it can also be just noise.

Next Steps:

  • If the regression was expected or you think it can be justified,
    please write a comment with sufficient written justification, and add
    @rustbot label: +perf-regression-triaged to it, to mark the regression as triaged.
  • If you think that you know of a way to resolve the regression, try to create
    a new PR with a fix for the regression.
  • If you do not understand the regression or you think that it is just noise,
    you can ask the @rust-lang/wg-compiler-performance working group for help (members of this group
    were already notified of this PR).

@rustbot label: +perf-regression
cc @rust-lang/wg-compiler-performance

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
0.4% [0.4%, 0.4%] 1
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.4% [-0.8%, -0.0%] 9
All ❌✅ (primary) 0.4% [0.4%, 0.4%] 1

Max RSS (memory usage)

Results (primary 0.8%, secondary -2.3%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
1.8% [1.0%, 2.4%] 3
Regressions ❌
(secondary)
3.3% [1.1%, 6.1%] 3
Improvements ✅
(primary)
-2.5% [-2.5%, -2.5%] 1
Improvements ✅
(secondary)
-4.4% [-6.5%, -1.5%] 8
All ❌✅ (primary) 0.8% [-2.5%, 2.4%] 4

Cycles

Results (secondary -2.8%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.8% [-2.8%, -2.8%] 1
All ❌✅ (primary) - - 0

Binary size

Results (secondary 0.0%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.1% [0.1%, 0.1%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.0% [-0.1%, -0.0%] 2
All ❌✅ (primary) - - 0

Bootstrap: 491.23s -> 491.853s (0.13%)
Artifact size: 394.37 MiB -> 394.39 MiB (0.01%)

@rustbot rustbot added the perf-regression Performance regression. label Apr 20, 2026
@Kobzol

Kobzol commented Apr 21, 2026

Copy link
Copy Markdown
Member

One tiny regression in clap_derive, but overall there were more green than red results. I don't think it's worth investigating further.

@rustbot label: +perf-regression-triaged

@rustbot rustbot added the perf-regression-triaged The performance regression has been triaged. label Apr 21, 2026
@cuviper cuviper added this to the 1.97.0 milestone Apr 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-run-make Area: port run-make Makefiles to rmake.rs F-explicit_tail_calls `#![feature(explicit_tail_calls)]` merged-by-bors This PR was explicitly merged by bors. perf-regression Performance regression. perf-regression-triaged The performance regression has been triaged. 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-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustdoc-frontend Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Morty Proxy This is a proxified and sanitized view of the page, visit original site.