Skip to content

Conversation

@jhpratt
Copy link
Member

@jhpratt jhpratt commented Jan 22, 2026

Successful merges:

r? @ghost

Create a similar rollup

Mark-Simulacrum and others added 12 commits January 20, 2026 21:17
Support slices in type reflection

Tracking issue: rust-lang#146922

This PR adds support for inspecting slices `[T]` through type reflection. It does so by adding the new `Slice` struct + variant, which is very similar to `Array` but without the `len` field:

```rust
pub struct Slice {
    pub element_ty: TypeId,
}
```

Here is an example reflecting a slice:

```rust
match const { Type::of::<[u8]>() }.kind {
    TypeKind::Slice(slice) => assert_eq!(slice.element_ty, TypeId::of::<u8>()),
    _ => unreachable!(),
}
```

In addition to this, I also re-arranged the type info unit tests.

r? @oli-obk
…hanBrouwer

Port `#![crate_type]` to the attribute parser

Tracking issue: rust-lang#131229

~~Note that the actual parsing that is used in the compiler session is unchanged, as it must happen very early on; this just ports the validation logic.~~

Also added `// tidy-alphabetical-start` to `check_attr.rs` to make it a bit less conflict-prone
…=enthropy7

Improve error message for assert!() macro in functions returning bool

Detect `assert!()` macro in error messages and provide clearer diagnostics

When `assert!()` is used in a function returning a value, show a message explaining that `assert!()` doesn't return a value, instead of the generic "if may be missing an else clause" error.

Fixes rust-lang#151446
@rust-bors rust-bors bot added the rollup A PR which is a rollup label Jan 22, 2026
@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. 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-clippy Relevant to the Clippy team. 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-release Relevant to the release subteam, which will review and decide on the PR/issue. labels Jan 22, 2026
@jhpratt
Copy link
Member Author

jhpratt commented Jan 22, 2026

@bors r+ rollup=never p=4

@rust-bors
Copy link
Contributor

rust-bors bot commented Jan 22, 2026

📌 Commit d43b667 has been approved by jhpratt

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 Jan 22, 2026
@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 Jan 22, 2026
@rust-bors
Copy link
Contributor

rust-bors bot commented Jan 22, 2026

☀️ Test successful - CI
Approved by: jhpratt
Duration: 3h 17m 52s
Pushing d29e478 to main...

@rust-bors rust-bors bot merged commit d29e478 into rust-lang:main Jan 22, 2026
12 checks passed
@rustbot rustbot added this to the 1.95.0 milestone Jan 22, 2026
@jhpratt jhpratt deleted the rollup-kUkiF2m branch January 22, 2026 10:52
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#151118 Support slices in type reflection eebf022b59dbe68eb002c88fc0b4d1beee1efc8f (link)
#151439 Bump bootstrap compiler to 1.94 b14373737b01f96d7d70de26ca8717549310bddc (link)
#151442 Port #![crate_type] to the attribute parser d888ff871ca019d721bdb5b75dcde64a6fca4c96 (link)
#151457 Improve error message for assert!() macro in functions retu… ca3659f272d7a6e8f6094e6c96e148b4eb32abbf (link)

previous master: b765963267

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
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 b765963 (parent) -> d29e478 (this PR)

Test differences

Show 93 test diffs

Stage 0

  • errors::verify_interface_unsupported_crate_type_for_codegen_backend_18: [missing] -> pass (J1)
  • errors::verify_interface_unsupported_crate_type_for_target_19: [missing] -> pass (J1)
  • errors::verify_session_failed_to_create_profiler_50: [missing] -> pass (J1)
  • errors::verify_session_failed_to_create_profiler_52: pass -> [missing] (J1)
  • errors::verify_session_function_return_requires_x86_or_x86_64_44: [missing] -> pass (J1)
  • errors::verify_session_function_return_requires_x86_or_x86_64_46: pass -> [missing] (J1)
  • errors::verify_session_function_return_thunk_extern_requires_non_large_code_model_45: [missing] -> pass (J1)
  • errors::verify_session_function_return_thunk_extern_requires_non_large_code_model_47: pass -> [missing] (J1)
  • errors::verify_session_incompatible_linker_flavor_43: [missing] -> pass (J1)
  • errors::verify_session_incompatible_linker_flavor_45: pass -> [missing] (J1)
  • errors::verify_session_indirect_branch_cs_prefix_requires_x86_or_x86_64_46: [missing] -> pass (J1)
  • errors::verify_session_indirect_branch_cs_prefix_requires_x86_or_x86_64_48: pass -> [missing] (J1)
  • errors::verify_session_soft_float_deprecated_52: [missing] -> pass (J1)
  • errors::verify_session_soft_float_deprecated_54: pass -> [missing] (J1)
  • errors::verify_session_soft_float_ignored_51: [missing] -> pass (J1)
  • errors::verify_session_soft_float_ignored_53: pass -> [missing] (J1)
  • errors::verify_session_unexpected_builtin_cfg_53: [missing] -> pass (J1)
  • errors::verify_session_unexpected_builtin_cfg_55: pass -> [missing] (J1)
  • errors::verify_session_unsupported_crate_type_for_codegen_backend_43: pass -> [missing] (J1)
  • errors::verify_session_unsupported_crate_type_for_target_44: pass -> [missing] (J1)
  • errors::verify_session_unsupported_reg_struct_return_arch_49: [missing] -> pass (J1)
  • errors::verify_session_unsupported_reg_struct_return_arch_51: pass -> [missing] (J1)
  • errors::verify_session_unsupported_regparm_47: [missing] -> pass (J1)
  • errors::verify_session_unsupported_regparm_49: pass -> [missing] (J1)
  • errors::verify_session_unsupported_regparm_arch_48: [missing] -> pass (J1)
  • errors::verify_session_unsupported_regparm_arch_50: pass -> [missing] (J1)

