Skip to content

Conversation

@JonathanBrouwer
Copy link
Contributor

Successful merges:

r? @ghost

Create a similar rollup

Muhtasim-Rasheed and others added 30 commits February 1, 2026 19:06
Requiring `fn` in the macro syntax makes it a little more obvious that the
macro declares functions with those names, and makes them easier to grep for.
…nbrouwer

Port a lot of attributes to the new parser

r? @JonathanBrouwer

See commits for which attributes
…-message, r=eholk

Add help message suggesting explicit reference cast for From/TryFrom

Closes rust-lang#109829

Improves E0277 diagnostics when a `From` or `TryFrom` implementation is expected, but the provided type is a reference that can be explicitly cast to a type the trait can convert from.
Move `impl Interner for TyCtxt` to its own submodule

This impl is several hundred lines of mostly self-contained, mostly boilerplate code that can be extracted out of the dauntingly large `rustc_middle::ty::context` module.

- The trait and its impl were introduced by rust-lang#97287.

---

There should be no change to compiler behaviour.
…ect-lifetime-diag, r=chenyukang

Modernize diagnostic for indeterminate trait object lifetime bounds

* remove suggestion from the diagnostic message (bad style, too long) and turn it into a structured suggestion
* replace *object type* with *trait object type* since the former is an outdated term
…nnethercote

Remove `SubdiagMessage` in favour of the identical `DiagMessage`

For rust-lang#151366
Just some more cleanup :)
SubdiagMessage is now identical to DiagMessage, so there's no point in having both of them
Move the needs-drop check for `arena_cache` queries out of macro code

This is slightly simpler than before, because now the macro only needs to call a single function, and can just unconditionally supply `tcx` and a typed arena.

There should be no actual change to compiler behaviour.
…nkov

typeck: Make it clearer that `check_pat_lit` only handles literal patterns

Nowadays, the `hir::PatExprKind` enum guarantees that “expressions” in patterns can only be paths or literals.

`PatExprKind::Path` is already handled by the previous match arm, so we can make this match arm explicitly match on `PatExprKind::Lit` without losing exhaustiveness.

There should be no actual change to compiler behaviour.
…mimi

Format heterogeneous try blocks

The tracking issue for `try_blocks_heterogeneous` is rust-lang#149488.

This follows the formatting of homogeneous try blocks (feature `try_blocks`) by considering `try bikeshed <type>` to be the equivalent of `try` (in particular a single "token").

An alternative would be to permit breaking between `bikeshed` and `<type>`, but given that those 2 elements are an explicitly temporary part of the syntax, it doesn't seem worth it. There also doesn't seem to be any existing precedent breaking between a keyword and a type. It also doesn't seem to be useful in practice, given that the type itself doesn't break (which is how it works for the return type of closures) and has more chances to dominate the length in case a break is necessary.

Happy to adapt anything in case this formatting is not optimal.

The test is also copied from homogeneous try blocks with 2 additional test cases to demonstrate the behavior with long types.

See [#t-lang > try blocks @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/213817-t-lang/topic/try.20blocks/near/572387493) for context.
…r=nnethercote

Update documentation of rustc_macros

Update the docs to reflect the changes in rust-lang#151366
…e, r=lcnr

Uplift `Predicate::allow_normalization` to `rustc_type_ir`

Found this FIXME comment while fixing a bug in rust-analyzer 😄
cc rust-lang/rust-analyzer#21611

r? types
…ouwer

Port #![test_runner] to the attribute parser

Tracking issue: rust-lang#131229

r? @JonathanBrouwer
@rust-bors rust-bors bot added the rollup A PR which is a rollup label Feb 10, 2026
@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) A-rustc-dev-guide Area: rustc-dev-guide A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-clippy Relevant to the Clippy team. T-compiler Relevant to the compiler 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 Feb 10, 2026
@JonathanBrouwer
Copy link
Contributor Author

@bors r+ rollup=never p=5

@rust-bors
Copy link
Contributor

rust-bors bot commented Feb 10, 2026

📌 Commit 9065f62 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 Feb 10, 2026
@rust-log-analyzer
Copy link
Collaborator

The job aarch64-gnu-llvm-20-1 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
REPOSITORY                                   TAG       IMAGE ID       CREATED       SIZE
ghcr.io/dependabot/dependabot-updater-core   latest    afc745c7535d   2 weeks ago   783MB
=> Removing docker images...
Deleted Images:
untagged: ghcr.io/dependabot/dependabot-updater-core:latest
untagged: ghcr.io/dependabot/dependabot-updater-core@sha256:faae3d3a1dedd24cde388bb506bbacc0f7ed1eae99ebac129af66acd8540c84a
deleted: sha256:afc745c7535da1bb12f92c273b9a7e9c52c3f12c5873714b2542da259c6d9769
deleted: sha256:64e147d5e54d9be8b8aa322e511cda02296eda4b8b8d063c6a314833aca50e29
deleted: sha256:5cba409bb463f4e7fa1a19f695450170422582c1bc7c0e934d893b4e5f558bc6
deleted: sha256:cddc6ebd344b0111eaab170ead1dfda24acdfe865ed8a12599a34d338fa8e28b
deleted: sha256:2412c3f334d79134573cd45e657fb6cc0abd75bef3881458b0d498d936545c8d
---
             at /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/std/src/panicking.rs:689:5
   1: core::panicking::panic_fmt
             at /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/core/src/panicking.rs:80:14
   2: rustc_attr_parsing::context::late::ATTRIBUTE_PARSERS::{closure#0}
   3: <std::sync::once::Once>::call_once_force::<<std::sync::lazy_lock::LazyLock<rustc_attr_parsing::context::GroupTypeInner<rustc_attr_parsing::context::Late>>>::force::{closure#0}>::{closure#0}
   4: std::sys::sync::once::futex::Once::call
             at /rustc/9b1f8ff42d110b0ca138116745be921df5dc97e7/library/std/src/sys/sync/once/futex.rs:178:21
   5: <rustc_attr_parsing::interface::AttributeParser<rustc_attr_parsing::context::Early>>::is_parsed_attribute
   6: <rustc_expand::expand::InvocationCollector>::check_attributes
   7: <rustc_expand::expand::InvocationCollector as rustc_ast::mut_visit::MutVisitor>::flat_map_item
   8: <thin_vec::ThinVec<alloc::boxed::Box<rustc_ast::ast::Item>> as rustc_data_structures::flat_map_in_place::FlatMapInPlace<alloc::boxed::Box<rustc_ast::ast::Item>>>::flat_map_in_place::<rustc_ast::mut_visit::visit_items<rustc_expand::expand::InvocationCollector>::{closure#0}, smallvec::SmallVec<[alloc::boxed::Box<rustc_ast::ast::Item>; 1]>>
   9: rustc_ast::mut_visit::walk_flat_map_item::<rustc_expand::expand::InvocationCollector>
  10: <alloc::boxed::Box<rustc_ast::ast::Item> as rustc_expand::expand::InvocationCollectorNode>::wrap_flat_map_node_walk_flat_map::<<rustc_expand::expand::InvocationCollector>::flat_map_node<alloc::boxed::Box<rustc_ast::ast::Item>>::{closure#1}>
  11: <rustc_expand::expand::InvocationCollector as rustc_ast::mut_visit::MutVisitor>::flat_map_item
  12: <thin_vec::ThinVec<alloc::boxed::Box<rustc_ast::ast::Item>> as rustc_data_structures::flat_map_in_place::FlatMapInPlace<alloc::boxed::Box<rustc_ast::ast::Item>>>::flat_map_in_place::<rustc_ast::mut_visit::visit_items<rustc_expand::expand::InvocationCollector>::{closure#0}, smallvec::SmallVec<[alloc::boxed::Box<rustc_ast::ast::Item>; 1]>>
  13: rustc_ast::mut_visit::walk_flat_map_item::<rustc_expand::expand::InvocationCollector>
  14: <alloc::boxed::Box<rustc_ast::ast::Item> as rustc_expand::expand::InvocationCollectorNode>::wrap_flat_map_node_walk_flat_map::<<rustc_expand::expand::InvocationCollector>::flat_map_node<alloc::boxed::Box<rustc_ast::ast::Item>>::{closure#1}>
  15: <rustc_expand::expand::InvocationCollector as rustc_ast::mut_visit::MutVisitor>::flat_map_item
  16: <thin_vec::ThinVec<alloc::boxed::Box<rustc_ast::ast::Item>> as rustc_data_structures::flat_map_in_place::FlatMapInPlace<alloc::boxed::Box<rustc_ast::ast::Item>>>::flat_map_in_place::<rustc_ast::mut_visit::visit_items<rustc_expand::expand::InvocationCollector>::{closure#0}, smallvec::SmallVec<[alloc::boxed::Box<rustc_ast::ast::Item>; 1]>>
  17: <rustc_expand::expand::InvocationCollector as rustc_ast::mut_visit::MutVisitor>::visit_crate
  18: <rustc_expand::expand::MacroExpander>::collect_invocations
  19: <rustc_expand::expand::MacroExpander>::fully_expand_fragment
  20: <rustc_expand::expand::MacroExpander>::expand_crate
  21: <rustc_session::session::Session>::time::<rustc_ast::ast::Crate, rustc_interface::passes::configure_and_expand::{closure#1}>
  22: rustc_interface::passes::resolver_for_lowering_raw
      [... omitted 2 frames ...]
  23: <rustc_middle::ty::context::TyCtxt>::resolver_for_lowering
  24: <std::thread::local::LocalKey<core::cell::Cell<*const ()>>>::with::<rustc_middle::ty::context::tls::enter_context<<rustc_middle::ty::context::GlobalCtxt>::enter<rustc_interface::passes::create_and_enter_global_ctxt<core::option::Option<rustc_interface::queries::Linker>, rustc_driver_impl::run_compiler::{closure#0}::{closure#2}>::{closure#2}::{closure#0}, core::option::Option<rustc_interface::queries::Linker>>::{closure#1}, core::option::Option<rustc_interface::queries::Linker>>::{closure#0}, core::option::Option<rustc_interface::queries::Linker>>
  25: <rustc_middle::ty::context::TyCtxt>::create_global_ctxt::<core::option::Option<rustc_interface::queries::Linker>, rustc_interface::passes::create_and_enter_global_ctxt<core::option::Option<rustc_interface::queries::Linker>, rustc_driver_impl::run_compiler::{closure#0}::{closure#2}>::{closure#2}::{closure#0}>
  26: <rustc_interface::passes::create_and_enter_global_ctxt<core::option::Option<rustc_interface::queries::Linker>, rustc_driver_impl::run_compiler::{closure#0}::{closure#2}>::{closure#2} as core::ops::function::FnOnce<(&rustc_session::session::Session, rustc_middle::ty::context::CurrentGcx, alloc::sync::Arc<rustc_data_structures::jobserver::Proxy>, &std::sync::once_lock::OnceLock<rustc_middle::ty::context::GlobalCtxt>, &rustc_data_structures::sync::worker_local::WorkerLocal<rustc_middle::arena::Arena>, &rustc_data_structures::sync::worker_local::WorkerLocal<rustc_hir::Arena>, rustc_driver_impl::run_compiler::{closure#0}::{closure#2})>>::call_once::{shim:vtable#0}
  27: <alloc::boxed::Box<dyn for<'a> core::ops::function::FnOnce<(&'a rustc_session::session::Session, rustc_middle::ty::context::CurrentGcx, alloc::sync::Arc<rustc_data_structures::jobserver::Proxy>, &'a std::sync::once_lock::OnceLock<rustc_middle::ty::context::GlobalCtxt<'a>>, &'a rustc_data_structures::sync::worker_local::WorkerLocal<rustc_middle::arena::Arena<'a>>, &'a rustc_data_structures::sync::worker_local::WorkerLocal<rustc_hir::Arena<'a>>, rustc_driver_impl::run_compiler::{closure#0}::{closure#2}), Output = core::option::Option<rustc_interface::queries::Linker>>> as core::ops::function::FnOnce<(&rustc_session::session::Session, rustc_middle::ty::context::CurrentGcx, alloc::sync::Arc<rustc_data_structures::jobserver::Proxy>, &std::sync::once_lock::OnceLock<rustc_middle::ty::context::GlobalCtxt>, &rustc_data_structures::sync::worker_local::WorkerLocal<rustc_middle::arena::Arena>, &rustc_data_structures::sync::worker_local::WorkerLocal<rustc_hir::Arena>, rustc_driver_impl::run_compiler::{closure#0}::{closure#2})>>::call_once
  28: rustc_interface::passes::create_and_enter_global_ctxt::<core::option::Option<rustc_interface::queries::Linker>, rustc_driver_impl::run_compiler::{closure#0}::{closure#2}>
  29: rustc_span::create_session_globals_then::<(), rustc_interface::util::run_in_thread_with_globals<rustc_interface::util::run_in_thread_pool_with_globals<rustc_interface::interface::run_compiler<(), rustc_driver_impl::run_compiler::{closure#0}>::{closure#1}, ()>::{closure#0}, ()>::{closure#0}::{closure#0}::{closure#0}>
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

error: the compiler unexpectedly panicked. This is a bug
---
warning: the ICE couldn't be written to `/checkout/rustc-ice-2026-02-10T09_55_01-13027.txt`: Read-only file system (os error 30)

note: rustc 1.95.0-nightly (29d9b8e86 2026-02-10) running on aarch64-unknown-linux-gnu

note: compiler flags: --crate-type lib -Z embed-metadata=no -C opt-level=3 -C embed-bitcode=no -C codegen-units=1 -C embed-bitcode=yes -Z unstable-options -C force-frame-pointers=non-leaf -C debug-assertions=on -Z annotate-moves -Z randomize-layout -Z unstable-options -Z macro-backtrace -C split-debuginfo=off -C prefer-dynamic -C llvm-args=-import-instr-limit=10 -Z inline-mir -Z inline-mir-preserve-debug -Z mir_strip_debuginfo=locals-in-tiny-functions -C link-args=-Wl,-z,origin -C link-args=-Wl,-rpath,$ORIGIN/../lib -Z crate-attr=doc(html_root_url="https://doc.rust-lang.org/nightly/") -Z binary-dep-depinfo -Z force-unstable-if-unmarked

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
#0 [resolver_for_lowering_raw] getting the resolver for lowering
end of query stack
[RUSTC-TIMING] core test:false 0.084
error: could not compile `core` (lib)

Caused by:
  process didn't exit successfully: `/checkout/obj/build/bootstrap/debug/rustc /checkout/obj/build/bootstrap/debug/rustc --crate-name core --edition=2024 library/core/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -Z embed-metadata=no -C opt-level=3 -C embed-bitcode=no -C codegen-units=1 --warn=unexpected_cfgs --check-cfg 'cfg(no_fp_fmt_parse)' --check-cfg 'cfg(feature, values(any()))' --check-cfg 'cfg(target_has_reliable_f16)' --check-cfg 'cfg(target_has_reliable_f16_math)' --check-cfg 'cfg(target_has_reliable_f128)' --check-cfg 'cfg(target_has_reliable_f128_math)' --check-cfg 'cfg(llvm_enzyme)' -Cembed-bitcode=yes -Zunstable-options -Cforce-frame-pointers=non-leaf -C debug-assertions=on --check-cfg 'cfg(docsrs,test)' --check-cfg 'cfg(feature, values("debug_refcell", "llvm_enzyme", "optimize_for_size", "panic_immediate_abort"))' -C metadata=3b16514726a86ee6 -C extra-filename=-9cc25fd76bf28989 --out-dir /checkout/obj/build/aarch64-unknown-linux-gnu/stage1-std/aarch64-unknown-linux-gnu/dist/deps --target aarch64-unknown-linux-gnu -L dependency=/checkout/obj/build/aarch64-unknown-linux-gnu/stage1-std/aarch64-unknown-linux-gnu/dist/deps -L dependency=/checkout/obj/build/aarch64-unknown-linux-gnu/stage1-std/dist/deps -Zannotate-moves -Zrandomize-layout '--check-cfg=cfg(feature,values(any()))' -Zunstable-options -Zmacro-backtrace -Csplit-debuginfo=off -Cprefer-dynamic -Cllvm-args=-import-instr-limit=10 --cfg=randomized_layouts -Zinline-mir -Zinline-mir-preserve-debug -Zmir_strip_debuginfo=locals-in-tiny-functions -Clink-args=-Wl,-z,origin '-Clink-args=-Wl,-rpath,$ORIGIN/../lib' '-Zcrate-attr=doc(html_root_url="https://doc.rust-lang.org/nightly/")' -Z binary-dep-depinfo` (exit status: 101)
warning: build failed, waiting for other jobs to finish...
[RUSTC-TIMING] shlex test:false 0.124
[RUSTC-TIMING] build_script_build test:false 0.143
[RUSTC-TIMING] build_script_build test:false 0.231
Bootstrap failed while executing `--stage 2 test --skip compiler --skip src`

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

rust-bors bot commented Feb 10, 2026

PR #152425, which is a member of this rollup, was unapproved.
This rollup was thus also unapproved.

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

Labels

A-attributes Area: Attributes (`#[…]`, `#![…]`) A-rustc-dev-guide Area: rustc-dev-guide A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic rollup A PR which is a rollup S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-clippy Relevant to the Clippy team. T-compiler Relevant to the compiler 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.

10 participants