Rollup of 11 pull requests#155552
Conversation
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.
…=jieyouxu bootstrap: Make "detected modifications" for download-rustc less verbose cc https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/bootstrap.20lists.20all.20files.20I.20change/with/585991706, @RalfJung r? @jieyouxu
This comment has been minimized.
This comment has been minimized.
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
This comment has been minimized.
This comment has been minimized.
|
📌 Perf builds for each rolled up PR:
previous master: 91367b0f73 In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
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 differencesShow 740 test diffsStage 1
Stage 2
Additionally, 716 doctest diffs were found. These are ignored, as they are noisy. Job group index
Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard c28e3037785af39226f5751294ed1c6cf4698e10 --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
Finished benchmarking commit (c28e303): comparison URL. Overall result: ❌✅ regressions and improvements - please read:Our benchmarks found a performance regression caused by this PR. Next Steps:
@rustbot label: +perf-regression Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
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.
CyclesResults (secondary -2.8%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeResults (secondary 0.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 491.23s -> 491.853s (0.13%) |
|
One tiny regression in @rustbot label: +perf-regression-triaged |
Successful merges:
std::io::ErrorKindtocore::io#154654 (Movestd::io::ErrorKindtocore::io)user_arg_indexnomenclature more broadly #154895 (borrowck: Applyuser_arg_indexnomenclature more broadly)single_use_lifetimes: respectanonymous_lifetime_in_impl_trait#155346 (single_use_lifetimes: respectanonymous_lifetime_in_impl_trait)#[link_section]API inherited from LLVM #155517 (Add a test for Mach-O#[link_section]API inherited from LLVM)non-camel-case-typeslint #154772 (slightly optimize thenon-camel-case-typeslint)#[rust_analyzer::prefer_underscore_import]to the traits inrustc_type_ir::inherent#155541 (Add#[rust_analyzer::prefer_underscore_import]to the traits inrustc_type_ir::inherent)r? @ghost
Create a similar rollup