Stage 1

  • errors::verify_interface_unsupported_crate_type_for_codegen_backend_18: [missing] -> pass (J0)
  • errors::verify_interface_unsupported_crate_type_for_target_19: [missing] -> pass (J0)
  • errors::verify_session_failed_to_create_profiler_50: [missing] -> pass (J0)
  • errors::verify_session_failed_to_create_profiler_52: pass -> [missing] (J0)
  • errors::verify_session_function_return_requires_x86_or_x86_64_44: [missing] -> pass (J0)
  • errors::verify_session_function_return_requires_x86_or_x86_64_46: pass -> [missing] (J0)
  • errors::verify_session_function_return_thunk_extern_requires_non_large_code_model_45: [missing] -> pass (J0)
  • errors::verify_session_function_return_thunk_extern_requires_non_large_code_model_47: pass -> [missing] (J0)
  • errors::verify_session_incompatible_linker_flavor_43: [missing] -> pass (J0)
  • errors::verify_session_incompatible_linker_flavor_45: pass -> [missing] (J0)
  • errors::verify_session_indirect_branch_cs_prefix_requires_x86_or_x86_64_46: [missing] -> pass (J0)
  • errors::verify_session_indirect_branch_cs_prefix_requires_x86_or_x86_64_48: pass -> [missing] (J0)
  • errors::verify_session_soft_float_deprecated_52: [missing] -> pass (J0)
  • errors::verify_session_soft_float_deprecated_54: pass -> [missing] (J0)
  • errors::verify_session_soft_float_ignored_51: [missing] -> pass (J0)
  • errors::verify_session_soft_float_ignored_53: pass -> [missing] (J0)
  • errors::verify_session_unexpected_builtin_cfg_53: [missing] -> pass (J0)
  • errors::verify_session_unexpected_builtin_cfg_55: pass -> [missing] (J0)
  • errors::verify_session_unsupported_crate_type_for_codegen_backend_43: pass -> [missing] (J0)
  • errors::verify_session_unsupported_crate_type_for_target_44: pass -> [missing] (J0)
  • errors::verify_session_unsupported_reg_struct_return_arch_49: [missing] -> pass (J0)
  • errors::verify_session_unsupported_reg_struct_return_arch_51: pass -> [missing] (J0)
  • errors::verify_session_unsupported_regparm_47: [missing] -> pass (J0)
  • errors::verify_session_unsupported_regparm_49: pass -> [missing] (J0)
  • errors::verify_session_unsupported_regparm_arch_48: [missing] -> pass (J0)
  • errors::verify_session_unsupported_regparm_arch_50: pass -> [missing] (J0)
  • [ui] tests/ui/attributes/crate-type-non-crate.rs: [missing] -> pass (J1)
  • [ui] tests/ui/expr/if/assert-macro-without-else.rs: [missing] -> pass (J1)
  • mem::type_info::test_slices: [missing] -> pass (J3)

Stage 2

  • [ui] tests/ui/attributes/crate-type-non-crate.rs: [missing] -> pass (J2)
  • [ui] tests/ui/expr/if/assert-macro-without-else.rs: [missing] -> pass (J2)
  • mem::type_info::test_slices: [missing] -> pass (J4)

Additionally, 35 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 d29e4783dff30f9526eeba3929ebfe86c00c9dad --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. dist-x86_64-apple: 6393.7s -> 8794.0s (+37.5%)
  2. tidy: 180.4s -> 217.1s (+20.4%)
  3. dist-aarch64-apple: 7945.4s -> 9208.7s (+15.9%)
  4. x86_64-gnu-llvm-21-1: 4097.7s -> 4674.6s (+14.1%)
  5. aarch64-msvc-2: 6428.8s -> 5674.5s (-11.7%)
  6. aarch64-apple: 9415.1s -> 10504.7s (+11.6%)
  7. dist-x86_64-llvm-mingw: 6865.4s -> 7648.9s (+11.4%)
  8. aarch64-gnu: 7193.4s -> 7946.0s (+10.5%)
  9. test-various: 6901.0s -> 7613.2s (+10.3%)
  10. dist-ohos-aarch64: 4915.0s -> 4428.0s (-9.9%)
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
Collaborator

Finished benchmarking commit (d29e478): comparison URL.

Overall result: ✅ improvements - no action needed

@rustbot label: -perf-regression

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
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.3% [-0.8%, -0.0%] 5
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary -1.4%, secondary -4.3%)

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)
-1.4% [-1.9%, -0.9%] 2
Improvements ✅
(secondary)
-4.3% [-4.8%, -3.8%] 2
All ❌✅ (primary) -1.4% [-1.9%, -0.9%] 2

Cycles

Results (secondary -2.6%)

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.6% [-2.9%, -2.2%] 2
All ❌✅ (primary) - - 0

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 473.6s -> 472.528s (-0.23%)
Artifact size: 383.21 MiB -> 383.22 MiB (0.00%)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-attributes Area: Attributes (`#[…]`, `#![…]`) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. merged-by-bors This PR was explicitly merged by bors. rollup A PR which is a rollup T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-clippy Relevant to the Clippy team. 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-release Relevant to the release subteam, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants