Auto merge of #143214 - camsteffen:remove-let-chains-feature, r=est31

Remove let_chains unstable feature

Per https://github.com/rust-lang/rust/issues/53667#issuecomment-3016742982 (but then I also noticed rust-lang/rust#140722)

This replaces the feature gate with a parser error that says let chains require 2024.

A lot of tests were using the unstable feature. I either added edition:2024 to the test or split out the parts that require 2024.
diff --git a/.mailmap b/.mailmap
index 2a53cbf..90533e8 100644
--- a/.mailmap
+++ b/.mailmap
@@ -690,6 +690,7 @@
 Xuefeng Wu <benewu@gmail.com> Xuefeng Wu <xfwu@thoughtworks.com>
 Xuefeng Wu <benewu@gmail.com> XuefengWu <benewu@gmail.com>
 York Xiang <bombless@126.com>
+Yotam Ofek <yotam.ofek@gmail.com> <yotamofek@microsoft.com>
 Youngsoo Son <ysson83@gmail.com> <ysoo.son@samsung.com>
 Youngsuk Kim <joseph942010@gmail.com>
 Yuki Okushi <jtitor@2k36.org>
diff --git a/Cargo.lock b/Cargo.lock
index 110d171..da3eb92 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -8,7 +8,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "dfbe277e56a376000877090da837660b4427aad530e3028d44e0bffe4f89a1c1"
 dependencies = [
- "gimli",
+ "gimli 0.31.1",
 ]
 
 [[package]]
@@ -1484,6 +1484,17 @@
 ]
 
 [[package]]
+name = "gimli"
+version = "0.32.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "93563d740bc9ef04104f9ed6f86f1e3275c2cdafb95664e26584b9ca807a8ffe"
+dependencies = [
+ "fallible-iterator",
+ "indexmap",
+ "stable_deref_trait",
+]
+
+[[package]]
 name = "glob"
 version = "0.3.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -2568,7 +2579,7 @@
  "hashbrown",
  "indexmap",
  "memchr",
- "ruzstd",
+ "ruzstd 0.7.3",
 ]
 
 [[package]]
@@ -2578,9 +2589,11 @@
 checksum = "03fd943161069e1768b4b3d050890ba48730e590f57e56d4aa04e7e090e61b4a"
 dependencies = [
  "crc32fast",
+ "flate2",
  "hashbrown",
  "indexmap",
  "memchr",
+ "ruzstd 0.8.1",
  "wasmparser 0.234.0",
 ]
 
@@ -3194,9 +3207,9 @@
 dependencies = [
  "bstr",
  "build_helper",
- "gimli",
+ "gimli 0.32.0",
  "libc",
- "object 0.36.7",
+ "object 0.37.1",
  "regex",
  "serde_json",
  "similar",
@@ -3498,7 +3511,7 @@
 version = "0.0.0"
 dependencies = [
  "bitflags",
- "gimli",
+ "gimli 0.31.1",
  "itertools",
  "libc",
  "measureme",
@@ -4473,7 +4486,7 @@
  "rustc_target",
  "rustc_trait_selection",
  "tracing",
- "twox-hash",
+ "twox-hash 1.6.3",
 ]
 
 [[package]]
@@ -4857,7 +4870,16 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "fad02996bfc73da3e301efe90b1837be9ed8f4a462b6ed410aa35d00381de89f"
 dependencies = [
- "twox-hash",
+ "twox-hash 1.6.3",
+]
+
+[[package]]
+name = "ruzstd"
+version = "0.8.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3640bec8aad418d7d03c72ea2de10d5c646a598f9883c7babc160d91e3c1b26c"
+dependencies = [
+ "twox-hash 2.1.1",
 ]
 
 [[package]]
@@ -5338,7 +5360,7 @@
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "9e9c1e705f82a260173f3eec93f2ff6d7807f23ad5a8cc2e7316a891733ea7a1"
 dependencies = [
- "gimli",
+ "gimli 0.31.1",
  "hashbrown",
  "object 0.36.7",
  "tracing",
@@ -5581,6 +5603,12 @@
 ]
 
 [[package]]
+name = "twox-hash"
+version = "2.1.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8b907da542cbced5261bd3256de1b3a1bf340a3d37f93425a07362a1d687de56"
+
+[[package]]
 name = "type-map"
 version = "0.5.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
diff --git a/compiler/rustc_ast/src/ast.rs b/compiler/rustc_ast/src/ast.rs
index b2d8881..286bbfb 100644
--- a/compiler/rustc_ast/src/ast.rs
+++ b/compiler/rustc_ast/src/ast.rs
@@ -19,7 +19,6 @@
 //! - [`UnOp`], [`BinOp`], and [`BinOpKind`]: Unary and binary operators.
 
 use std::borrow::Cow;
-use std::sync::Arc;
 use std::{cmp, fmt};
 
 pub use GenericArgs::*;
@@ -32,7 +31,7 @@
 use rustc_macros::{Decodable, Encodable, HashStable_Generic};
 pub use rustc_span::AttrId;
 use rustc_span::source_map::{Spanned, respan};
-use rustc_span::{DUMMY_SP, ErrorGuaranteed, Ident, Span, Symbol, kw, sym};
+use rustc_span::{ByteSymbol, DUMMY_SP, ErrorGuaranteed, Ident, Span, Symbol, kw, sym};
 use thin_vec::{ThinVec, thin_vec};
 
 pub use crate::format::*;
@@ -1805,10 +1804,17 @@ pub enum ExprKind {
     Become(P<Expr>),
 
     /// Bytes included via `include_bytes!`
+    ///
     /// Added for optimization purposes to avoid the need to escape
     /// large binary blobs - should always behave like [`ExprKind::Lit`]
     /// with a `ByteStr` literal.
-    IncludedBytes(Arc<[u8]>),
+    ///
+    /// The value is stored as a `ByteSymbol`. It's unfortunate that we need to
+    /// intern (hash) the bytes because they're likely to be large and unique.
+    /// But it's necessary because this will eventually be lowered to
+    /// `LitKind::ByteStr`, which needs a `ByteSymbol` to impl `Copy` and avoid
+    /// arena allocation.
+    IncludedBytes(ByteSymbol),
 
     /// A `format_args!()` expression.
     FormatArgs(P<FormatArgs>),
@@ -2066,7 +2072,7 @@ pub const fn same_kind(&self, other: &Self) -> bool {
 }
 
 /// A literal in a meta item.
-#[derive(Clone, Encodable, Decodable, Debug, HashStable_Generic)]
+#[derive(Clone, Copy, Encodable, Decodable, Debug, HashStable_Generic)]
 pub struct MetaItemLit {
     /// The original literal as written in the source code.
     pub symbol: Symbol,
@@ -2129,16 +2135,18 @@ pub enum LitFloatType {
 /// deciding the `LitKind`. This means that float literals like `1f32` are
 /// classified by this type as `Float`. This is different to `token::LitKind`
 /// which does *not* consider the suffix.
-#[derive(Clone, Encodable, Decodable, Debug, Hash, Eq, PartialEq, HashStable_Generic)]
+#[derive(Clone, Copy, Encodable, Decodable, Debug, Hash, Eq, PartialEq, HashStable_Generic)]
 pub enum LitKind {
     /// A string literal (`"foo"`). The symbol is unescaped, and so may differ
     /// from the original token's symbol.
     Str(Symbol, StrStyle),
-    /// A byte string (`b"foo"`). Not stored as a symbol because it might be
-    /// non-utf8, and symbols only allow utf8 strings.
-    ByteStr(Arc<[u8]>, StrStyle),
-    /// A C String (`c"foo"`). Guaranteed to only have `\0` at the end.
-    CStr(Arc<[u8]>, StrStyle),
+    /// A byte string (`b"foo"`). The symbol is unescaped, and so may differ
+    /// from the original token's symbol.
+    ByteStr(ByteSymbol, StrStyle),
+    /// A C String (`c"foo"`). Guaranteed to only have `\0` at the end. The
+    /// symbol is unescaped, and so may differ from the original token's
+    /// symbol.
+    CStr(ByteSymbol, StrStyle),
     /// A byte char (`b'f'`).
     Byte(u8),
     /// A character literal (`'a'`).
@@ -2577,8 +2585,7 @@ pub enum TyPatKind {
 pub enum TraitObjectSyntax {
     // SAFETY: When adding new variants make sure to update the `Tag` impl.
     Dyn = 0,
-    DynStar = 1,
-    None = 2,
+    None = 1,
 }
 
 /// SAFETY: `TraitObjectSyntax` only has 3 data-less variants which means
@@ -2594,8 +2601,7 @@ fn into_usize(self) -> usize {
     unsafe fn from_usize(tag: usize) -> Self {
         match tag {
             0 => TraitObjectSyntax::Dyn,
-            1 => TraitObjectSyntax::DynStar,
-            2 => TraitObjectSyntax::None,
+            1 => TraitObjectSyntax::None,
             _ => unreachable!(),
         }
     }
diff --git a/compiler/rustc_ast/src/util/literal.rs b/compiler/rustc_ast/src/util/literal.rs
index ad9e5d1..fa78788 100644
--- a/compiler/rustc_ast/src/util/literal.rs
+++ b/compiler/rustc_ast/src/util/literal.rs
@@ -5,7 +5,7 @@
 use rustc_literal_escaper::{
     MixedUnit, unescape_byte, unescape_byte_str, unescape_c_str, unescape_char, unescape_str,
 };
-use rustc_span::{Span, Symbol, kw, sym};
+use rustc_span::{ByteSymbol, Span, Symbol, kw, sym};
 use tracing::debug;
 
 use crate::ast::{self, LitKind, MetaItemLit, StrStyle};
@@ -116,13 +116,12 @@ pub fn from_token_lit(lit: token::Lit) -> Result<LitKind, LitError> {
                         assert!(!err.is_fatal(), "failed to unescape string literal")
                     }
                 });
-                LitKind::ByteStr(buf.into(), StrStyle::Cooked)
+                LitKind::ByteStr(ByteSymbol::intern(&buf), StrStyle::Cooked)
             }
             token::ByteStrRaw(n) => {
-                // Raw strings have no escapes so we can convert the symbol
-                // directly to a `Arc<u8>`.
+                // Raw byte strings have no escapes so no work is needed here.
                 let buf = symbol.as_str().to_owned().into_bytes();
-                LitKind::ByteStr(buf.into(), StrStyle::Raw(n))
+                LitKind::ByteStr(ByteSymbol::intern(&buf), StrStyle::Raw(n))
             }
             token::CStr => {
                 let s = symbol.as_str();
@@ -137,7 +136,7 @@ pub fn from_token_lit(lit: token::Lit) -> Result<LitKind, LitError> {
                     }
                 });
                 buf.push(0);
-                LitKind::CStr(buf.into(), StrStyle::Cooked)
+                LitKind::CStr(ByteSymbol::intern(&buf), StrStyle::Cooked)
             }
             token::CStrRaw(n) => {
                 // Raw strings have no escapes so we can convert the symbol
@@ -145,7 +144,7 @@ pub fn from_token_lit(lit: token::Lit) -> Result<LitKind, LitError> {
                 // char.
                 let mut buf = symbol.as_str().to_owned().into_bytes();
                 buf.push(0);
-                LitKind::CStr(buf.into(), StrStyle::Raw(n))
+                LitKind::CStr(ByteSymbol::intern(&buf), StrStyle::Raw(n))
             }
             token::Err(guar) => LitKind::Err(guar),
         })
@@ -167,12 +166,12 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
                 delim = "#".repeat(n as usize),
                 string = sym
             )?,
-            LitKind::ByteStr(ref bytes, StrStyle::Cooked) => {
-                write!(f, "b\"{}\"", escape_byte_str_symbol(bytes))?
+            LitKind::ByteStr(ref byte_sym, StrStyle::Cooked) => {
+                write!(f, "b\"{}\"", escape_byte_str_symbol(byte_sym.as_byte_str()))?
             }
-            LitKind::ByteStr(ref bytes, StrStyle::Raw(n)) => {
+            LitKind::ByteStr(ref byte_sym, StrStyle::Raw(n)) => {
                 // Unwrap because raw byte string literals can only contain ASCII.
-                let symbol = str::from_utf8(bytes).unwrap();
+                let symbol = str::from_utf8(byte_sym.as_byte_str()).unwrap();
                 write!(
                     f,
                     "br{delim}\"{string}\"{delim}",
@@ -181,11 +180,11 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
                 )?;
             }
             LitKind::CStr(ref bytes, StrStyle::Cooked) => {
-                write!(f, "c\"{}\"", escape_byte_str_symbol(bytes))?
+                write!(f, "c\"{}\"", escape_byte_str_symbol(bytes.as_byte_str()))?
             }
             LitKind::CStr(ref bytes, StrStyle::Raw(n)) => {
                 // This can only be valid UTF-8.
-                let symbol = str::from_utf8(bytes).unwrap();
+                let symbol = str::from_utf8(bytes.as_byte_str()).unwrap();
                 write!(f, "cr{delim}\"{symbol}\"{delim}", delim = "#".repeat(n as usize),)?;
             }
             LitKind::Int(n, ty) => {
diff --git a/compiler/rustc_ast_lowering/src/expr.rs b/compiler/rustc_ast_lowering/src/expr.rs
index c214051..8747e62 100644
--- a/compiler/rustc_ast_lowering/src/expr.rs
+++ b/compiler/rustc_ast_lowering/src/expr.rs
@@ -144,11 +144,11 @@ pub(super) fn lower_expr_mut(&mut self, e: &Expr) -> hir::Expr<'hir> {
                     hir::ExprKind::Unary(op, ohs)
                 }
                 ExprKind::Lit(token_lit) => hir::ExprKind::Lit(self.lower_lit(token_lit, e.span)),
-                ExprKind::IncludedBytes(bytes) => {
-                    let lit = self.arena.alloc(respan(
+                ExprKind::IncludedBytes(byte_sym) => {
+                    let lit = respan(
                         self.lower_span(e.span),
-                        LitKind::ByteStr(Arc::clone(bytes), StrStyle::Cooked),
-                    ));
+                        LitKind::ByteStr(*byte_sym, StrStyle::Cooked),
+                    );
                     hir::ExprKind::Lit(lit)
                 }
                 ExprKind::Cast(expr, ty) => {
@@ -421,11 +421,7 @@ pub(crate) fn lower_const_block(&mut self, c: &AnonConst) -> hir::ConstBlock {
         })
     }
 
-    pub(crate) fn lower_lit(
-        &mut self,
-        token_lit: &token::Lit,
-        span: Span,
-    ) -> &'hir Spanned<LitKind> {
+    pub(crate) fn lower_lit(&mut self, token_lit: &token::Lit, span: Span) -> hir::Lit {
         let lit_kind = match LitKind::from_token_lit(*token_lit) {
             Ok(lit_kind) => lit_kind,
             Err(err) => {
@@ -433,7 +429,7 @@ pub(crate) fn lower_lit(
                 LitKind::Err(guar)
             }
         };
-        self.arena.alloc(respan(self.lower_span(span), lit_kind))
+        respan(self.lower_span(span), lit_kind)
     }
 
     fn lower_unop(&mut self, u: UnOp) -> hir::UnOp {
@@ -2141,10 +2137,10 @@ fn expr_unit(&mut self, sp: Span) -> &'hir hir::Expr<'hir> {
     }
 
     fn expr_uint(&mut self, sp: Span, ty: ast::UintTy, value: u128) -> hir::Expr<'hir> {
-        let lit = self.arena.alloc(hir::Lit {
+        let lit = hir::Lit {
             span: sp,
             node: ast::LitKind::Int(value.into(), ast::LitIntType::Unsigned(ty)),
-        });
+        };
         self.expr(sp, hir::ExprKind::Lit(lit))
     }
 
@@ -2161,9 +2157,7 @@ pub(super) fn expr_u16(&mut self, sp: Span, value: u16) -> hir::Expr<'hir> {
     }
 
     pub(super) fn expr_str(&mut self, sp: Span, value: Symbol) -> hir::Expr<'hir> {
-        let lit = self
-            .arena
-            .alloc(hir::Lit { span: sp, node: ast::LitKind::Str(value, ast::StrStyle::Cooked) });
+        let lit = hir::Lit { span: sp, node: ast::LitKind::Str(value, ast::StrStyle::Cooked) };
         self.expr(sp, hir::ExprKind::Lit(lit))
     }
 
diff --git a/compiler/rustc_ast_lowering/src/pat.rs b/compiler/rustc_ast_lowering/src/pat.rs
index 58dea47..e444062 100644
--- a/compiler/rustc_ast_lowering/src/pat.rs
+++ b/compiler/rustc_ast_lowering/src/pat.rs
@@ -390,19 +390,15 @@ fn lower_expr_within_pat(
         allow_paths: bool,
     ) -> &'hir hir::PatExpr<'hir> {
         let span = self.lower_span(expr.span);
-        let err = |guar| hir::PatExprKind::Lit {
-            lit: self.arena.alloc(respan(span, LitKind::Err(guar))),
-            negated: false,
-        };
+        let err =
+            |guar| hir::PatExprKind::Lit { lit: respan(span, LitKind::Err(guar)), negated: false };
         let kind = match &expr.kind {
             ExprKind::Lit(lit) => {
                 hir::PatExprKind::Lit { lit: self.lower_lit(lit, span), negated: false }
             }
             ExprKind::ConstBlock(c) => hir::PatExprKind::ConstBlock(self.lower_const_block(c)),
-            ExprKind::IncludedBytes(bytes) => hir::PatExprKind::Lit {
-                lit: self
-                    .arena
-                    .alloc(respan(span, LitKind::ByteStr(Arc::clone(bytes), StrStyle::Cooked))),
+            ExprKind::IncludedBytes(byte_sym) => hir::PatExprKind::Lit {
+                lit: respan(span, LitKind::ByteStr(*byte_sym, StrStyle::Cooked)),
                 negated: false,
             },
             ExprKind::Err(guar) => err(*guar),
diff --git a/compiler/rustc_ast_passes/src/feature_gate.rs b/compiler/rustc_ast_passes/src/feature_gate.rs
index 83af27c..5d8ee07 100644
--- a/compiler/rustc_ast_passes/src/feature_gate.rs
+++ b/compiler/rustc_ast_passes/src/feature_gate.rs
@@ -504,7 +504,6 @@ macro_rules! gate_all {
     );
     gate_all!(associated_const_equality, "associated const equality is incomplete");
     gate_all!(yeet_expr, "`do yeet` expression is experimental");
-    gate_all!(dyn_star, "`dyn*` trait objects are experimental");
     gate_all!(const_closures, "const closures are experimental");
     gate_all!(builtin_syntax, "`builtin #` syntax is unstable");
     gate_all!(ergonomic_clones, "ergonomic clones are experimental");
diff --git a/compiler/rustc_ast_pretty/src/pprust/state.rs b/compiler/rustc_ast_pretty/src/pprust/state.rs
index 3d738fa..9802ac9 100644
--- a/compiler/rustc_ast_pretty/src/pprust/state.rs
+++ b/compiler/rustc_ast_pretty/src/pprust/state.rs
@@ -1303,7 +1303,6 @@ pub fn print_type(&mut self, ty: &ast::Ty) {
             ast::TyKind::TraitObject(bounds, syntax) => {
                 match syntax {
                     ast::TraitObjectSyntax::Dyn => self.word_nbsp("dyn"),
-                    ast::TraitObjectSyntax::DynStar => self.word_nbsp("dyn*"),
                     ast::TraitObjectSyntax::None => {}
                 }
                 self.print_type_bounds(bounds);
diff --git a/compiler/rustc_ast_pretty/src/pprust/state/expr.rs b/compiler/rustc_ast_pretty/src/pprust/state/expr.rs
index 7651e83..8a2cb64 100644
--- a/compiler/rustc_ast_pretty/src/pprust/state/expr.rs
+++ b/compiler/rustc_ast_pretty/src/pprust/state/expr.rs
@@ -469,8 +469,12 @@ pub(super) fn print_expr_outer_attr_style(
             ast::ExprKind::Lit(token_lit) => {
                 self.print_token_literal(*token_lit, expr.span);
             }
-            ast::ExprKind::IncludedBytes(bytes) => {
-                let lit = token::Lit::new(token::ByteStr, escape_byte_str_symbol(bytes), None);
+            ast::ExprKind::IncludedBytes(byte_sym) => {
+                let lit = token::Lit::new(
+                    token::ByteStr,
+                    escape_byte_str_symbol(byte_sym.as_byte_str()),
+                    None,
+                );
                 self.print_token_literal(lit, expr.span)
             }
             ast::ExprKind::Cast(expr, ty) => {
diff --git a/compiler/rustc_attr_data_structures/src/attributes.rs b/compiler/rustc_attr_data_structures/src/attributes.rs
index 5eb1931..6f4cc83 100644
--- a/compiler/rustc_attr_data_structures/src/attributes.rs
+++ b/compiler/rustc_attr_data_structures/src/attributes.rs
@@ -256,6 +256,9 @@ pub enum AttributeKind {
     /// Represents `#[link_name]`.
     LinkName { name: Symbol, span: Span },
 
+    /// Represents [`#[link_section]`](https://doc.rust-lang.org/reference/abi.html#the-link_section-attribute)
+    LinkSection { name: Symbol, span: Span },
+
     /// Represents `#[loop_match]`.
     LoopMatch(Span),
 
@@ -287,6 +290,15 @@ pub enum AttributeKind {
     /// Represents [`#[repr]`](https://doc.rust-lang.org/stable/reference/type-layout.html#representations).
     Repr(ThinVec<(ReprAttr, Span)>),
 
+    /// Represents `#[rustc_layout_scalar_valid_range_end]`.
+    RustcLayoutScalarValidRangeEnd(Box<u128>, Span),
+
+    /// Represents `#[rustc_layout_scalar_valid_range_start]`.
+    RustcLayoutScalarValidRangeStart(Box<u128>, Span),
+
+    /// Represents `#[rustc_object_lifetime_default]`.
+    RustcObjectLifetimeDefault,
+
     /// Represents `#[rustc_skip_during_method_dispatch]`.
     SkipDuringMethodDispatch { array: bool, boxed_slice: bool, span: Span },
 
diff --git a/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs b/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs
index 0d6ee77..58ced8e 100644
--- a/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs
+++ b/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs
@@ -24,6 +24,7 @@ pub fn encode_cross_crate(&self) -> EncodeCrossCrate {
             DocComment { .. } => Yes,
             ExportName { .. } => Yes,
             Inline(..) => No,
+            LinkSection { .. } => No,
             MacroTransparency(..) => Yes,
             Repr(..) => No,
             Stability { .. } => Yes,
@@ -37,6 +38,9 @@ pub fn encode_cross_crate(&self) -> EncodeCrossCrate {
             NoMangle(..) => No,
             Optimize(..) => No,
             PubTransparent(..) => Yes,
+            RustcLayoutScalarValidRangeEnd(..) => Yes,
+            RustcLayoutScalarValidRangeStart(..) => Yes,
+            RustcObjectLifetimeDefault => No,
             SkipDuringMethodDispatch { .. } => No,
             TrackCaller(..) => Yes,
             Used { .. } => No,
diff --git a/compiler/rustc_attr_data_structures/src/lib.rs b/compiler/rustc_attr_data_structures/src/lib.rs
index 86c73f0..8f8ce57 100644
--- a/compiler/rustc_attr_data_structures/src/lib.rs
+++ b/compiler/rustc_attr_data_structures/src/lib.rs
@@ -49,6 +49,16 @@ pub trait PrintAttribute {
     fn print_attribute(&self, p: &mut Printer);
 }
 
+impl PrintAttribute for u128 {
+    fn should_render(&self) -> bool {
+        true
+    }
+
+    fn print_attribute(&self, p: &mut Printer) {
+        p.word(self.to_string())
+    }
+}
+
 impl<T: PrintAttribute> PrintAttribute for &T {
     fn should_render(&self) -> bool {
         T::should_render(self)
diff --git a/compiler/rustc_attr_parsing/messages.ftl b/compiler/rustc_attr_parsing/messages.ftl
index 3965233..9ad46a8 100644
--- a/compiler/rustc_attr_parsing/messages.ftl
+++ b/compiler/rustc_attr_parsing/messages.ftl
@@ -99,6 +99,8 @@
 
 attr_parsing_null_on_export = `export_name` may not contain null characters
 
+attr_parsing_null_on_link_section = `link_section` may not contain null characters
+
 attr_parsing_repr_ident =
     meta item in `repr` must be an identifier
 
diff --git a/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs b/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
index 7402221..e298053 100644
--- a/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
+++ b/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
@@ -1,11 +1,12 @@
 use rustc_attr_data_structures::AttributeKind;
-use rustc_attr_data_structures::AttributeKind::LinkName;
+use rustc_attr_data_structures::AttributeKind::{LinkName, LinkSection};
 use rustc_feature::{AttributeTemplate, template};
 use rustc_span::{Symbol, sym};
 
 use crate::attributes::{AttributeOrder, OnDuplicate, SingleAttributeParser};
 use crate::context::{AcceptContext, Stage};
 use crate::parser::ArgParser;
+use crate::session_diagnostics::NullOnLinkSection;
 
 pub(crate) struct LinkNameParser;
 
@@ -28,3 +29,31 @@ fn convert(cx: &mut AcceptContext<'_, '_, S>, args: &ArgParser<'_>) -> Option<At
         Some(LinkName { name, span: cx.attr_span })
     }
 }
+
+pub(crate) struct LinkSectionParser;
+
+impl<S: Stage> SingleAttributeParser<S> for LinkSectionParser {
+    const PATH: &[Symbol] = &[sym::link_section];
+    const ATTRIBUTE_ORDER: AttributeOrder = AttributeOrder::KeepFirst;
+    const ON_DUPLICATE: OnDuplicate<S> = OnDuplicate::WarnButFutureError;
+    const TEMPLATE: AttributeTemplate = template!(NameValueStr: "name");
+
+    fn convert(cx: &mut AcceptContext<'_, '_, S>, args: &ArgParser<'_>) -> Option<AttributeKind> {
+        let Some(nv) = args.name_value() else {
+            cx.expected_name_value(cx.attr_span, None);
+            return None;
+        };
+        let Some(name) = nv.value_as_str() else {
+            cx.expected_string_literal(nv.value_span, Some(nv.value_as_lit()));
+            return None;
+        };
+        if name.as_str().contains('\0') {
+            // `#[link_section = ...]` will be converted to a null-terminated string,
+            // so it may not contain any null characters.
+            cx.emit_err(NullOnLinkSection { span: cx.attr_span });
+            return None;
+        }
+
+        Some(LinkSection { name, span: cx.attr_span })
+    }
+}
diff --git a/compiler/rustc_attr_parsing/src/attributes/mod.rs b/compiler/rustc_attr_parsing/src/attributes/mod.rs
index 584dada..b3a9c69 100644
--- a/compiler/rustc_attr_parsing/src/attributes/mod.rs
+++ b/compiler/rustc_attr_parsing/src/attributes/mod.rs
@@ -36,6 +36,7 @@
 pub(crate) mod loop_match;
 pub(crate) mod must_use;
 pub(crate) mod repr;
+pub(crate) mod rustc_internal;
 pub(crate) mod semantics;
 pub(crate) mod stability;
 pub(crate) mod traits;
diff --git a/compiler/rustc_attr_parsing/src/attributes/must_use.rs b/compiler/rustc_attr_parsing/src/attributes/must_use.rs
index a672d95..b5eb85f 100644
--- a/compiler/rustc_attr_parsing/src/attributes/must_use.rs
+++ b/compiler/rustc_attr_parsing/src/attributes/must_use.rs
@@ -21,7 +21,16 @@ fn convert(cx: &mut AcceptContext<'_, '_, S>, args: &ArgParser<'_>) -> Option<At
             span: cx.attr_span,
             reason: match args {
                 ArgParser::NoArgs => None,
-                ArgParser::NameValue(name_value) => name_value.value_as_str(),
+                ArgParser::NameValue(name_value) => {
+                    let Some(value_str) = name_value.value_as_str() else {
+                        cx.expected_string_literal(
+                            name_value.value_span,
+                            Some(&name_value.value_as_lit()),
+                        );
+                        return None;
+                    };
+                    Some(value_str)
+                }
                 ArgParser::List(_) => {
                     let suggestions =
                         <Self as SingleAttributeParser<S>>::TEMPLATE.suggestions(false, "must_use");
diff --git a/compiler/rustc_attr_parsing/src/attributes/rustc_internal.rs b/compiler/rustc_attr_parsing/src/attributes/rustc_internal.rs
new file mode 100644
index 0000000..e6b6a6f
--- /dev/null
+++ b/compiler/rustc_attr_parsing/src/attributes/rustc_internal.rs
@@ -0,0 +1,77 @@
+use rustc_ast::LitKind;
+use rustc_attr_data_structures::AttributeKind;
+use rustc_feature::{AttributeTemplate, template};
+use rustc_span::{Symbol, sym};
+
+use crate::attributes::{AttributeOrder, OnDuplicate, SingleAttributeParser};
+use crate::context::{AcceptContext, Stage};
+use crate::parser::ArgParser;
+
+pub(crate) struct RustcLayoutScalarValidRangeStart;
+
+impl<S: Stage> SingleAttributeParser<S> for RustcLayoutScalarValidRangeStart {
+    const PATH: &'static [Symbol] = &[sym::rustc_layout_scalar_valid_range_start];
+    const ATTRIBUTE_ORDER: AttributeOrder = AttributeOrder::KeepFirst;
+    const ON_DUPLICATE: OnDuplicate<S> = OnDuplicate::Error;
+    const TEMPLATE: AttributeTemplate = template!(List: "start");
+
+    fn convert(cx: &mut AcceptContext<'_, '_, S>, args: &ArgParser<'_>) -> Option<AttributeKind> {
+        parse_rustc_layout_scalar_valid_range(cx, args)
+            .map(|n| AttributeKind::RustcLayoutScalarValidRangeStart(n, cx.attr_span))
+    }
+}
+
+pub(crate) struct RustcLayoutScalarValidRangeEnd;
+
+impl<S: Stage> SingleAttributeParser<S> for RustcLayoutScalarValidRangeEnd {
+    const PATH: &'static [Symbol] = &[sym::rustc_layout_scalar_valid_range_end];
+    const ATTRIBUTE_ORDER: AttributeOrder = AttributeOrder::KeepFirst;
+    const ON_DUPLICATE: OnDuplicate<S> = OnDuplicate::Error;
+    const TEMPLATE: AttributeTemplate = template!(List: "end");
+
+    fn convert(cx: &mut AcceptContext<'_, '_, S>, args: &ArgParser<'_>) -> Option<AttributeKind> {
+        parse_rustc_layout_scalar_valid_range(cx, args)
+            .map(|n| AttributeKind::RustcLayoutScalarValidRangeEnd(n, cx.attr_span))
+    }
+}
+
+fn parse_rustc_layout_scalar_valid_range<S: Stage>(
+    cx: &mut AcceptContext<'_, '_, S>,
+    args: &ArgParser<'_>,
+) -> Option<Box<u128>> {
+    let Some(list) = args.list() else {
+        cx.expected_list(cx.attr_span);
+        return None;
+    };
+    let Some(single) = list.single() else {
+        cx.expected_single_argument(list.span);
+        return None;
+    };
+    let Some(lit) = single.lit() else {
+        cx.expected_integer_literal(single.span());
+        return None;
+    };
+    let LitKind::Int(num, _ty) = lit.kind else {
+        cx.expected_integer_literal(single.span());
+        return None;
+    };
+    Some(Box::new(num.0))
+}
+
+pub(crate) struct RustcObjectLifetimeDefaultParser;
+
+impl<S: Stage> SingleAttributeParser<S> for RustcObjectLifetimeDefaultParser {
+    const PATH: &[rustc_span::Symbol] = &[sym::rustc_object_lifetime_default];
+    const ATTRIBUTE_ORDER: AttributeOrder = AttributeOrder::KeepFirst;
+    const ON_DUPLICATE: OnDuplicate<S> = OnDuplicate::Error;
+    const TEMPLATE: AttributeTemplate = template!(Word);
+
+    fn convert(cx: &mut AcceptContext<'_, '_, S>, args: &ArgParser<'_>) -> Option<AttributeKind> {
+        if let Err(span) = args.no_args() {
+            cx.expected_no_args(span);
+            return None;
+        }
+
+        Some(AttributeKind::RustcObjectLifetimeDefault)
+    }
+}
diff --git a/compiler/rustc_attr_parsing/src/context.rs b/compiler/rustc_attr_parsing/src/context.rs
index 1ac41b9..cfba065 100644
--- a/compiler/rustc_attr_parsing/src/context.rs
+++ b/compiler/rustc_attr_parsing/src/context.rs
@@ -22,11 +22,15 @@
 use crate::attributes::confusables::ConfusablesParser;
 use crate::attributes::deprecation::DeprecationParser;
 use crate::attributes::inline::{InlineParser, RustcForceInlineParser};
-use crate::attributes::link_attrs::LinkNameParser;
+use crate::attributes::link_attrs::{LinkNameParser, LinkSectionParser};
 use crate::attributes::lint_helpers::{AsPtrParser, PubTransparentParser};
 use crate::attributes::loop_match::{ConstContinueParser, LoopMatchParser};
 use crate::attributes::must_use::MustUseParser;
 use crate::attributes::repr::{AlignParser, ReprParser};
+use crate::attributes::rustc_internal::{
+    RustcLayoutScalarValidRangeEnd, RustcLayoutScalarValidRangeStart,
+    RustcObjectLifetimeDefaultParser,
+};
 use crate::attributes::semantics::MayDangleParser;
 use crate::attributes::stability::{
     BodyStabilityParser, ConstStabilityIndirectParser, ConstStabilityParser, StabilityParser,
@@ -123,6 +127,7 @@ mod late {
         Single<ExportNameParser>,
         Single<InlineParser>,
         Single<LinkNameParser>,
+        Single<LinkSectionParser>,
         Single<LoopMatchParser>,
         Single<MayDangleParser>,
         Single<MustUseParser>,
@@ -130,6 +135,9 @@ mod late {
         Single<OptimizeParser>,
         Single<PubTransparentParser>,
         Single<RustcForceInlineParser>,
+        Single<RustcLayoutScalarValidRangeEnd>,
+        Single<RustcLayoutScalarValidRangeStart>,
+        Single<RustcObjectLifetimeDefaultParser>,
         Single<SkipDuringMethodDispatchParser>,
         Single<TrackCallerParser>,
         Single<TransparencyParser>,
@@ -273,6 +281,16 @@ pub(crate) fn expected_string_literal(
         })
     }
 
+    pub(crate) fn expected_integer_literal(&self, span: Span) -> ErrorGuaranteed {
+        self.emit_err(AttributeParseError {
+            span,
+            attr_span: self.attr_span,
+            template: self.template.clone(),
+            attribute: self.attr_path.clone(),
+            reason: AttributeParseErrorReason::ExpectedIntegerLiteral,
+        })
+    }
+
     pub(crate) fn expected_list(&self, span: Span) -> ErrorGuaranteed {
         self.emit_err(AttributeParseError {
             span,
diff --git a/compiler/rustc_attr_parsing/src/session_diagnostics.rs b/compiler/rustc_attr_parsing/src/session_diagnostics.rs
index 7cfce57..6145f1e 100644
--- a/compiler/rustc_attr_parsing/src/session_diagnostics.rs
+++ b/compiler/rustc_attr_parsing/src/session_diagnostics.rs
@@ -453,6 +453,13 @@ pub(crate) struct NullOnExport {
 }
 
 #[derive(Diagnostic)]
+#[diag(attr_parsing_null_on_link_section, code = E0648)]
+pub(crate) struct NullOnLinkSection {
+    #[primary_span]
+    pub span: Span,
+}
+
+#[derive(Diagnostic)]
 #[diag(attr_parsing_stability_outside_std, code = E0734)]
 pub(crate) struct StabilityOutsideStd {
     #[primary_span]
@@ -503,6 +510,7 @@ pub(crate) struct NakedFunctionIncompatibleAttribute {
 pub(crate) enum AttributeParseErrorReason {
     ExpectedNoArgs,
     ExpectedStringLiteral { byte_string: Option<Span> },
+    ExpectedIntegerLiteral,
     ExpectedAtLeastOneArgument,
     ExpectedSingleArgument,
     ExpectedList,
@@ -543,6 +551,9 @@ fn into_diag(self, dcx: DiagCtxtHandle<'a>, level: Level) -> Diag<'a, G> {
                     diag.span_label(self.span, "expected a string literal here");
                 }
             }
+            AttributeParseErrorReason::ExpectedIntegerLiteral => {
+                diag.span_label(self.span, "expected an integer literal here");
+            }
             AttributeParseErrorReason::ExpectedSingleArgument => {
                 diag.span_label(self.span, "expected a single argument here");
                 diag.code(E0805);
@@ -566,10 +577,7 @@ fn into_diag(self, dcx: DiagCtxtHandle<'a>, level: Level) -> Diag<'a, G> {
                 diag.code(E0565);
             }
             AttributeParseErrorReason::ExpectedNameValue(None) => {
-                diag.span_label(
-                    self.span,
-                    format!("expected this to be of the form `{name} = \"...\"`"),
-                );
+                // The suggestion we add below this match already contains enough information
             }
             AttributeParseErrorReason::ExpectedNameValue(Some(name)) => {
                 diag.span_label(
diff --git a/compiler/rustc_borrowck/src/diagnostics/mutability_errors.rs b/compiler/rustc_borrowck/src/diagnostics/mutability_errors.rs
index fd8a2a6..7c69bab 100644
--- a/compiler/rustc_borrowck/src/diagnostics/mutability_errors.rs
+++ b/compiler/rustc_borrowck/src/diagnostics/mutability_errors.rs
@@ -1168,6 +1168,7 @@ fn suggest_make_local_mut(&self, err: &mut Diag<'_>, local: Local, name: Symbol)
                                     _,
                                     mir::Rvalue::Use(mir::Operand::Copy(place)),
                                 )),
+                            ..
                         }) = self.body[location.block].statements.get(location.statement_index)
                         {
                             self.body.local_decls[place.local].source_info.span
diff --git a/compiler/rustc_borrowck/src/type_check/mod.rs b/compiler/rustc_borrowck/src/type_check/mod.rs
index e37b5a3..05bcd9f 100644
--- a/compiler/rustc_borrowck/src/type_check/mod.rs
+++ b/compiler/rustc_borrowck/src/type_check/mod.rs
@@ -25,9 +25,9 @@
 use rustc_middle::ty::adjustment::PointerCoercion;
 use rustc_middle::ty::cast::CastTy;
 use rustc_middle::ty::{
-    self, Binder, CanonicalUserTypeAnnotation, CanonicalUserTypeAnnotations, CoroutineArgsExt,
-    Dynamic, GenericArgsRef, OpaqueHiddenType, OpaqueTypeKey, RegionVid, Ty, TyCtxt,
-    TypeVisitableExt, UserArgs, UserTypeAnnotationIndex, fold_regions,
+    self, CanonicalUserTypeAnnotation, CanonicalUserTypeAnnotations, CoroutineArgsExt,
+    GenericArgsRef, OpaqueHiddenType, OpaqueTypeKey, RegionVid, Ty, TyCtxt, TypeVisitableExt,
+    UserArgs, UserTypeAnnotationIndex, fold_regions,
 };
 use rustc_middle::{bug, span_bug};
 use rustc_mir_dataflow::move_paths::MoveData;
@@ -1233,38 +1233,6 @@ fn visit_rvalue(&mut self, rvalue: &Rvalue<'tcx>, location: Location) {
                         );
                     }
 
-                    CastKind::PointerCoercion(PointerCoercion::DynStar, coercion_source) => {
-                        // get the constraints from the target type (`dyn* Clone`)
-                        //
-                        // apply them to prove that the source type `Foo` implements `Clone` etc
-                        let (existential_predicates, region) = match ty.kind() {
-                            Dynamic(predicates, region, ty::DynStar) => (predicates, region),
-                            _ => panic!("Invalid dyn* cast_ty"),
-                        };
-
-                        let self_ty = op.ty(self.body, tcx);
-
-                        let is_implicit_coercion = coercion_source == CoercionSource::Implicit;
-                        self.prove_predicates(
-                            existential_predicates
-                                .iter()
-                                .map(|predicate| predicate.with_self_ty(tcx, self_ty)),
-                            location.to_locations(),
-                            ConstraintCategory::Cast { is_implicit_coercion, unsize_to: None },
-                        );
-
-                        let outlives_predicate = tcx.mk_predicate(Binder::dummy(
-                            ty::PredicateKind::Clause(ty::ClauseKind::TypeOutlives(
-                                ty::OutlivesPredicate(self_ty, *region),
-                            )),
-                        ));
-                        self.prove_predicate(
-                            outlives_predicate,
-                            location.to_locations(),
-                            ConstraintCategory::Cast { is_implicit_coercion, unsize_to: None },
-                        );
-                    }
-
                     CastKind::PointerCoercion(
                         PointerCoercion::MutToConstPointer,
                         coercion_source,
diff --git a/compiler/rustc_builtin_macros/src/concat_bytes.rs b/compiler/rustc_builtin_macros/src/concat_bytes.rs
index 92d011f..fd2d740 100644
--- a/compiler/rustc_builtin_macros/src/concat_bytes.rs
+++ b/compiler/rustc_builtin_macros/src/concat_bytes.rs
@@ -177,15 +177,15 @@ pub(crate) fn expand_concat_bytes(
                 Ok(LitKind::Byte(val)) => {
                     accumulator.push(val);
                 }
-                Ok(LitKind::ByteStr(ref bytes, _)) => {
-                    accumulator.extend_from_slice(bytes);
+                Ok(LitKind::ByteStr(ref byte_sym, _)) => {
+                    accumulator.extend_from_slice(byte_sym.as_byte_str());
                 }
                 _ => {
                     guar.get_or_insert_with(|| invalid_type_err(cx, token_lit, e.span, false));
                 }
             },
-            ExprKind::IncludedBytes(bytes) => {
-                accumulator.extend_from_slice(bytes);
+            ExprKind::IncludedBytes(byte_sym) => {
+                accumulator.extend_from_slice(byte_sym.as_byte_str());
             }
             ExprKind::Err(guarantee) => {
                 guar = Some(*guarantee);
diff --git a/compiler/rustc_builtin_macros/src/lib.rs b/compiler/rustc_builtin_macros/src/lib.rs
index 9b6dea2..0594f7e 100644
--- a/compiler/rustc_builtin_macros/src/lib.rs
+++ b/compiler/rustc_builtin_macros/src/lib.rs
@@ -5,10 +5,10 @@
 #![allow(internal_features)]
 #![allow(rustc::diagnostic_outside_of_impl)]
 #![allow(rustc::untranslatable_diagnostic)]
-#![cfg_attr(not(bootstrap), feature(autodiff))]
 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
 #![doc(rust_logo)]
 #![feature(assert_matches)]
+#![feature(autodiff)]
 #![feature(box_patterns)]
 #![feature(decl_macro)]
 #![feature(if_let_guard)]
diff --git a/compiler/rustc_builtin_macros/src/source_util.rs b/compiler/rustc_builtin_macros/src/source_util.rs
index 8142f15..cebfffa 100644
--- a/compiler/rustc_builtin_macros/src/source_util.rs
+++ b/compiler/rustc_builtin_macros/src/source_util.rs
@@ -16,7 +16,7 @@
 use rustc_parse::{new_parser_from_file, unwrap_or_emit_fatal, utf8_error};
 use rustc_session::lint::builtin::INCOMPLETE_INCLUDE;
 use rustc_span::source_map::SourceMap;
-use rustc_span::{Pos, Span, Symbol};
+use rustc_span::{ByteSymbol, Pos, Span, Symbol};
 use smallvec::SmallVec;
 
 use crate::errors;
@@ -237,7 +237,7 @@ pub(crate) fn expand_include_bytes(
         Ok((bytes, _bsp)) => {
             // Don't care about getting the span for the raw bytes,
             // because the console can't really show them anyway.
-            let expr = cx.expr(sp, ast::ExprKind::IncludedBytes(bytes));
+            let expr = cx.expr(sp, ast::ExprKind::IncludedBytes(ByteSymbol::intern(&bytes)));
             MacEager::expr(expr)
         }
         Err(dummy) => dummy,
diff --git a/compiler/rustc_codegen_cranelift/example/mini_core.rs b/compiler/rustc_codegen_cranelift/example/mini_core.rs
index 524ebde..2f53bbf 100644
--- a/compiler/rustc_codegen_cranelift/example/mini_core.rs
+++ b/compiler/rustc_codegen_cranelift/example/mini_core.rs
@@ -660,7 +660,7 @@ pub mod intrinsics {
     #[rustc_intrinsic]
     pub unsafe fn ctlz_nonzero<T>(x: T) -> u32;
     #[rustc_intrinsic]
-    pub fn needs_drop<T: ?::Sized>() -> bool;
+    pub const fn needs_drop<T: ?::Sized>() -> bool;
     #[rustc_intrinsic]
     pub fn bitreverse<T>(x: T) -> T;
     #[rustc_intrinsic]
diff --git a/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs b/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs
index 1499f94..246bd31 100644
--- a/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs
+++ b/compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs
@@ -1,4 +1,13 @@
-#![feature(no_core, lang_items, never_type, linkage, extern_types, thread_local, repr_simd)]
+#![feature(
+    no_core,
+    lang_items,
+    never_type,
+    linkage,
+    extern_types,
+    thread_local,
+    repr_simd,
+    rustc_private
+)]
 #![no_core]
 #![allow(dead_code, non_camel_case_types, internal_features)]
 
@@ -207,10 +216,14 @@ fn main() {
         assert_eq!(intrinsics::align_of::<u16>() as u8, 2);
         assert_eq!(intrinsics::align_of_val(&a) as u8, intrinsics::align_of::<&str>() as u8);
 
-        assert!(!intrinsics::needs_drop::<u8>());
-        assert!(!intrinsics::needs_drop::<[u8]>());
-        assert!(intrinsics::needs_drop::<NoisyDrop>());
-        assert!(intrinsics::needs_drop::<NoisyDropUnsized>());
+        let u8_needs_drop = const { intrinsics::needs_drop::<u8>() };
+        assert!(!u8_needs_drop);
+        let slice_needs_drop = const { intrinsics::needs_drop::<[u8]>() };
+        assert!(!slice_needs_drop);
+        let noisy_drop = const { intrinsics::needs_drop::<NoisyDrop>() };
+        assert!(noisy_drop);
+        let noisy_unsized_drop = const { intrinsics::needs_drop::<NoisyDropUnsized>() };
+        assert!(noisy_unsized_drop);
 
         Unique { pointer: NonNull(1 as *mut &str), _marker: PhantomData } as Unique<dyn SomeTrait>;
 
diff --git a/compiler/rustc_codegen_cranelift/src/abi/mod.rs b/compiler/rustc_codegen_cranelift/src/abi/mod.rs
index 4c6fd90..8965e4a 100644
--- a/compiler/rustc_codegen_cranelift/src/abi/mod.rs
+++ b/compiler/rustc_codegen_cranelift/src/abi/mod.rs
@@ -753,51 +753,6 @@ pub(crate) fn codegen_drop<'tcx>(
                 fx.bcx.ins().call_indirect(sig, drop_fn, &[ptr]);
                 fx.bcx.ins().jump(ret_block, &[]);
             }
-            ty::Dynamic(_, _, ty::DynStar) => {
-                // IN THIS ARM, WE HAVE:
-                // ty = *mut (dyn* Trait)
-                // which is: *mut exists<T: sizeof(T) == sizeof(usize)> (T, Vtable<T: Trait>)
-                //
-                // args = [ * ]
-                //          |
-                //          v
-                //      ( Data, Vtable )
-                //                |
-                //                v
-                //              /-------\
-                //              | ...   |
-                //              \-------/
-                //
-                //
-                // WE CAN CONVERT THIS INTO THE ABOVE LOGIC BY DOING
-                //
-                // data = &(*args[0]).0    // gives a pointer to Data above (really the same pointer)
-                // vtable = (*args[0]).1   // loads the vtable out
-                // (data, vtable)          // an equivalent Rust `*mut dyn Trait`
-                //
-                // SO THEN WE CAN USE THE ABOVE CODE.
-                let (data, vtable) = drop_place.to_cvalue(fx).dyn_star_force_data_on_stack(fx);
-                let drop_fn = crate::vtable::drop_fn_of_obj(fx, vtable);
-
-                let is_null = fx.bcx.ins().icmp_imm(IntCC::Equal, drop_fn, 0);
-                let target_block = fx.get_block(target);
-                let continued = fx.bcx.create_block();
-                fx.bcx.ins().brif(is_null, target_block, &[], continued, &[]);
-                fx.bcx.switch_to_block(continued);
-
-                let virtual_drop = Instance {
-                    def: ty::InstanceKind::Virtual(drop_instance.def_id(), 0),
-                    args: drop_instance.args,
-                };
-                let fn_abi = FullyMonomorphizedLayoutCx(fx.tcx)
-                    .fn_abi_of_instance(virtual_drop, ty::List::empty());
-
-                let sig = clif_sig_from_fn_abi(fx.tcx, fx.target_config.default_call_conv, &fn_abi);
-                let sig = fx.bcx.import_signature(sig);
-                fx.bcx.ins().call_indirect(sig, drop_fn, &[data]);
-                // FIXME implement cleanup on exceptions
-                fx.bcx.ins().jump(ret_block, &[]);
-            }
             _ => {
                 assert!(!matches!(drop_instance.def, InstanceKind::Virtual(_, _)));
 
diff --git a/compiler/rustc_codegen_cranelift/src/base.rs b/compiler/rustc_codegen_cranelift/src/base.rs
index 1b68c65..bc0a0f0 100644
--- a/compiler/rustc_codegen_cranelift/src/base.rs
+++ b/compiler/rustc_codegen_cranelift/src/base.rs
@@ -790,14 +790,6 @@ fn is_wide_ptr<'tcx>(fx: &FunctionCx<'_, '_, 'tcx>, ty: Ty<'tcx>) -> bool {
                     let operand = codegen_operand(fx, operand);
                     crate::unsize::coerce_unsized_into(fx, operand, lval);
                 }
-                Rvalue::Cast(
-                    CastKind::PointerCoercion(PointerCoercion::DynStar, _),
-                    ref operand,
-                    _,
-                ) => {
-                    let operand = codegen_operand(fx, operand);
-                    crate::unsize::coerce_dyn_star(fx, operand, lval);
-                }
                 Rvalue::Cast(CastKind::Transmute, ref operand, _to_ty) => {
                     let operand = codegen_operand(fx, operand);
                     lval.write_cvalue_transmute(fx, operand);
diff --git a/compiler/rustc_codegen_cranelift/src/constant.rs b/compiler/rustc_codegen_cranelift/src/constant.rs
index 3a62cd5..ee43eb7 100644
--- a/compiler/rustc_codegen_cranelift/src/constant.rs
+++ b/compiler/rustc_codegen_cranelift/src/constant.rs
@@ -133,7 +133,7 @@ pub(crate) fn codegen_const_value<'tcx>(
                 }
             }
             Scalar::Ptr(ptr, _size) => {
-                let (prov, offset) = ptr.into_parts(); // we know the `offset` is relative
+                let (prov, offset) = ptr.prov_and_relative_offset();
                 let alloc_id = prov.alloc_id();
                 let base_addr = match fx.tcx.global_alloc(alloc_id) {
                     GlobalAlloc::Memory(alloc) => {
diff --git a/compiler/rustc_codegen_cranelift/src/intrinsics/mod.rs b/compiler/rustc_codegen_cranelift/src/intrinsics/mod.rs
index df5748c..4ff5773 100644
--- a/compiler/rustc_codegen_cranelift/src/intrinsics/mod.rs
+++ b/compiler/rustc_codegen_cranelift/src/intrinsics/mod.rs
@@ -812,21 +812,6 @@ fn codegen_regular_intrinsic_call<'tcx>(
             dest.write_cvalue(fx, val);
         }
 
-        sym::needs_drop | sym::type_id | sym::type_name | sym::variant_count => {
-            intrinsic_args!(fx, args => (); intrinsic);
-
-            let const_val = fx
-                .tcx
-                .const_eval_instance(
-                    ty::TypingEnv::fully_monomorphized(),
-                    instance,
-                    source_info.span,
-                )
-                .unwrap();
-            let val = crate::constant::codegen_const_value(fx, const_val, ret.layout().ty);
-            ret.write_cvalue(fx, val);
-        }
-
         sym::ptr_offset_from | sym::ptr_offset_from_unsigned => {
             intrinsic_args!(fx, args => (ptr, base); intrinsic);
             let ptr = ptr.load_scalar(fx);
diff --git a/compiler/rustc_codegen_cranelift/src/unsize.rs b/compiler/rustc_codegen_cranelift/src/unsize.rs
index df60b05..2aee0b2 100644
--- a/compiler/rustc_codegen_cranelift/src/unsize.rs
+++ b/compiler/rustc_codegen_cranelift/src/unsize.rs
@@ -112,21 +112,6 @@ fn unsize_ptr<'tcx>(
     }
 }
 
-/// Coerces `src` to `dst_ty` which is guaranteed to be a `dyn*` type.
-pub(crate) fn cast_to_dyn_star<'tcx>(
-    fx: &mut FunctionCx<'_, '_, 'tcx>,
-    src: Value,
-    src_ty_and_layout: TyAndLayout<'tcx>,
-    dst_ty: Ty<'tcx>,
-    old_info: Option<Value>,
-) -> (Value, Value) {
-    assert!(
-        matches!(dst_ty.kind(), ty::Dynamic(_, _, ty::DynStar)),
-        "destination type must be a dyn*"
-    );
-    (src, unsized_info(fx, src_ty_and_layout.ty, dst_ty, old_info))
-}
-
 /// Coerce `src`, which is a reference to a value of type `src_ty`,
 /// to a value of type `dst_ty` and store the result in `dst`
 pub(crate) fn coerce_unsized_into<'tcx>(
@@ -174,24 +159,6 @@ pub(crate) fn coerce_unsized_into<'tcx>(
     }
 }
 
-pub(crate) fn coerce_dyn_star<'tcx>(
-    fx: &mut FunctionCx<'_, '_, 'tcx>,
-    src: CValue<'tcx>,
-    dst: CPlace<'tcx>,
-) {
-    let (data, extra) = if let ty::Dynamic(_, _, ty::DynStar) = src.layout().ty.kind() {
-        let (data, vtable) = src.load_scalar_pair(fx);
-        (data, Some(vtable))
-    } else {
-        let data = src.load_scalar(fx);
-        (data, None)
-    };
-
-    let (data, vtable) = cast_to_dyn_star(fx, data, src.layout(), dst.layout().ty, extra);
-
-    dst.write_cvalue(fx, CValue::by_val_pair(data, vtable, dst.layout()));
-}
-
 // Adapted from https://github.com/rust-lang/rust/blob/2a663555ddf36f6b041445894a8c175cd1bc718c/src/librustc_codegen_ssa/glue.rs
 
 pub(crate) fn size_and_align_of<'tcx>(
diff --git a/compiler/rustc_codegen_cranelift/src/value_and_place.rs b/compiler/rustc_codegen_cranelift/src/value_and_place.rs
index cbfb215..9d73f20 100644
--- a/compiler/rustc_codegen_cranelift/src/value_and_place.rs
+++ b/compiler/rustc_codegen_cranelift/src/value_and_place.rs
@@ -121,43 +121,6 @@ pub(crate) fn force_stack(self, fx: &mut FunctionCx<'_, '_, 'tcx>) -> (Pointer,
         }
     }
 
-    // FIXME remove
-    /// Forces the data value of a dyn* value to the stack and returns a pointer to it as well as the
-    /// vtable pointer.
-    pub(crate) fn dyn_star_force_data_on_stack(
-        self,
-        fx: &mut FunctionCx<'_, '_, 'tcx>,
-    ) -> (Value, Value) {
-        assert!(self.1.ty.is_dyn_star());
-
-        match self.0 {
-            CValueInner::ByRef(ptr, None) => {
-                let (a_scalar, b_scalar) = match self.1.backend_repr {
-                    BackendRepr::ScalarPair(a, b) => (a, b),
-                    _ => unreachable!("dyn_star_force_data_on_stack({:?})", self),
-                };
-                let b_offset = scalar_pair_calculate_b_offset(fx.tcx, a_scalar, b_scalar);
-                let clif_ty2 = scalar_to_clif_type(fx.tcx, b_scalar);
-                let mut flags = MemFlags::new();
-                flags.set_notrap();
-                let vtable = ptr.offset(fx, b_offset).load(fx, clif_ty2, flags);
-                (ptr.get_addr(fx), vtable)
-            }
-            CValueInner::ByValPair(data, vtable) => {
-                let data_ptr = fx.create_stack_slot(
-                    u32::try_from(fx.target_config.pointer_type().bytes()).unwrap(),
-                    u32::try_from(fx.target_config.pointer_type().bytes()).unwrap(),
-                );
-                data_ptr.store(fx, data, MemFlags::trusted());
-
-                (data_ptr.get_addr(fx), vtable)
-            }
-            CValueInner::ByRef(_, Some(_)) | CValueInner::ByVal(_) => {
-                unreachable!("dyn_star_force_data_on_stack({:?})", self)
-            }
-        }
-    }
-
     pub(crate) fn try_to_ptr(self) -> Option<(Pointer, Option<Value>)> {
         match self.0 {
             CValueInner::ByRef(ptr, meta) => Some((ptr, meta)),
diff --git a/compiler/rustc_codegen_cranelift/src/vtable.rs b/compiler/rustc_codegen_cranelift/src/vtable.rs
index 1fae569..423cc8d 100644
--- a/compiler/rustc_codegen_cranelift/src/vtable.rs
+++ b/compiler/rustc_codegen_cranelift/src/vtable.rs
@@ -46,34 +46,22 @@ pub(crate) fn get_ptr_and_method_ref<'tcx>(
     mut arg: CValue<'tcx>,
     idx: usize,
 ) -> (Pointer, Value) {
-    let (ptr, vtable) = 'block: {
-        if let BackendRepr::Scalar(_) = arg.layout().backend_repr {
-            while !arg.layout().ty.is_raw_ptr() && !arg.layout().ty.is_ref() {
-                let (idx, _) = arg
-                    .layout()
-                    .non_1zst_field(fx)
-                    .expect("not exactly one non-1-ZST field in a `DispatchFromDyn` type");
-                arg = arg.value_field(fx, idx);
-            }
+    if let BackendRepr::Scalar(_) = arg.layout().backend_repr {
+        while !arg.layout().ty.is_raw_ptr() && !arg.layout().ty.is_ref() {
+            let (idx, _) = arg
+                .layout()
+                .non_1zst_field(fx)
+                .expect("not exactly one non-1-ZST field in a `DispatchFromDyn` type");
+            arg = arg.value_field(fx, idx);
         }
+    }
 
-        if let ty::Ref(_, ty, _) = arg.layout().ty.kind() {
-            if ty.is_dyn_star() {
-                let inner_layout = fx.layout_of(arg.layout().ty.builtin_deref(true).unwrap());
-                let dyn_star = CPlace::for_ptr(Pointer::new(arg.load_scalar(fx)), inner_layout);
-                let ptr = dyn_star.place_field(fx, FieldIdx::ZERO).to_ptr();
-                let vtable = dyn_star.place_field(fx, FieldIdx::ONE).to_cvalue(fx).load_scalar(fx);
-                break 'block (ptr, vtable);
-            }
-        }
-
-        if let BackendRepr::ScalarPair(_, _) = arg.layout().backend_repr {
-            let (ptr, vtable) = arg.load_scalar_pair(fx);
-            (Pointer::new(ptr), vtable)
-        } else {
-            let (ptr, vtable) = arg.try_to_ptr().unwrap();
-            (ptr, vtable.unwrap())
-        }
+    let (ptr, vtable) = if let BackendRepr::ScalarPair(_, _) = arg.layout().backend_repr {
+        let (ptr, vtable) = arg.load_scalar_pair(fx);
+        (Pointer::new(ptr), vtable)
+    } else {
+        let (ptr, vtable) = arg.try_to_ptr().unwrap();
+        (ptr, vtable.unwrap())
     };
 
     let usize_size = fx.layout_of(fx.tcx.types.usize).size.bytes();
diff --git a/compiler/rustc_codegen_gcc/build_system/build_sysroot/Cargo.toml b/compiler/rustc_codegen_gcc/build_system/build_sysroot/Cargo.toml
index 931f609..29a3bce 100644
--- a/compiler/rustc_codegen_gcc/build_system/build_sysroot/Cargo.toml
+++ b/compiler/rustc_codegen_gcc/build_system/build_sysroot/Cargo.toml
@@ -6,6 +6,7 @@
 
 [dependencies]
 core = { path = "./sysroot_src/library/core" }
+compiler_builtins = { path = "./sysroot_src/library/compiler-builtins/compiler-builtins" }
 alloc = { path = "./sysroot_src/library/alloc" }
 std = { path = "./sysroot_src/library/std", features = ["panic_unwind", "backtrace"] }
 test = { path = "./sysroot_src/library/test" }
diff --git a/compiler/rustc_codegen_gcc/build_system/src/test.rs b/compiler/rustc_codegen_gcc/build_system/src/test.rs
index f1f31f8..cbb0f94 100644
--- a/compiler/rustc_codegen_gcc/build_system/src/test.rs
+++ b/compiler/rustc_codegen_gcc/build_system/src/test.rs
@@ -9,8 +9,8 @@
 use crate::config::{Channel, ConfigInfo};
 use crate::utils::{
     create_dir, get_sysroot_dir, get_toolchain, git_clone, git_clone_root_dir, remove_file,
-    run_command, run_command_with_env, run_command_with_output, run_command_with_output_and_env,
-    rustc_version_info, split_args, walk_dir,
+    run_command, run_command_with_env, run_command_with_output_and_env, rustc_version_info,
+    split_args, walk_dir,
 };
 
 type Env = HashMap<String, String>;
@@ -485,30 +485,6 @@ fn setup_rustc(env: &mut Env, args: &TestArg) -> Result<PathBuf, String> {
         run_command_with_output_and_env(&[&"git", &"checkout"], rust_dir, Some(env))?;
     }
 
-    let mut patches = Vec::new();
-    walk_dir(
-        "patches/tests",
-        &mut |_| Ok(()),
-        &mut |file_path: &Path| {
-            patches.push(file_path.to_path_buf());
-            Ok(())
-        },
-        false,
-    )?;
-    patches.sort();
-    // TODO: remove duplication with prepare.rs by creating a apply_patch function in the utils
-    // module.
-    for file_path in patches {
-        println!("[GIT] apply `{}`", file_path.display());
-        let path = Path::new("../..").join(file_path);
-        run_command_with_output(&[&"git", &"apply", &path], rust_dir)?;
-        run_command_with_output(&[&"git", &"add", &"-A"], rust_dir)?;
-        run_command_with_output(
-            &[&"git", &"commit", &"--no-gpg-sign", &"-m", &format!("Patch {}", path.display())],
-            rust_dir,
-        )?;
-    }
-
     let cargo = String::from_utf8(
         run_command_with_env(&[&"rustup", &"which", &"cargo"], rust_dir, Some(env))?.stdout,
     )
diff --git a/compiler/rustc_codegen_gcc/example/mini_core_hello_world.rs b/compiler/rustc_codegen_gcc/example/mini_core_hello_world.rs
index c3bd62e..6b6f71e 100644
--- a/compiler/rustc_codegen_gcc/example/mini_core_hello_world.rs
+++ b/compiler/rustc_codegen_gcc/example/mini_core_hello_world.rs
@@ -6,6 +6,7 @@
 )]
 #![no_core]
 #![allow(dead_code, internal_features, non_camel_case_types)]
+#![rustfmt::skip]
 
 extern crate mini_core;
 
@@ -197,10 +198,10 @@ fn main() {
         assert_eq!(intrinsics::align_of::<u16>() as u8, 2);
         assert_eq!(intrinsics::align_of_val(&a) as u8, intrinsics::align_of::<&str>() as u8);
 
-        assert!(!intrinsics::needs_drop::<u8>());
-        assert!(!intrinsics::needs_drop::<[u8]>());
-        assert!(intrinsics::needs_drop::<NoisyDrop>());
-        assert!(intrinsics::needs_drop::<NoisyDropUnsized>());
+        assert!(!const { intrinsics::needs_drop::<u8>() });
+        assert!(!const { intrinsics::needs_drop::<[u8]>() });
+        assert!(const { intrinsics::needs_drop::<NoisyDrop>() });
+        assert!(const { intrinsics::needs_drop::<NoisyDropUnsized>() });
 
         Unique {
             pointer: 0 as *const &str,
diff --git a/compiler/rustc_codegen_gcc/patches/tests/0001-Workaround-to-make-a-run-make-test-pass.patch b/compiler/rustc_codegen_gcc/patches/tests/0001-Workaround-to-make-a-run-make-test-pass.patch
deleted file mode 100644
index a329d09..0000000
--- a/compiler/rustc_codegen_gcc/patches/tests/0001-Workaround-to-make-a-run-make-test-pass.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From a131c69e54b5c02fe3b517e8f3ad23d4f784ffc8 Mon Sep 17 00:00:00 2001
-From: Antoni Boucher <bouanto@zoho.com>
-Date: Fri, 13 Jun 2025 20:25:33 -0400
-Subject: [PATCH] Workaround to make a run-make test pass
-
----
- tests/run-make/linker-warning/rmake.rs | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/tests/run-make/linker-warning/rmake.rs b/tests/run-make/linker-warning/rmake.rs
-index bc21739fefc..0946a7e2a48 100644
---- a/tests/run-make/linker-warning/rmake.rs
-+++ b/tests/run-make/linker-warning/rmake.rs
-@@ -55,7 +55,7 @@ fn main() {
-         diff()
-             .expected_file("short-error.txt")
-             .actual_text("(linker error)", out.stderr())
--            .normalize(r#"/rustc[^/]*/"#, "/rustc/")
-+            .normalize(r#"/tmp/rustc[^/]*/"#, "/tmp/rustc/")
-             .normalize(
-                 regex::escape(run_make_support::build_root().to_str().unwrap()),
-                 "/build-root",
--- 
-2.49.0
-
diff --git a/compiler/rustc_codegen_gcc/rust-toolchain b/compiler/rustc_codegen_gcc/rust-toolchain
index 8be204c..bccbc6c 100644
--- a/compiler/rustc_codegen_gcc/rust-toolchain
+++ b/compiler/rustc_codegen_gcc/rust-toolchain
@@ -1,3 +1,3 @@
 [toolchain]
-channel = "nightly-2025-06-02"
+channel = "nightly-2025-06-28"
 components = ["rust-src", "rustc-dev", "llvm-tools-preview"]
diff --git a/compiler/rustc_codegen_gcc/src/abi.rs b/compiler/rustc_codegen_gcc/src/abi.rs
index 08f3d28..0b359f1 100644
--- a/compiler/rustc_codegen_gcc/src/abi.rs
+++ b/compiler/rustc_codegen_gcc/src/abi.rs
@@ -1,7 +1,9 @@
 #[cfg(feature = "master")]
 use gccjit::FnAttribute;
 use gccjit::{ToLValue, ToRValue, Type};
-use rustc_abi::{ArmCall, CanonAbi, InterruptKind, Reg, RegKind, X86Call};
+#[cfg(feature = "master")]
+use rustc_abi::{ArmCall, CanonAbi, InterruptKind, X86Call};
+use rustc_abi::{Reg, RegKind};
 use rustc_codegen_ssa::traits::{AbiBuilderMethods, BaseTypeCodegenMethods};
 use rustc_data_structures::fx::FxHashSet;
 use rustc_middle::bug;
diff --git a/compiler/rustc_codegen_gcc/src/builder.rs b/compiler/rustc_codegen_gcc/src/builder.rs
index 1fce547..b1785af 100644
--- a/compiler/rustc_codegen_gcc/src/builder.rs
+++ b/compiler/rustc_codegen_gcc/src/builder.rs
@@ -538,11 +538,6 @@ fn ret_void(&mut self) {
     }
 
     fn ret(&mut self, mut value: RValue<'gcc>) {
-        if self.structs_as_pointer.borrow().contains(&value) {
-            // NOTE: hack to workaround a limitation of the rustc API: see comment on
-            // CodegenCx.structs_as_pointer
-            value = value.dereference(self.location).to_rvalue();
-        }
         let expected_return_type = self.current_func().get_return_type();
         if !expected_return_type.is_compatible_with(value.get_type()) {
             // NOTE: due to opaque pointers now being used, we need to cast here.
@@ -700,7 +695,7 @@ fn exactudiv(&mut self, a: RValue<'gcc>, b: RValue<'gcc>) -> RValue<'gcc> {
         let a = self.gcc_int_cast(a, a_type);
         let b_type = b.get_type().to_unsigned(self);
         let b = self.gcc_int_cast(b, b_type);
-        a / b
+        self.gcc_udiv(a, b)
     }
 
     fn sdiv(&mut self, a: RValue<'gcc>, b: RValue<'gcc>) -> RValue<'gcc> {
@@ -712,8 +707,8 @@ fn exactsdiv(&mut self, a: RValue<'gcc>, b: RValue<'gcc>) -> RValue<'gcc> {
         // FIXME(antoyo): rustc_codegen_ssa::mir::intrinsic uses different types for a and b but they
         // should be the same.
         let typ = a.get_type().to_signed(self);
-        let b = self.context.new_cast(self.location, b, typ);
-        a / b
+        let b = self.gcc_int_cast(b, typ);
+        self.gcc_sdiv(a, b)
     }
 
     fn fdiv(&mut self, a: RValue<'gcc>, b: RValue<'gcc>) -> RValue<'gcc> {
@@ -1119,13 +1114,7 @@ fn nonnull_metadata(&mut self, _load: RValue<'gcc>) {
         // TODO(antoyo)
     }
 
-    fn store(&mut self, mut val: RValue<'gcc>, ptr: RValue<'gcc>, align: Align) -> RValue<'gcc> {
-        if self.structs_as_pointer.borrow().contains(&val) {
-            // NOTE: hack to workaround a limitation of the rustc API: see comment on
-            // CodegenCx.structs_as_pointer
-            val = val.dereference(self.location).to_rvalue();
-        }
-
+    fn store(&mut self, val: RValue<'gcc>, ptr: RValue<'gcc>, align: Align) -> RValue<'gcc> {
         self.store_with_flags(val, ptr, align, MemFlags::empty())
     }
 
@@ -1508,16 +1497,6 @@ fn extract_value(&mut self, aggregate_value: RValue<'gcc>, idx: u64) -> RValue<'
             element.get_address(self.location)
         } else if value_type.dyncast_vector().is_some() {
             panic!();
-        } else if let Some(pointer_type) = value_type.get_pointee() {
-            if let Some(struct_type) = pointer_type.is_struct() {
-                // NOTE: hack to workaround a limitation of the rustc API: see comment on
-                // CodegenCx.structs_as_pointer
-                aggregate_value
-                    .dereference_field(self.location, struct_type.get_field(idx as i32))
-                    .to_rvalue()
-            } else {
-                panic!("Unexpected type {:?}", value_type);
-            }
         } else if let Some(struct_type) = value_type.is_struct() {
             aggregate_value
                 .access_field(self.location, struct_type.get_field(idx as i32))
@@ -1537,21 +1516,18 @@ fn insert_value(
         assert_eq!(idx as usize as u64, idx);
         let value_type = aggregate_value.get_type();
 
+        let new_val = self.current_func().new_local(None, value_type, "aggregate_value");
+        self.block.add_assignment(None, new_val, aggregate_value);
+
         let lvalue = if value_type.dyncast_array().is_some() {
             let index = self
                 .context
                 .new_rvalue_from_long(self.u64_type, i64::try_from(idx).expect("i64::try_from"));
-            self.context.new_array_access(self.location, aggregate_value, index)
+            self.context.new_array_access(self.location, new_val, index)
         } else if value_type.dyncast_vector().is_some() {
             panic!();
-        } else if let Some(pointer_type) = value_type.get_pointee() {
-            if let Some(struct_type) = pointer_type.is_struct() {
-                // NOTE: hack to workaround a limitation of the rustc API: see comment on
-                // CodegenCx.structs_as_pointer
-                aggregate_value.dereference_field(self.location, struct_type.get_field(idx as i32))
-            } else {
-                panic!("Unexpected type {:?}", value_type);
-            }
+        } else if let Some(struct_type) = value_type.is_struct() {
+            new_val.access_field(None, struct_type.get_field(idx as i32))
         } else {
             panic!("Unexpected type {:?}", value_type);
         };
@@ -1568,7 +1544,7 @@ fn insert_value(
 
         self.llbb().add_assignment(self.location, lvalue, value);
 
-        aggregate_value
+        new_val.to_rvalue()
     }
 
     fn set_personality_fn(&mut self, _personality: Function<'gcc>) {
diff --git a/compiler/rustc_codegen_gcc/src/common.rs b/compiler/rustc_codegen_gcc/src/common.rs
index fdd4782..dd58283 100644
--- a/compiler/rustc_codegen_gcc/src/common.rs
+++ b/compiler/rustc_codegen_gcc/src/common.rs
@@ -117,15 +117,7 @@ fn const_null(&self, typ: Type<'gcc>) -> RValue<'gcc> {
 
     fn const_undef(&self, typ: Type<'gcc>) -> RValue<'gcc> {
         let local = self.current_func.borrow().expect("func").new_local(None, typ, "undefined");
-        if typ.is_struct().is_some() {
-            // NOTE: hack to workaround a limitation of the rustc API: see comment on
-            // CodegenCx.structs_as_pointer
-            let pointer = local.get_address(None);
-            self.structs_as_pointer.borrow_mut().insert(pointer);
-            pointer
-        } else {
-            local.to_rvalue()
-        }
+        local.to_rvalue()
     }
 
     fn const_poison(&self, typ: Type<'gcc>) -> RValue<'gcc> {
@@ -248,7 +240,7 @@ fn scalar_to_backend(&self, cv: Scalar, layout: abi::Scalar, ty: Type<'gcc>) ->
                 }
             }
             Scalar::Ptr(ptr, _size) => {
-                let (prov, offset) = ptr.into_parts(); // we know the `offset` is relative
+                let (prov, offset) = ptr.prov_and_relative_offset();
                 let alloc_id = prov.alloc_id();
                 let base_addr = match self.tcx.global_alloc(alloc_id) {
                     GlobalAlloc::Memory(alloc) => {
diff --git a/compiler/rustc_codegen_gcc/src/context.rs b/compiler/rustc_codegen_gcc/src/context.rs
index 1d02981..665cf22 100644
--- a/compiler/rustc_codegen_gcc/src/context.rs
+++ b/compiler/rustc_codegen_gcc/src/context.rs
@@ -124,14 +124,6 @@ pub struct CodegenCx<'gcc, 'tcx> {
 
     pub pointee_infos: RefCell<FxHashMap<(Ty<'tcx>, Size), Option<PointeeInfo>>>,
 
-    /// NOTE: a hack is used because the rustc API is not suitable to libgccjit and as such,
-    /// `const_undef()` returns struct as pointer so that they can later be assigned a value (in
-    /// e.g. Builder::insert_value).
-    /// As such, this set remembers which of these pointers were returned by this function so that
-    /// they can be dereferenced later.
-    /// FIXME(antoyo): fix the rustc API to avoid having this hack.
-    pub structs_as_pointer: RefCell<FxHashSet<RValue<'gcc>>>,
-
     #[cfg(feature = "master")]
     pub cleanup_blocks: RefCell<FxHashSet<Block<'gcc>>>,
     /// The alignment of a u128/i128 type.
@@ -304,7 +296,6 @@ pub fn new(
             #[cfg(feature = "master")]
             rust_try_fn: Cell::new(None),
             pointee_infos: Default::default(),
-            structs_as_pointer: Default::default(),
             #[cfg(feature = "master")]
             cleanup_blocks: Default::default(),
         };
diff --git a/compiler/rustc_codegen_gcc/src/intrinsic/archs.rs b/compiler/rustc_codegen_gcc/src/intrinsic/archs.rs
index f0352c5..915ed875 100644
--- a/compiler/rustc_codegen_gcc/src/intrinsic/archs.rs
+++ b/compiler/rustc_codegen_gcc/src/intrinsic/archs.rs
@@ -1,9 +1,9 @@
 // File generated by `rustc_codegen_gcc/tools/generate_intrinsics.py`
 // DO NOT EDIT IT!
 /// Translate a given LLVM intrinsic name to an equivalent GCC one.
-fn map_arch_intrinsic(name: &str) -> &str {
-    let Some(name) = name.strip_prefix("llvm.") else {
-        unimplemented!("***** unsupported LLVM intrinsic {}", name)
+fn map_arch_intrinsic(full_name: &str) -> &'static str {
+    let Some(name) = full_name.strip_prefix("llvm.") else {
+        unimplemented!("***** unsupported LLVM intrinsic {}", full_name)
     };
     let Some((arch, name)) = name.split_once('.') else {
         unimplemented!("***** unsupported LLVM intrinsic {}", name)
@@ -11,7 +11,7 @@ fn map_arch_intrinsic(name: &str) -> &str {
     match arch {
         "AMDGPU" => {
             #[allow(non_snake_case)]
-            fn AMDGPU(name: &str) -> &str {
+            fn AMDGPU(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // AMDGPU
                     "div.fixup.f32" => "__builtin_amdgpu_div_fixup",
@@ -42,14 +42,14 @@ fn AMDGPU(name: &str) -> &str {
                     "trig.preop.f64" => "__builtin_amdgpu_trig_preop",
                     "trig.preop.v2f64" => "__builtin_amdgpu_trig_preop",
                     "trig.preop.v4f32" => "__builtin_amdgpu_trig_preop",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            AMDGPU(name)
+            AMDGPU(name, full_name)
         }
         "aarch64" => {
             #[allow(non_snake_case)]
-            fn aarch64(name: &str) -> &str {
+            fn aarch64(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // aarch64
                     "chkfeat" => "__builtin_arm_chkfeat",
@@ -75,14 +75,14 @@ fn aarch64(name: &str) -> &str {
                     "tcommit" => "__builtin_arm_tcommit",
                     "tstart" => "__builtin_arm_tstart",
                     "ttest" => "__builtin_arm_ttest",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            aarch64(name)
+            aarch64(name, full_name)
         }
         "amdgcn" => {
             #[allow(non_snake_case)]
-            fn amdgcn(name: &str) -> &str {
+            fn amdgcn(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // amdgcn
                     "alignbyte" => "__builtin_amdgcn_alignbyte",
@@ -99,6 +99,8 @@ fn amdgcn(name: &str) -> &str {
                     "cvt.f32.fp8" => "__builtin_amdgcn_cvt_f32_fp8",
                     "cvt.off.f32.i4" => "__builtin_amdgcn_cvt_off_f32_i4",
                     "cvt.pk.bf8.f32" => "__builtin_amdgcn_cvt_pk_bf8_f32",
+                    "cvt.pk.f16.bf8" => "__builtin_amdgcn_cvt_pk_f16_bf8",
+                    "cvt.pk.f16.fp8" => "__builtin_amdgcn_cvt_pk_f16_fp8",
                     "cvt.pk.f32.bf8" => "__builtin_amdgcn_cvt_pk_f32_bf8",
                     "cvt.pk.f32.fp8" => "__builtin_amdgcn_cvt_pk_f32_fp8",
                     "cvt.pk.fp8.f32" => "__builtin_amdgcn_cvt_pk_fp8_f32",
@@ -292,6 +294,7 @@ fn amdgcn(name: &str) -> &str {
                     "s.sendmsg" => "__builtin_amdgcn_s_sendmsg",
                     "s.sendmsghalt" => "__builtin_amdgcn_s_sendmsghalt",
                     "s.setprio" => "__builtin_amdgcn_s_setprio",
+                    "s.setprio.inc.wg" => "__builtin_amdgcn_s_setprio_inc_wg",
                     "s.setreg" => "__builtin_amdgcn_s_setreg",
                     "s.sleep" => "__builtin_amdgcn_s_sleep",
                     "s.sleep.var" => "__builtin_amdgcn_s_sleep_var",
@@ -356,14 +359,14 @@ fn amdgcn(name: &str) -> &str {
                     "workitem.id.x" => "__builtin_amdgcn_workitem_id_x",
                     "workitem.id.y" => "__builtin_amdgcn_workitem_id_y",
                     "workitem.id.z" => "__builtin_amdgcn_workitem_id_z",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            amdgcn(name)
+            amdgcn(name, full_name)
         }
         "arm" => {
             #[allow(non_snake_case)]
-            fn arm(name: &str) -> &str {
+            fn arm(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // arm
                     "cdp" => "__builtin_arm_cdp",
@@ -465,14 +468,14 @@ fn arm(name: &str) -> &str {
                     "usub8" => "__builtin_arm_usub8",
                     "uxtab16" => "__builtin_arm_uxtab16",
                     "uxtb16" => "__builtin_arm_uxtb16",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            arm(name)
+            arm(name, full_name)
         }
         "bpf" => {
             #[allow(non_snake_case)]
-            fn bpf(name: &str) -> &str {
+            fn bpf(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // bpf
                     "btf.type.id" => "__builtin_bpf_btf_type_id",
@@ -487,25 +490,25 @@ fn bpf(name: &str) -> &str {
                     "preserve.field.info" => "__builtin_bpf_preserve_field_info",
                     "preserve.type.info" => "__builtin_bpf_preserve_type_info",
                     "pseudo" => "__builtin_bpf_pseudo",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            bpf(name)
+            bpf(name, full_name)
         }
         "cuda" => {
             #[allow(non_snake_case)]
-            fn cuda(name: &str) -> &str {
+            fn cuda(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // cuda
                     "syncthreads" => "__syncthreads",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            cuda(name)
+            cuda(name, full_name)
         }
         "hexagon" => {
             #[allow(non_snake_case)]
-            fn hexagon(name: &str) -> &str {
+            fn hexagon(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // hexagon
                     "A2.abs" => "__builtin_HEXAGON_A2_abs",
@@ -2479,14 +2482,14 @@ fn hexagon(name: &str) -> &str {
                     "prefetch" => "__builtin_HEXAGON_prefetch",
                     "vmemcpy" => "__builtin_hexagon_vmemcpy",
                     "vmemset" => "__builtin_hexagon_vmemset",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            hexagon(name)
+            hexagon(name, full_name)
         }
         "loongarch" => {
             #[allow(non_snake_case)]
-            fn loongarch(name: &str) -> &str {
+            fn loongarch(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // loongarch
                     "asrtgt.d" => "__builtin_loongarch_asrtgt_d",
@@ -3988,14 +3991,14 @@ fn loongarch(name: &str) -> &str {
                     "movfcsr2gr" => "__builtin_loongarch_movfcsr2gr",
                     "movgr2fcsr" => "__builtin_loongarch_movgr2fcsr",
                     "syscall" => "__builtin_loongarch_syscall",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            loongarch(name)
+            loongarch(name, full_name)
         }
         "mips" => {
             #[allow(non_snake_case)]
-            fn mips(name: &str) -> &str {
+            fn mips(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // mips
                     "absq.s.ph" => "__builtin_mips_absq_s_ph",
@@ -4669,14 +4672,14 @@ fn mips(name: &str) -> &str {
                     "wrdsp" => "__builtin_mips_wrdsp",
                     "xor.v" => "__builtin_msa_xor_v",
                     "xori.b" => "__builtin_msa_xori_b",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            mips(name)
+            mips(name, full_name)
         }
         "nvvm" => {
             #[allow(non_snake_case)]
-            fn nvvm(name: &str) -> &str {
+            fn nvvm(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // nvvm
                     "abs.i" => "__nvvm_abs_i",
@@ -5024,6 +5027,7 @@ fn nvvm(name: &str) -> &str {
                     "nanosleep" => "__nvvm_nanosleep",
                     "neg.bf16" => "__nvvm_neg_bf16",
                     "neg.bf16x2" => "__nvvm_neg_bf16x2",
+                    "pm.event.mask" => "__nvvm_pm_event_mask",
                     "popc.i" => "__nvvm_popc_i",
                     "popc.ll" => "__nvvm_popc_ll",
                     "prmt" => "__nvvm_prmt",
@@ -5448,14 +5452,14 @@ fn nvvm(name: &str) -> &str {
                     "vote.ballot.sync" => "__nvvm_vote_ballot_sync",
                     "vote.uni" => "__nvvm_vote_uni",
                     "vote.uni.sync" => "__nvvm_vote_uni_sync",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            nvvm(name)
+            nvvm(name, full_name)
         }
         "ppc" => {
             #[allow(non_snake_case)]
-            fn ppc(name: &str) -> &str {
+            fn ppc(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // ppc
                     "addex" => "__builtin_ppc_addex",
@@ -5842,7 +5846,10 @@ fn ppc(name: &str) -> &str {
                     "mulhdu" => "__builtin_ppc_mulhdu",
                     "mulhw" => "__builtin_ppc_mulhw",
                     "mulhwu" => "__builtin_ppc_mulhwu",
+                    "national2packed" => "__builtin_ppc_national2packed",
                     "pack.longdouble" => "__builtin_pack_longdouble",
+                    "packed2national" => "__builtin_ppc_packed2national",
+                    "packed2zoned" => "__builtin_ppc_packed2zoned",
                     "pdepd" => "__builtin_pdepd",
                     "pextd" => "__builtin_pextd",
                     "qpx.qvfabs" => "__builtin_qpx_qvfabs",
@@ -6035,14 +6042,15 @@ fn ppc(name: &str) -> &str {
                     "vsx.xxinsertw" => "__builtin_vsx_xxinsertw",
                     "vsx.xxleqv" => "__builtin_vsx_xxleqv",
                     "vsx.xxpermx" => "__builtin_vsx_xxpermx",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    "zoned2packed" => "__builtin_ppc_zoned2packed",
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            ppc(name)
+            ppc(name, full_name)
         }
         "ptx" => {
             #[allow(non_snake_case)]
-            fn ptx(name: &str) -> &str {
+            fn ptx(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // ptx
                     "bar.sync" => "__builtin_ptx_bar_sync",
@@ -6063,14 +6071,14 @@ fn ptx(name: &str) -> &str {
                     "read.pm3" => "__builtin_ptx_read_pm3",
                     "read.smid" => "__builtin_ptx_read_smid",
                     "read.warpid" => "__builtin_ptx_read_warpid",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            ptx(name)
+            ptx(name, full_name)
         }
         "r600" => {
             #[allow(non_snake_case)]
-            fn r600(name: &str) -> &str {
+            fn r600(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // r600
                     "group.barrier" => "__builtin_r600_group_barrier",
@@ -6088,14 +6096,14 @@ fn r600(name: &str) -> &str {
                     "read.tidig.x" => "__builtin_r600_read_tidig_x",
                     "read.tidig.y" => "__builtin_r600_read_tidig_y",
                     "read.tidig.z" => "__builtin_r600_read_tidig_z",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            r600(name)
+            r600(name, full_name)
         }
         "riscv" => {
             #[allow(non_snake_case)]
-            fn riscv(name: &str) -> &str {
+            fn riscv(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // riscv
                     "aes32dsi" => "__builtin_riscv_aes32dsi",
@@ -6119,14 +6127,14 @@ fn riscv(name: &str) -> &str {
                     "sha512sum0r" => "__builtin_riscv_sha512sum0r",
                     "sha512sum1" => "__builtin_riscv_sha512sum1",
                     "sha512sum1r" => "__builtin_riscv_sha512sum1r",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            riscv(name)
+            riscv(name, full_name)
         }
         "s390" => {
             #[allow(non_snake_case)]
-            fn s390(name: &str) -> &str {
+            fn s390(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // s390
                     "bdepg" => "__builtin_s390_bdepg",
@@ -6313,14 +6321,14 @@ fn s390(name: &str) -> &str {
                     "vupllf" => "__builtin_s390_vupllf",
                     "vupllg" => "__builtin_s390_vupllg",
                     "vupllh" => "__builtin_s390_vupllh",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            s390(name)
+            s390(name, full_name)
         }
         "ve" => {
             #[allow(non_snake_case)]
-            fn ve(name: &str) -> &str {
+            fn ve(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // ve
                     "vl.andm.MMM" => "__builtin_ve_vl_andm_MMM",
@@ -7586,14 +7594,14 @@ fn ve(name: &str) -> &str {
                     "vl.vxor.vvvvl" => "__builtin_ve_vl_vxor_vvvvl",
                     "vl.xorm.MMM" => "__builtin_ve_vl_xorm_MMM",
                     "vl.xorm.mmm" => "__builtin_ve_vl_xorm_mmm",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            ve(name)
+            ve(name, full_name)
         }
         "x86" => {
             #[allow(non_snake_case)]
-            fn x86(name: &str) -> &str {
+            fn x86(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // x86
                     "aadd32" => "__builtin_ia32_aadd32",
@@ -10154,25 +10162,25 @@ fn x86(name: &str) -> &str {
                     "xresldtrk" => "__builtin_ia32_xresldtrk",
                     "xsusldtrk" => "__builtin_ia32_xsusldtrk",
                     "xtest" => "__builtin_ia32_xtest",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            x86(name)
+            x86(name, full_name)
         }
         "xcore" => {
             #[allow(non_snake_case)]
-            fn xcore(name: &str) -> &str {
+            fn xcore(name: &str, full_name: &str) -> &'static str {
                 match name {
                     // xcore
                     "bitrev" => "__builtin_bitrev",
                     "getid" => "__builtin_getid",
                     "getps" => "__builtin_getps",
                     "setps" => "__builtin_setps",
-                    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+                    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),
                 }
             }
-            xcore(name)
+            xcore(name, full_name)
         }
-        _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),
+        _ => unimplemented!("***** unsupported LLVM architecture {arch}, intrinsic:{full_name}"),
     }
 }
diff --git a/compiler/rustc_codegen_gcc/src/intrinsic/llvm.rs b/compiler/rustc_codegen_gcc/src/intrinsic/llvm.rs
index 0b77694..39dba28 100644
--- a/compiler/rustc_codegen_gcc/src/intrinsic/llvm.rs
+++ b/compiler/rustc_codegen_gcc/src/intrinsic/llvm.rs
@@ -648,6 +648,11 @@ pub fn adjust_intrinsic_arguments<'a, 'b, 'gcc, 'tcx>(
                 new_args.push(handle);
                 args = new_args.into();
             }
+            "__builtin_ia32_rdtscp" => {
+                let result = builder.current_func().new_local(None, builder.u32_type, "result");
+                let new_args = vec![result.get_address(None).to_rvalue()];
+                args = new_args.into();
+            }
             _ => (),
         }
     } else {
@@ -764,6 +769,14 @@ pub fn adjust_intrinsic_arguments<'a, 'b, 'gcc, 'tcx>(
                 new_args.swap(0, 1);
                 args = new_args.into();
             }
+            "__builtin_ia32_dpps256" => {
+                let mut new_args = args.to_vec();
+                // NOTE: without this cast to u8 (and it needs to be a u8 to fix the issue), we
+                // would get the following error:
+                // the last argument must be an 8-bit immediate
+                new_args[2] = builder.context.new_cast(None, new_args[2], builder.cx.type_u8());
+                args = new_args.into();
+            }
             _ => (),
         }
     }
@@ -935,6 +948,19 @@ pub fn adjust_intrinsic_return_value<'a, 'gcc, 'tcx>(
             );
             return_value = result.to_rvalue();
         }
+        "__builtin_ia32_rdtscp" => {
+            let field1 = builder.context.new_field(None, return_value.get_type(), "rdtscpField1");
+            let return2 = args[0].dereference(None).to_rvalue();
+            let field2 = builder.context.new_field(None, return2.get_type(), "rdtscpField2");
+            let struct_type =
+                builder.context.new_struct_type(None, "rdtscpResult", &[field1, field2]);
+            return_value = builder.context.new_struct_constructor(
+                None,
+                struct_type.as_type(),
+                None,
+                &[return_value, return2],
+            );
+        }
         _ => (),
     }
 
@@ -1529,6 +1555,17 @@ pub fn intrinsic<'gcc, 'tcx>(name: &str, cx: &CodegenCx<'gcc, 'tcx>) -> Function
         "llvm.x86.aesdecwide128kl" => "__builtin_ia32_aesdecwide128kl_u8",
         "llvm.x86.aesencwide256kl" => "__builtin_ia32_aesencwide256kl_u8",
         "llvm.x86.aesdecwide256kl" => "__builtin_ia32_aesdecwide256kl_u8",
+        "llvm.x86.avx512.uitofp.round.v8f16.v8i16" => "__builtin_ia32_vcvtuw2ph128_mask",
+        "llvm.x86.avx512.uitofp.round.v16f16.v16i16" => "__builtin_ia32_vcvtuw2ph256_mask",
+        "llvm.x86.avx512.uitofp.round.v32f16.v32i16" => "__builtin_ia32_vcvtuw2ph512_mask_round",
+        "llvm.x86.avx512.uitofp.round.v8f16.v8i32" => "__builtin_ia32_vcvtudq2ph256_mask",
+        "llvm.x86.avx512.uitofp.round.v16f16.v16i32" => "__builtin_ia32_vcvtudq2ph512_mask_round",
+        "llvm.x86.avx512.uitofp.round.v8f16.v8i64" => "__builtin_ia32_vcvtuqq2ph512_mask_round",
+        "llvm.x86.avx512.uitofp.round.v8f64.v8i64" => "__builtin_ia32_cvtuqq2pd512_mask",
+        "llvm.x86.avx512.uitofp.round.v2f64.v2i64" => "__builtin_ia32_cvtuqq2pd128_mask",
+        "llvm.x86.avx512.uitofp.round.v4f64.v4i64" => "__builtin_ia32_cvtuqq2pd256_mask",
+        "llvm.x86.avx512.uitofp.round.v8f32.v8i64" => "__builtin_ia32_cvtuqq2ps512_mask",
+        "llvm.x86.avx512.uitofp.round.v4f32.v4i64" => "__builtin_ia32_cvtuqq2ps256_mask",
 
         // TODO: support the tile builtins:
         "llvm.x86.ldtilecfg" => "__builtin_trap",
diff --git a/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs b/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs
index 4c10380..4976059 100644
--- a/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs
+++ b/compiler/rustc_codegen_gcc/src/intrinsic/mod.rs
@@ -114,7 +114,6 @@ fn get_simple_intrinsic<'gcc, 'tcx>(
         }
         sym::copysignf32 => "copysignf",
         sym::copysignf64 => "copysign",
-        sym::copysignf128 => "copysignl",
         sym::floorf32 => "floorf",
         sym::floorf64 => "floor",
         sym::ceilf32 => "ceilf",
@@ -238,6 +237,7 @@ fn get_simple_function_f128_2args<'gcc, 'tcx>(
     let func_name = match name {
         sym::maxnumf128 => "fmaxf128",
         sym::minnumf128 => "fminf128",
+        sym::copysignf128 => "copysignf128",
         _ => return None,
     };
     Some(cx.context.new_function(
@@ -261,6 +261,7 @@ fn f16_builtin<'gcc, 'tcx>(
     let f32_type = cx.type_f32();
     let builtin_name = match name {
         sym::ceilf16 => "__builtin_ceilf",
+        sym::copysignf16 => "__builtin_copysignf",
         sym::floorf16 => "__builtin_floorf",
         sym::fmaf16 => "fmaf",
         sym::maxnumf16 => "__builtin_fmaxf",
@@ -330,6 +331,7 @@ fn codegen_intrinsic_call(
                 )
             }
             sym::ceilf16
+            | sym::copysignf16
             | sym::floorf16
             | sym::fmaf16
             | sym::maxnumf16
diff --git a/compiler/rustc_codegen_gcc/tools/generate_intrinsics.py b/compiler/rustc_codegen_gcc/tools/generate_intrinsics.py
index ed0ebf0..88927f3 100644
--- a/compiler/rustc_codegen_gcc/tools/generate_intrinsics.py
+++ b/compiler/rustc_codegen_gcc/tools/generate_intrinsics.py
@@ -176,14 +176,14 @@
         out.write("// File generated by `rustc_codegen_gcc/tools/generate_intrinsics.py`\n")
         out.write("// DO NOT EDIT IT!\n")
         out.write("/// Translate a given LLVM intrinsic name to an equivalent GCC one.\n")
-        out.write("fn map_arch_intrinsic(name:&str)->&str{\n")
-        out.write('let Some(name) = name.strip_prefix("llvm.") else { unimplemented!("***** unsupported LLVM intrinsic {}", name) };\n')
+        out.write("fn map_arch_intrinsic(full_name:&str)->&'static str{\n")
+        out.write('let Some(name) = full_name.strip_prefix("llvm.") else { unimplemented!("***** unsupported LLVM intrinsic {}", full_name) };\n')
         out.write('let Some((arch, name)) = name.split_once(\'.\') else { unimplemented!("***** unsupported LLVM intrinsic {}", name) };\n')
         out.write("match arch {\n")
         for arch in archs:
             if len(intrinsics[arch]) == 0:
                 continue
-            out.write("\"{}\" => {{ #[allow(non_snake_case)] fn {}(name: &str) -> &str {{ match name {{".format(arch,arch))
+            out.write("\"{}\" => {{ #[allow(non_snake_case)] fn {}(name: &str,full_name:&str) -> &'static str {{ match name {{".format(arch,arch))
             intrinsics[arch].sort(key=lambda x: (x[0], x[2]))
             out.write('    // {}\n'.format(arch))
             for entry in intrinsics[arch]:
@@ -196,9 +196,9 @@
                     out.write('    // [INVALID CONVERSION]: "{}" => "{}",\n'.format(llvm_name, entry[1]))
                 else:
                     out.write('    "{}" => "{}",\n'.format(llvm_name, entry[1]))
-            out.write('    _ => unimplemented!("***** unsupported LLVM intrinsic {}", name),\n')
-            out.write("}} }} {}(name) }}\n,".format(arch))
-        out.write('    _ => unimplemented!("***** unsupported LLVM architecture {}", name),\n')
+            out.write('    _ => unimplemented!("***** unsupported LLVM intrinsic {full_name}"),\n')
+            out.write("}} }} {}(name,full_name) }}\n,".format(arch))
+        out.write('    _ => unimplemented!("***** unsupported LLVM architecture {arch}, intrinsic:{full_name}"),\n')
         out.write("}\n}")
     subprocess.call(["rustfmt", output_file])
     print("Done!")
diff --git a/compiler/rustc_codegen_llvm/src/common.rs b/compiler/rustc_codegen_llvm/src/common.rs
index ae5add5..7cfab25 100644
--- a/compiler/rustc_codegen_llvm/src/common.rs
+++ b/compiler/rustc_codegen_llvm/src/common.rs
@@ -268,7 +268,7 @@ fn scalar_to_backend(&self, cv: Scalar, layout: abi::Scalar, llty: &'ll Type) ->
                 }
             }
             Scalar::Ptr(ptr, _size) => {
-                let (prov, offset) = ptr.into_parts();
+                let (prov, offset) = ptr.prov_and_relative_offset();
                 let global_alloc = self.tcx.global_alloc(prov.alloc_id());
                 let base_addr = match global_alloc {
                     GlobalAlloc::Memory(alloc) => {
diff --git a/compiler/rustc_codegen_llvm/src/llvm_util.rs b/compiler/rustc_codegen_llvm/src/llvm_util.rs
index 6fd07d5..0fb987b 100644
--- a/compiler/rustc_codegen_llvm/src/llvm_util.rs
+++ b/compiler/rustc_codegen_llvm/src/llvm_util.rs
@@ -370,10 +370,18 @@ fn update_target_reliable_float_cfg(sess: &Session, cfg: &mut TargetConfig) {
     let target_env = sess.target.options.env.as_ref();
     let target_abi = sess.target.options.abi.as_ref();
     let target_pointer_width = sess.target.pointer_width;
+    let version = get_version();
 
     cfg.has_reliable_f16 = match (target_arch, target_os) {
         // Selection failure <https://github.com/llvm/llvm-project/issues/50374>
         ("s390x", _) => false,
+        // LLVM crash without neon <https://github.com/llvm/llvm-project/issues/129394> (now fixed)
+        ("aarch64", _)
+            if !cfg.target_features.iter().any(|f| f.as_str() == "neon")
+                && version < (20, 1, 1) =>
+        {
+            false
+        }
         // Unsupported <https://github.com/llvm/llvm-project/issues/94434>
         ("arm64ec", _) => false,
         // MinGW ABI bugs <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115054>
diff --git a/compiler/rustc_codegen_ssa/src/back/linker.rs b/compiler/rustc_codegen_ssa/src/back/linker.rs
index ede1149..1896f63 100644
--- a/compiler/rustc_codegen_ssa/src/back/linker.rs
+++ b/compiler/rustc_codegen_ssa/src/back/linker.rs
@@ -1794,7 +1794,10 @@ fn for_each_exported_symbols_include_dep<'tcx>(
     for (cnum, dep_format) in deps.iter_enumerated() {
         // For each dependency that we are linking to statically ...
         if *dep_format == Linkage::Static {
-            for &(symbol, info) in tcx.exported_symbols(cnum).iter() {
+            for &(symbol, info) in tcx.exported_non_generic_symbols(cnum).iter() {
+                callback(symbol, info, cnum);
+            }
+            for &(symbol, info) in tcx.exported_generic_symbols(cnum).iter() {
                 callback(symbol, info, cnum);
             }
         }
diff --git a/compiler/rustc_codegen_ssa/src/back/symbol_export.rs b/compiler/rustc_codegen_ssa/src/back/symbol_export.rs
index 75f7a46..2f5eca2 100644
--- a/compiler/rustc_codegen_ssa/src/back/symbol_export.rs
+++ b/compiler/rustc_codegen_ssa/src/back/symbol_export.rs
@@ -168,7 +168,7 @@ fn is_reachable_non_generic_provider_extern(tcx: TyCtxt<'_>, def_id: DefId) -> b
     tcx.reachable_non_generics(def_id.krate).contains_key(&def_id)
 }
 
-fn exported_symbols_provider_local<'tcx>(
+fn exported_non_generic_symbols_provider_local<'tcx>(
     tcx: TyCtxt<'tcx>,
     _: LocalCrate,
 ) -> &'tcx [(ExportedSymbol<'tcx>, SymbolExportInfo)] {
@@ -306,6 +306,22 @@ fn exported_symbols_provider_local<'tcx>(
         ));
     }
 
+    // Sort so we get a stable incr. comp. hash.
+    symbols.sort_by_cached_key(|s| s.0.symbol_name_for_local_instance(tcx));
+
+    tcx.arena.alloc_from_iter(symbols)
+}
+
+fn exported_generic_symbols_provider_local<'tcx>(
+    tcx: TyCtxt<'tcx>,
+    _: LocalCrate,
+) -> &'tcx [(ExportedSymbol<'tcx>, SymbolExportInfo)] {
+    if !tcx.sess.opts.output_types.should_codegen() && !tcx.is_sdylib_interface_build() {
+        return &[];
+    }
+
+    let mut symbols: Vec<_> = vec![];
+
     if tcx.local_crate_exports_generics() {
         use rustc_middle::mir::mono::{Linkage, MonoItem, Visibility};
         use rustc_middle::ty::InstanceKind;
@@ -474,7 +490,7 @@ fn upstream_monomorphizations_provider(
     let async_drop_in_place_fn_def_id = tcx.lang_items().async_drop_in_place_fn();
 
     for &cnum in cnums.iter() {
-        for (exported_symbol, _) in tcx.exported_symbols(cnum).iter() {
+        for (exported_symbol, _) in tcx.exported_generic_symbols(cnum).iter() {
             let (def_id, args) = match *exported_symbol {
                 ExportedSymbol::Generic(def_id, args) => (def_id, args),
                 ExportedSymbol::DropGlue(ty) => {
@@ -496,10 +512,7 @@ fn upstream_monomorphizations_provider(
                 ExportedSymbol::AsyncDropGlue(def_id, ty) => (def_id, tcx.mk_args(&[ty.into()])),
                 ExportedSymbol::NonGeneric(..)
                 | ExportedSymbol::ThreadLocalShim(..)
-                | ExportedSymbol::NoDefId(..) => {
-                    // These are no monomorphizations
-                    continue;
-                }
+                | ExportedSymbol::NoDefId(..) => unreachable!("{exported_symbol:?}"),
             };
 
             let args_map = instances.entry(def_id).or_default();
@@ -554,7 +567,8 @@ fn is_unreachable_local_definition_provider(tcx: TyCtxt<'_>, def_id: LocalDefId)
 pub(crate) fn provide(providers: &mut Providers) {
     providers.reachable_non_generics = reachable_non_generics_provider;
     providers.is_reachable_non_generic = is_reachable_non_generic_provider_local;
-    providers.exported_symbols = exported_symbols_provider_local;
+    providers.exported_non_generic_symbols = exported_non_generic_symbols_provider_local;
+    providers.exported_generic_symbols = exported_generic_symbols_provider_local;
     providers.upstream_monomorphizations = upstream_monomorphizations_provider;
     providers.is_unreachable_local_definition = is_unreachable_local_definition_provider;
     providers.upstream_drop_glue_for = upstream_drop_glue_for_provider;
diff --git a/compiler/rustc_codegen_ssa/src/back/write.rs b/compiler/rustc_codegen_ssa/src/back/write.rs
index c3bfe4c..8330e4f 100644
--- a/compiler/rustc_codegen_ssa/src/back/write.rs
+++ b/compiler/rustc_codegen_ssa/src/back/write.rs
@@ -1124,8 +1124,9 @@ fn start_executing_work<B: ExtraBackendMethods>(
 
         let copy_symbols = |cnum| {
             let symbols = tcx
-                .exported_symbols(cnum)
+                .exported_non_generic_symbols(cnum)
                 .iter()
+                .chain(tcx.exported_generic_symbols(cnum))
                 .map(|&(s, lvl)| (symbol_name_for_instance_in_crate(tcx, s, cnum), lvl))
                 .collect();
             Arc::new(symbols)
diff --git a/compiler/rustc_codegen_ssa/src/base.rs b/compiler/rustc_codegen_ssa/src/base.rs
index b06cfd1..102d4ea 100644
--- a/compiler/rustc_codegen_ssa/src/base.rs
+++ b/compiler/rustc_codegen_ssa/src/base.rs
@@ -262,28 +262,6 @@ pub(crate) fn unsize_ptr<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(
     }
 }
 
-/// Coerces `src` to `dst_ty` which is guaranteed to be a `dyn*` type.
-pub(crate) fn cast_to_dyn_star<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(
-    bx: &mut Bx,
-    src: Bx::Value,
-    src_ty_and_layout: TyAndLayout<'tcx>,
-    dst_ty: Ty<'tcx>,
-    old_info: Option<Bx::Value>,
-) -> (Bx::Value, Bx::Value) {
-    debug!("cast_to_dyn_star: {:?} => {:?}", src_ty_and_layout.ty, dst_ty);
-    assert!(
-        matches!(dst_ty.kind(), ty::Dynamic(_, _, ty::DynStar)),
-        "destination type must be a dyn*"
-    );
-    let src = match bx.cx().type_kind(bx.cx().backend_type(src_ty_and_layout)) {
-        TypeKind::Pointer => src,
-        TypeKind::Integer => bx.inttoptr(src, bx.type_ptr()),
-        // FIXME(dyn-star): We probably have to do a bitcast first, then inttoptr.
-        kind => bug!("unexpected TypeKind for left-hand side of `dyn*` cast: {kind:?}"),
-    };
-    (src, unsized_info(bx, src_ty_and_layout.ty, dst_ty, old_info))
-}
-
 /// Coerces `src`, which is a reference to a value of type `src_ty`,
 /// to a value of type `dst_ty`, and stores the result in `dst`.
 pub(crate) fn coerce_unsized_into<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(
diff --git a/compiler/rustc_codegen_ssa/src/codegen_attrs.rs b/compiler/rustc_codegen_ssa/src/codegen_attrs.rs
index 7680f8e..6e21438 100644
--- a/compiler/rustc_codegen_ssa/src/codegen_attrs.rs
+++ b/compiler/rustc_codegen_ssa/src/codegen_attrs.rs
@@ -1,6 +1,6 @@
 use std::str::FromStr;
 
-use rustc_abi::ExternAbi;
+use rustc_abi::{Align, ExternAbi};
 use rustc_ast::expand::autodiff_attrs::{AutoDiffAttrs, DiffActivity, DiffMode};
 use rustc_ast::{LitKind, MetaItem, MetaItemInner, attr};
 use rustc_attr_data_structures::{
@@ -124,6 +124,9 @@ fn codegen_fn_attrs(tcx: TyCtxt<'_>, did: LocalDefId) -> CodegenFnAttrs {
                 AttributeKind::Naked(_) => codegen_fn_attrs.flags |= CodegenFnAttrFlags::NAKED,
                 AttributeKind::Align { align, .. } => codegen_fn_attrs.alignment = Some(*align),
                 AttributeKind::LinkName { name, .. } => codegen_fn_attrs.link_name = Some(*name),
+                AttributeKind::LinkSection { name, .. } => {
+                    codegen_fn_attrs.link_section = Some(*name)
+                }
                 AttributeKind::NoMangle(attr_span) => {
                     if tcx.opt_item_name(did.to_def_id()).is_some() {
                         codegen_fn_attrs.flags |= CodegenFnAttrFlags::NO_MANGLE;
@@ -253,16 +256,6 @@ fn codegen_fn_attrs(tcx: TyCtxt<'_>, did: LocalDefId) -> CodegenFnAttrs {
                     }
                 }
             }
-            sym::link_section => {
-                if let Some(val) = attr.value_str() {
-                    if val.as_str().bytes().any(|b| b == 0) {
-                        let msg = format!("illegal null byte in link_section value: `{val}`");
-                        tcx.dcx().span_err(attr.span(), msg);
-                    } else {
-                        codegen_fn_attrs.link_section = Some(val);
-                    }
-                }
-            }
             sym::link_ordinal => {
                 link_ordinal_span = Some(attr.span());
                 if let ordinal @ Some(_) = check_link_ordinal(tcx, attr) {
@@ -402,6 +395,9 @@ fn codegen_fn_attrs(tcx: TyCtxt<'_>, did: LocalDefId) -> CodegenFnAttrs {
     codegen_fn_attrs.alignment =
         Ord::max(codegen_fn_attrs.alignment, tcx.sess.opts.unstable_opts.min_function_alignment);
 
+    // On trait methods, inherit the `#[align]` of the trait's method prototype.
+    codegen_fn_attrs.alignment = Ord::max(codegen_fn_attrs.alignment, tcx.inherited_align(did));
+
     let inline_span;
     (codegen_fn_attrs.inline, inline_span) = if let Some((inline_attr, span)) =
         find_attr!(attrs, AttributeKind::Inline(i, span) => (*i, *span))
@@ -556,17 +552,26 @@ fn codegen_fn_attrs(tcx: TyCtxt<'_>, did: LocalDefId) -> CodegenFnAttrs {
     codegen_fn_attrs
 }
 
+/// If the provided DefId is a method in a trait impl, return the DefId of the method prototype.
+fn opt_trait_item(tcx: TyCtxt<'_>, def_id: DefId) -> Option<DefId> {
+    let impl_item = tcx.opt_associated_item(def_id)?;
+    match impl_item.container {
+        ty::AssocItemContainer::Impl => impl_item.trait_item_def_id,
+        _ => None,
+    }
+}
+
 /// Checks if the provided DefId is a method in a trait impl for a trait which has track_caller
 /// applied to the method prototype.
 fn should_inherit_track_caller(tcx: TyCtxt<'_>, def_id: DefId) -> bool {
-    if let Some(impl_item) = tcx.opt_associated_item(def_id)
-        && let ty::AssocItemContainer::Impl = impl_item.container
-        && let Some(trait_item) = impl_item.trait_item_def_id
-    {
-        return tcx.codegen_fn_attrs(trait_item).flags.intersects(CodegenFnAttrFlags::TRACK_CALLER);
-    }
+    let Some(trait_item) = opt_trait_item(tcx, def_id) else { return false };
+    tcx.codegen_fn_attrs(trait_item).flags.intersects(CodegenFnAttrFlags::TRACK_CALLER)
+}
 
-    false
+/// If the provided DefId is a method in a trait impl, return the value of the `#[align]`
+/// attribute on the method prototype (if any).
+fn inherited_align<'tcx>(tcx: TyCtxt<'tcx>, def_id: DefId) -> Option<Align> {
+    tcx.codegen_fn_attrs(opt_trait_item(tcx, def_id)?).alignment
 }
 
 fn check_link_ordinal(tcx: TyCtxt<'_>, attr: &hir::Attribute) -> Option<u16> {
@@ -734,5 +739,6 @@ fn autodiff_attrs(tcx: TyCtxt<'_>, id: DefId) -> Option<AutoDiffAttrs> {
 }
 
 pub(crate) fn provide(providers: &mut Providers) {
-    *providers = Providers { codegen_fn_attrs, should_inherit_track_caller, ..*providers };
+    *providers =
+        Providers { codegen_fn_attrs, should_inherit_track_caller, inherited_align, ..*providers };
 }
diff --git a/compiler/rustc_codegen_ssa/src/mir/block.rs b/compiler/rustc_codegen_ssa/src/mir/block.rs
index 1d5fbfc..bde63fd 100644
--- a/compiler/rustc_codegen_ssa/src/mir/block.rs
+++ b/compiler/rustc_codegen_ssa/src/mir/block.rs
@@ -628,50 +628,6 @@ fn codegen_drop_terminator(
                     virtual_drop,
                 )
             }
-            ty::Dynamic(_, _, ty::DynStar) => {
-                // IN THIS ARM, WE HAVE:
-                // ty = *mut (dyn* Trait)
-                // which is: *mut exists<T: sizeof(T) == sizeof(usize)> (T, Vtable<T: Trait>)
-                //
-                // args = [ * ]
-                //          |
-                //          v
-                //      ( Data, Vtable )
-                //                |
-                //                v
-                //              /-------\
-                //              | ...   |
-                //              \-------/
-                //
-                //
-                // WE CAN CONVERT THIS INTO THE ABOVE LOGIC BY DOING
-                //
-                // data = &(*args[0]).0    // gives a pointer to Data above (really the same pointer)
-                // vtable = (*args[0]).1   // loads the vtable out
-                // (data, vtable)          // an equivalent Rust `*mut dyn Trait`
-                //
-                // SO THEN WE CAN USE THE ABOVE CODE.
-                let virtual_drop = Instance {
-                    def: ty::InstanceKind::Virtual(drop_fn.def_id(), 0), // idx 0: the drop function
-                    args: drop_fn.args,
-                };
-                debug!("ty = {:?}", ty);
-                debug!("drop_fn = {:?}", drop_fn);
-                debug!("args = {:?}", args);
-                let fn_abi = bx.fn_abi_of_instance(virtual_drop, ty::List::empty());
-                let meta_ptr = place.project_field(bx, 1);
-                let meta = bx.load_operand(meta_ptr);
-                // Truncate vtable off of args list
-                args = &args[..1];
-                debug!("args' = {:?}", args);
-                (
-                    true,
-                    meth::VirtualIndex::from_index(ty::COMMON_VTABLE_ENTRIES_DROPINPLACE)
-                        .get_optional_fn(bx, meta.immediate(), ty, fn_abi),
-                    fn_abi,
-                    virtual_drop,
-                )
-            }
             _ => (
                 false,
                 bx.get_fn_addr(drop_fn),
@@ -1108,33 +1064,6 @@ fn codegen_call_terminator(
                         llargs.push(data_ptr);
                         continue;
                     }
-                    Immediate(_) => {
-                        // See comment above explaining why we peel these newtypes
-                        while !op.layout.ty.is_raw_ptr() && !op.layout.ty.is_ref() {
-                            let (idx, _) = op.layout.non_1zst_field(bx).expect(
-                                "not exactly one non-1-ZST field in a `DispatchFromDyn` type",
-                            );
-                            op = op.extract_field(self, bx, idx.as_usize());
-                        }
-
-                        // Make sure that we've actually unwrapped the rcvr down
-                        // to a pointer or ref to `dyn* Trait`.
-                        if !op.layout.ty.builtin_deref(true).unwrap().is_dyn_star() {
-                            span_bug!(fn_span, "can't codegen a virtual call on {:#?}", op);
-                        }
-                        let place = op.deref(bx.cx());
-                        let data_place = place.project_field(bx, 0);
-                        let meta_place = place.project_field(bx, 1);
-                        let meta = bx.load_operand(meta_place);
-                        llfn = Some(meth::VirtualIndex::from_index(idx).get_fn(
-                            bx,
-                            meta.immediate(),
-                            op.layout.ty,
-                            fn_abi,
-                        ));
-                        llargs.push(data_place.val.llval);
-                        continue;
-                    }
                     _ => {
                         span_bug!(fn_span, "can't codegen a virtual call on {:#?}", op);
                     }
diff --git a/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs b/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs
index 27fcab8..fc95f62 100644
--- a/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs
+++ b/compiler/rustc_codegen_ssa/src/mir/intrinsic.rs
@@ -1,7 +1,7 @@
 use rustc_abi::WrappingRange;
-use rustc_middle::bug;
 use rustc_middle::mir::SourceInfo;
 use rustc_middle::ty::{self, Ty, TyCtxt};
+use rustc_middle::{bug, span_bug};
 use rustc_session::config::OptLevel;
 use rustc_span::sym;
 
@@ -98,6 +98,27 @@ pub fn codegen_intrinsic_call(
             discr.to_atomic_ordering()
         };
 
+        if args.is_empty() {
+            match name {
+                sym::abort
+                | sym::unreachable
+                | sym::cold_path
+                | sym::breakpoint
+                | sym::assert_zero_valid
+                | sym::assert_mem_uninitialized_valid
+                | sym::assert_inhabited
+                | sym::ub_checks
+                | sym::contract_checks
+                | sym::atomic_fence
+                | sym::atomic_singlethreadfence
+                | sym::caller_location => {}
+                _ => {
+                    span_bug!(span, "nullary intrinsic {name} must either be in a const block or explicitly opted out because it is inherently a runtime intrinsic
+");
+                }
+            }
+        }
+
         let llval = match name {
             sym::abort => {
                 bx.abort();
@@ -150,10 +171,6 @@ pub fn codegen_intrinsic_call(
                 }
                 value
             }
-            sym::needs_drop | sym::type_id | sym::type_name | sym::variant_count => {
-                let value = bx.tcx().const_eval_instance(bx.typing_env(), instance, span).unwrap();
-                OperandRef::from_const(bx, value, result.layout.ty).immediate_or_packed_pair(bx)
-            }
             sym::arith_offset => {
                 let ty = fn_args.type_at(0);
                 let layout = bx.layout_of(ty);
diff --git a/compiler/rustc_codegen_ssa/src/mir/mod.rs b/compiler/rustc_codegen_ssa/src/mir/mod.rs
index 66c4af4..10b44a1 100644
--- a/compiler/rustc_codegen_ssa/src/mir/mod.rs
+++ b/compiler/rustc_codegen_ssa/src/mir/mod.rs
@@ -354,15 +354,15 @@ fn optimize_use_clone<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(
 
             let destination_block = target.unwrap();
 
-            bb.statements.push(mir::Statement {
-                source_info: bb.terminator().source_info,
-                kind: mir::StatementKind::Assign(Box::new((
+            bb.statements.push(mir::Statement::new(
+                bb.terminator().source_info,
+                mir::StatementKind::Assign(Box::new((
                     *destination,
                     mir::Rvalue::Use(mir::Operand::Copy(
                         arg_place.project_deeper(&[mir::ProjectionElem::Deref], tcx),
                     )),
                 ))),
-            });
+            ));
 
             bb.terminator_mut().kind = mir::TerminatorKind::Goto { target: destination_block };
         }
diff --git a/compiler/rustc_codegen_ssa/src/mir/rvalue.rs b/compiler/rustc_codegen_ssa/src/mir/rvalue.rs
index db5ac6a..7ef0421 100644
--- a/compiler/rustc_codegen_ssa/src/mir/rvalue.rs
+++ b/compiler/rustc_codegen_ssa/src/mir/rvalue.rs
@@ -468,12 +468,6 @@ pub(crate) fn codegen_rvalue_operand(
                             bug!("unexpected non-pair operand");
                         }
                     }
-                    mir::CastKind::PointerCoercion(PointerCoercion::DynStar, _) => {
-                        let (lldata, llextra) = operand.val.pointer_parts();
-                        let (lldata, llextra) =
-                            base::cast_to_dyn_star(bx, lldata, operand.layout, cast.ty, llextra);
-                        OperandValue::Pair(lldata, llextra)
-                    }
                     | mir::CastKind::IntToInt
                     | mir::CastKind::FloatToInt
                     | mir::CastKind::FloatToFloat
diff --git a/compiler/rustc_const_eval/messages.ftl b/compiler/rustc_const_eval/messages.ftl
index 2a2c3e6..22a1894 100644
--- a/compiler/rustc_const_eval/messages.ftl
+++ b/compiler/rustc_const_eval/messages.ftl
@@ -263,9 +263,6 @@
 const_eval_not_enough_caller_args =
     calling a function with fewer arguments than it requires
 
-const_eval_nullary_intrinsic_fail =
-    could not evaluate nullary intrinsic
-
 const_eval_offset_from_different_allocations =
     `{$name}` called on two different pointers that are not both derived from the same allocation
 const_eval_offset_from_out_of_bounds =
diff --git a/compiler/rustc_const_eval/src/check_consts/check.rs b/compiler/rustc_const_eval/src/check_consts/check.rs
index c1d91f9..0eb6f28 100644
--- a/compiler/rustc_const_eval/src/check_consts/check.rs
+++ b/compiler/rustc_const_eval/src/check_consts/check.rs
@@ -638,14 +638,6 @@ fn visit_rvalue(&mut self, rvalue: &Rvalue<'tcx>, location: Location) {
                 // These are all okay; they only change the type, not the data.
             }
 
-            Rvalue::Cast(
-                CastKind::PointerCoercion(PointerCoercion::Unsize | PointerCoercion::DynStar, _),
-                _,
-                _,
-            ) => {
-                // Unsizing and `dyn*` coercions are implemented for CTFE.
-            }
-
             Rvalue::Cast(CastKind::PointerExposeProvenance, _, _) => {
                 self.check_op(ops::RawPtrToIntCast);
             }
diff --git a/compiler/rustc_const_eval/src/const_eval/eval_queries.rs b/compiler/rustc_const_eval/src/const_eval/eval_queries.rs
index 569a07c..08e1877 100644
--- a/compiler/rustc_const_eval/src/const_eval/eval_queries.rs
+++ b/compiler/rustc_const_eval/src/const_eval/eval_queries.rs
@@ -20,7 +20,7 @@
 use crate::interpret::{
     CtfeValidationMode, GlobalId, Immediate, InternKind, InternResult, InterpCx, InterpErrorKind,
     InterpResult, MPlaceTy, MemoryKind, OpTy, RefTracking, StackPopCleanup, create_static_alloc,
-    eval_nullary_intrinsic, intern_const_alloc_recursive, interp_ok, throw_exhaust,
+    intern_const_alloc_recursive, interp_ok, throw_exhaust,
 };
 use crate::{CTRL_C_RECEIVED, errors};
 
@@ -209,9 +209,9 @@ pub(super) fn op_to_const<'tcx>(
 
     match immediate {
         Left(ref mplace) => {
-            // We know `offset` is relative to the allocation, so we can use `into_parts`.
-            let (prov, offset) = mplace.ptr().into_parts();
-            let alloc_id = prov.expect("cannot have `fake` place for non-ZST type").alloc_id();
+            let (prov, offset) =
+                mplace.ptr().into_pointer_or_addr().unwrap().prov_and_relative_offset();
+            let alloc_id = prov.alloc_id();
             ConstValue::Indirect { alloc_id, offset }
         }
         // see comment on `let force_as_immediate` above
@@ -232,9 +232,10 @@ pub(super) fn op_to_const<'tcx>(
                     imm.layout.ty,
                 );
                 let msg = "`op_to_const` on an immediate scalar pair must only be used on slice references to the beginning of an actual allocation";
-                // We know `offset` is relative to the allocation, so we can use `into_parts`.
-                let (prov, offset) = a.to_pointer(ecx).expect(msg).into_parts();
-                let alloc_id = prov.expect(msg).alloc_id();
+                let ptr = a.to_pointer(ecx).expect(msg);
+                let (prov, offset) =
+                    ptr.into_pointer_or_addr().expect(msg).prov_and_relative_offset();
+                let alloc_id = prov.alloc_id();
                 let data = ecx.tcx.global_alloc(alloc_id).unwrap_memory();
                 assert!(offset == abi::Size::ZERO, "{}", msg);
                 let meta = b.to_target_usize(ecx).expect(msg);
@@ -280,34 +281,6 @@ pub fn eval_to_const_value_raw_provider<'tcx>(
     tcx: TyCtxt<'tcx>,
     key: ty::PseudoCanonicalInput<'tcx, GlobalId<'tcx>>,
 ) -> ::rustc_middle::mir::interpret::EvalToConstValueResult<'tcx> {
-    // We call `const_eval` for zero arg intrinsics, too, in order to cache their value.
-    // Catch such calls and evaluate them instead of trying to load a constant's MIR.
-    if let ty::InstanceKind::Intrinsic(def_id) = key.value.instance.def {
-        let ty = key.value.instance.ty(tcx, key.typing_env);
-        let ty::FnDef(_, args) = ty.kind() else {
-            bug!("intrinsic with type {:?}", ty);
-        };
-        return eval_nullary_intrinsic(tcx, key.typing_env, def_id, args).report_err().map_err(
-            |error| {
-                let span = tcx.def_span(def_id);
-
-                // FIXME(oli-obk): why don't we have any tests for this code path?
-                super::report(
-                    tcx,
-                    error.into_kind(),
-                    span,
-                    || (span, vec![]),
-                    |diag, span, _| {
-                        diag.span_label(
-                            span,
-                            crate::fluent_generated::const_eval_nullary_intrinsic_fail,
-                        );
-                    },
-                )
-            },
-        );
-    }
-
     tcx.eval_to_allocation_raw(key).map(|val| turn_into_const_value(tcx, val, key))
 }
 
diff --git a/compiler/rustc_const_eval/src/errors.rs b/compiler/rustc_const_eval/src/errors.rs
index 14abdd8..9133a5f 100644
--- a/compiler/rustc_const_eval/src/errors.rs
+++ b/compiler/rustc_const_eval/src/errors.rs
@@ -574,7 +574,7 @@ fn add_args<G: EmissionGuarantee>(self, diag: &mut Diag<'_, G>) {
                 if addr != 0 {
                     diag.arg(
                         "pointer",
-                        Pointer::<Option<CtfeProvenance>>::from_addr_invalid(addr).to_string(),
+                        Pointer::<Option<CtfeProvenance>>::without_provenance(addr).to_string(),
                     );
                 }
 
diff --git a/compiler/rustc_const_eval/src/interpret/call.rs b/compiler/rustc_const_eval/src/interpret/call.rs
index 79c14b2..ebaa5a9 100644
--- a/compiler/rustc_const_eval/src/interpret/call.rs
+++ b/compiler/rustc_const_eval/src/interpret/call.rs
@@ -643,13 +643,6 @@ pub(super) fn init_fn_call(
                             break self.ref_to_mplace(&val)?;
                         }
                         ty::Dynamic(.., ty::Dyn) => break receiver.assert_mem_place(), // no immediate unsized values
-                        ty::Dynamic(.., ty::DynStar) => {
-                            // Not clear how to handle this, so far we assume the receiver is always a pointer.
-                            span_bug!(
-                                self.cur_span(),
-                                "by-value calls on a `dyn*`... are those a thing?"
-                            );
-                        }
                         _ => {
                             // Not there yet, search for the only non-ZST field.
                             // (The rules for `DispatchFromDyn` ensure there's exactly one such field.)
@@ -662,39 +655,23 @@ pub(super) fn init_fn_call(
                 };
 
                 // Obtain the underlying trait we are working on, and the adjusted receiver argument.
-                let (trait_, dyn_ty, adjusted_recv) = if let ty::Dynamic(data, _, ty::DynStar) =
-                    receiver_place.layout.ty.kind()
-                {
-                    let recv = self.unpack_dyn_star(&receiver_place, data)?;
-
-                    (data.principal(), recv.layout.ty, recv.ptr())
-                } else {
-                    // Doesn't have to be a `dyn Trait`, but the unsized tail must be `dyn Trait`.
-                    // (For that reason we also cannot use `unpack_dyn_trait`.)
-                    let receiver_tail =
-                        self.tcx.struct_tail_for_codegen(receiver_place.layout.ty, self.typing_env);
-                    let ty::Dynamic(receiver_trait, _, ty::Dyn) = receiver_tail.kind() else {
-                        span_bug!(
-                            self.cur_span(),
-                            "dynamic call on non-`dyn` type {}",
-                            receiver_tail
-                        )
-                    };
-                    assert!(receiver_place.layout.is_unsized());
-
-                    // Get the required information from the vtable.
-                    let vptr = receiver_place.meta().unwrap_meta().to_pointer(self)?;
-                    let dyn_ty = self.get_ptr_vtable_ty(vptr, Some(receiver_trait))?;
-
-                    // It might be surprising that we use a pointer as the receiver even if this
-                    // is a by-val case; this works because by-val passing of an unsized `dyn
-                    // Trait` to a function is actually desugared to a pointer.
-                    (receiver_trait.principal(), dyn_ty, receiver_place.ptr())
+                // Doesn't have to be a `dyn Trait`, but the unsized tail must be `dyn Trait`.
+                // (For that reason we also cannot use `unpack_dyn_trait`.)
+                let receiver_tail =
+                    self.tcx.struct_tail_for_codegen(receiver_place.layout.ty, self.typing_env);
+                let ty::Dynamic(receiver_trait, _, ty::Dyn) = receiver_tail.kind() else {
+                    span_bug!(self.cur_span(), "dynamic call on non-`dyn` type {}", receiver_tail)
                 };
+                assert!(receiver_place.layout.is_unsized());
+
+                // Get the required information from the vtable.
+                let vptr = receiver_place.meta().unwrap_meta().to_pointer(self)?;
+                let dyn_ty = self.get_ptr_vtable_ty(vptr, Some(receiver_trait))?;
+                let adjusted_recv = receiver_place.ptr();
 
                 // Now determine the actual method to call. Usually we use the easy way of just
                 // looking up the method at index `idx`.
-                let vtable_entries = self.vtable_entries(trait_, dyn_ty);
+                let vtable_entries = self.vtable_entries(receiver_trait.principal(), dyn_ty);
                 let Some(ty::VtblEntry::Method(fn_inst)) = vtable_entries.get(idx).copied() else {
                     // FIXME(fee1-dead) these could be variants of the UB info enum instead of this
                     throw_ub_custom!(fluent::const_eval_dyn_call_not_a_method);
@@ -830,10 +807,6 @@ pub(super) fn init_drop_in_place_call(
                 // Dropping a trait object. Need to find actual drop fn.
                 self.unpack_dyn_trait(&place, data)?
             }
-            ty::Dynamic(data, _, ty::DynStar) => {
-                // Dropping a `dyn*`. Need to find actual drop fn.
-                self.unpack_dyn_star(&place, data)?
-            }
             _ => {
                 debug_assert_eq!(
                     instance,
diff --git a/compiler/rustc_const_eval/src/interpret/cast.rs b/compiler/rustc_const_eval/src/interpret/cast.rs
index 1036935..7a73d70 100644
--- a/compiler/rustc_const_eval/src/interpret/cast.rs
+++ b/compiler/rustc_const_eval/src/interpret/cast.rs
@@ -126,20 +126,6 @@ pub fn cast(
                 }
             }
 
-            CastKind::PointerCoercion(PointerCoercion::DynStar, _) => {
-                if let ty::Dynamic(data, _, ty::DynStar) = cast_ty.kind() {
-                    // Initial cast from sized to dyn trait
-                    let vtable = self.get_vtable_ptr(src.layout.ty, data)?;
-                    let vtable = Scalar::from_maybe_pointer(vtable, self);
-                    let data = self.read_immediate(src)?.to_scalar();
-                    let _assert_pointer_like = data.to_pointer(self)?;
-                    let val = Immediate::ScalarPair(data, vtable);
-                    self.write_immediate(val, dest)?;
-                } else {
-                    bug!()
-                }
-            }
-
             CastKind::Transmute => {
                 assert!(src.layout.is_sized());
                 assert!(dest.layout.is_sized());
diff --git a/compiler/rustc_const_eval/src/interpret/intrinsics.rs b/compiler/rustc_const_eval/src/interpret/intrinsics.rs
index b29c5c7..d7cede7 100644
--- a/compiler/rustc_const_eval/src/interpret/intrinsics.rs
+++ b/compiler/rustc_const_eval/src/interpret/intrinsics.rs
@@ -6,10 +6,9 @@
 
 use rustc_abi::Size;
 use rustc_apfloat::ieee::{Double, Half, Quad, Single};
-use rustc_hir::def_id::DefId;
 use rustc_middle::mir::{self, BinOp, ConstValue, NonDivergingIntrinsic};
 use rustc_middle::ty::layout::{TyAndLayout, ValidityRequirement};
-use rustc_middle::ty::{GenericArgsRef, Ty, TyCtxt};
+use rustc_middle::ty::{Ty, TyCtxt};
 use rustc_middle::{bug, ty};
 use rustc_span::{Symbol, sym};
 use tracing::trace;
@@ -17,8 +16,8 @@
 use super::memory::MemoryKind;
 use super::util::ensure_monomorphic_enough;
 use super::{
-    Allocation, CheckInAllocMsg, ConstAllocation, GlobalId, ImmTy, InterpCx, InterpResult, Machine,
-    OpTy, PlaceTy, Pointer, PointerArithmetic, Provenance, Scalar, err_inval, err_ub_custom,
+    Allocation, CheckInAllocMsg, ConstAllocation, ImmTy, InterpCx, InterpResult, Machine, OpTy,
+    PlaceTy, Pointer, PointerArithmetic, Provenance, Scalar, err_inval, err_ub_custom,
     err_unsup_format, interp_ok, throw_inval, throw_ub_custom, throw_ub_format,
 };
 use crate::fluent_generated as fluent;
@@ -30,73 +29,6 @@ pub(crate) fn alloc_type_name<'tcx>(tcx: TyCtxt<'tcx>, ty: Ty<'tcx>) -> ConstAll
     tcx.mk_const_alloc(alloc)
 }
 
-/// The logic for all nullary intrinsics is implemented here. These intrinsics don't get evaluated
-/// inside an `InterpCx` and instead have their value computed directly from rustc internal info.
-pub(crate) fn eval_nullary_intrinsic<'tcx>(
-    tcx: TyCtxt<'tcx>,
-    typing_env: ty::TypingEnv<'tcx>,
-    def_id: DefId,
-    args: GenericArgsRef<'tcx>,
-) -> InterpResult<'tcx, ConstValue<'tcx>> {
-    let tp_ty = args.type_at(0);
-    let name = tcx.item_name(def_id);
-    interp_ok(match name {
-        sym::type_name => {
-            ensure_monomorphic_enough(tcx, tp_ty)?;
-            let alloc = alloc_type_name(tcx, tp_ty);
-            ConstValue::Slice { data: alloc, meta: alloc.inner().size().bytes() }
-        }
-        sym::needs_drop => {
-            ensure_monomorphic_enough(tcx, tp_ty)?;
-            ConstValue::from_bool(tp_ty.needs_drop(tcx, typing_env))
-        }
-        sym::type_id => {
-            ensure_monomorphic_enough(tcx, tp_ty)?;
-            ConstValue::from_u128(tcx.type_id_hash(tp_ty).as_u128())
-        }
-        sym::variant_count => match match tp_ty.kind() {
-            // Pattern types have the same number of variants as their base type.
-            // Even if we restrict e.g. which variants are valid, the variants are essentially just uninhabited.
-            // And `Result<(), !>` still has two variants according to `variant_count`.
-            ty::Pat(base, _) => *base,
-            _ => tp_ty,
-        }
-        .kind()
-        {
-            // Correctly handles non-monomorphic calls, so there is no need for ensure_monomorphic_enough.
-            ty::Adt(adt, _) => ConstValue::from_target_usize(adt.variants().len() as u64, &tcx),
-            ty::Alias(..) | ty::Param(_) | ty::Placeholder(_) | ty::Infer(_) => {
-                throw_inval!(TooGeneric)
-            }
-            ty::Pat(..) => unreachable!(),
-            ty::Bound(_, _) => bug!("bound ty during ctfe"),
-            ty::Bool
-            | ty::Char
-            | ty::Int(_)
-            | ty::Uint(_)
-            | ty::Float(_)
-            | ty::Foreign(_)
-            | ty::Str
-            | ty::Array(_, _)
-            | ty::Slice(_)
-            | ty::RawPtr(_, _)
-            | ty::Ref(_, _, _)
-            | ty::FnDef(_, _)
-            | ty::FnPtr(..)
-            | ty::Dynamic(_, _, _)
-            | ty::Closure(_, _)
-            | ty::CoroutineClosure(_, _)
-            | ty::Coroutine(_, _)
-            | ty::CoroutineWitness(..)
-            | ty::UnsafeBinder(_)
-            | ty::Never
-            | ty::Tuple(_)
-            | ty::Error(_) => ConstValue::from_target_usize(0u64, &tcx),
-        },
-        other => bug!("`{}` is not a zero arg intrinsic", other),
-    })
-}
-
 impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
     /// Returns `true` if emulation happened.
     /// Here we implement the intrinsics that are common to all Miri instances; individual machines can add their own
@@ -110,8 +42,77 @@ pub fn eval_intrinsic(
     ) -> InterpResult<'tcx, bool> {
         let instance_args = instance.args;
         let intrinsic_name = self.tcx.item_name(instance.def_id());
+        let tcx = self.tcx.tcx;
 
         match intrinsic_name {
+            sym::type_name => {
+                let tp_ty = instance.args.type_at(0);
+                ensure_monomorphic_enough(tcx, tp_ty)?;
+                let alloc = alloc_type_name(tcx, tp_ty);
+                let val = ConstValue::Slice { data: alloc, meta: alloc.inner().size().bytes() };
+                let val = self.const_val_to_op(val, dest.layout.ty, Some(dest.layout))?;
+                self.copy_op(&val, dest)?;
+            }
+            sym::needs_drop => {
+                let tp_ty = instance.args.type_at(0);
+                ensure_monomorphic_enough(tcx, tp_ty)?;
+                let val = ConstValue::from_bool(tp_ty.needs_drop(tcx, self.typing_env));
+                let val = self.const_val_to_op(val, tcx.types.bool, Some(dest.layout))?;
+                self.copy_op(&val, dest)?;
+            }
+            sym::type_id => {
+                let tp_ty = instance.args.type_at(0);
+                ensure_monomorphic_enough(tcx, tp_ty)?;
+                let val = ConstValue::from_u128(tcx.type_id_hash(tp_ty).as_u128());
+                let val = self.const_val_to_op(val, dest.layout.ty, Some(dest.layout))?;
+                self.copy_op(&val, dest)?;
+            }
+            sym::variant_count => {
+                let tp_ty = instance.args.type_at(0);
+                let ty = match tp_ty.kind() {
+                    // Pattern types have the same number of variants as their base type.
+                    // Even if we restrict e.g. which variants are valid, the variants are essentially just uninhabited.
+                    // And `Result<(), !>` still has two variants according to `variant_count`.
+                    ty::Pat(base, _) => *base,
+                    _ => tp_ty,
+                };
+                let val = match ty.kind() {
+                    // Correctly handles non-monomorphic calls, so there is no need for ensure_monomorphic_enough.
+                    ty::Adt(adt, _) => {
+                        ConstValue::from_target_usize(adt.variants().len() as u64, &tcx)
+                    }
+                    ty::Alias(..) | ty::Param(_) | ty::Placeholder(_) | ty::Infer(_) => {
+                        throw_inval!(TooGeneric)
+                    }
+                    ty::Pat(..) => unreachable!(),
+                    ty::Bound(_, _) => bug!("bound ty during ctfe"),
+                    ty::Bool
+                    | ty::Char
+                    | ty::Int(_)
+                    | ty::Uint(_)
+                    | ty::Float(_)
+                    | ty::Foreign(_)
+                    | ty::Str
+                    | ty::Array(_, _)
+                    | ty::Slice(_)
+                    | ty::RawPtr(_, _)
+                    | ty::Ref(_, _, _)
+                    | ty::FnDef(_, _)
+                    | ty::FnPtr(..)
+                    | ty::Dynamic(_, _, _)
+                    | ty::Closure(_, _)
+                    | ty::CoroutineClosure(_, _)
+                    | ty::Coroutine(_, _)
+                    | ty::CoroutineWitness(..)
+                    | ty::UnsafeBinder(_)
+                    | ty::Never
+                    | ty::Tuple(_)
+                    | ty::Error(_) => ConstValue::from_target_usize(0u64, &tcx),
+                };
+                let val = self.const_val_to_op(val, dest.layout.ty, Some(dest.layout))?;
+                self.copy_op(&val, dest)?;
+            }
+
             sym::caller_location => {
                 let span = self.find_closest_untracked_caller_location();
                 let val = self.tcx.span_as_caller_location(span);
@@ -137,21 +138,6 @@ pub fn eval_intrinsic(
                 self.write_scalar(Scalar::from_target_usize(result, self), dest)?;
             }
 
-            sym::needs_drop | sym::type_id | sym::type_name | sym::variant_count => {
-                let gid = GlobalId { instance, promoted: None };
-                let ty = self
-                    .tcx
-                    .fn_sig(instance.def_id())
-                    .instantiate(self.tcx.tcx, instance.args)
-                    .output()
-                    .no_bound_vars()
-                    .unwrap();
-                let val = self
-                    .ctfe_query(|tcx| tcx.const_eval_global_id(self.typing_env, gid, tcx.span))?;
-                let val = self.const_val_to_op(val, ty, Some(dest.layout))?;
-                self.copy_op(&val, dest)?;
-            }
-
             sym::fadd_algebraic
             | sym::fsub_algebraic
             | sym::fmul_algebraic
diff --git a/compiler/rustc_const_eval/src/interpret/machine.rs b/compiler/rustc_const_eval/src/interpret/machine.rs
index d6d230f..35ec303 100644
--- a/compiler/rustc_const_eval/src/interpret/machine.rs
+++ b/compiler/rustc_const_eval/src/interpret/machine.rs
@@ -747,7 +747,7 @@ fn ptr_from_addr_cast(
         // Allow these casts, but make the pointer not dereferenceable.
         // (I.e., they behave like transmutation.)
         // This is correct because no pointers can ever be exposed in compile-time evaluation.
-        interp_ok(Pointer::from_addr_invalid(addr))
+        interp_ok(Pointer::without_provenance(addr))
     }
 
     #[inline(always)]
@@ -756,8 +756,7 @@ fn ptr_get_alloc(
         ptr: Pointer<CtfeProvenance>,
         _size: i64,
     ) -> Option<(AllocId, Size, Self::ProvenanceExtra)> {
-        // We know `offset` is relative to the allocation, so we can use `into_parts`.
-        let (prov, offset) = ptr.into_parts();
+        let (prov, offset) = ptr.prov_and_relative_offset();
         Some((prov.alloc_id(), offset, prov.immutable()))
     }
 
diff --git a/compiler/rustc_const_eval/src/interpret/memory.rs b/compiler/rustc_const_eval/src/interpret/memory.rs
index 69fceb0..3b36bb8 100644
--- a/compiler/rustc_const_eval/src/interpret/memory.rs
+++ b/compiler/rustc_const_eval/src/interpret/memory.rs
@@ -1596,7 +1596,8 @@ pub fn ptr_try_get_alloc_id(
                 Some((alloc_id, offset, extra)) => Ok((alloc_id, offset, extra)),
                 None => {
                     assert!(M::Provenance::OFFSET_IS_ADDR);
-                    let (_, addr) = ptr.into_parts();
+                    // Offset is absolute, as we just asserted.
+                    let (_, addr) = ptr.into_raw_parts();
                     Err(addr.bytes())
                 }
             },
diff --git a/compiler/rustc_const_eval/src/interpret/mod.rs b/compiler/rustc_const_eval/src/interpret/mod.rs
index f5792ab..f8b3c92 100644
--- a/compiler/rustc_const_eval/src/interpret/mod.rs
+++ b/compiler/rustc_const_eval/src/interpret/mod.rs
@@ -29,7 +29,6 @@
     HasStaticRootDefId, InternKind, InternResult, intern_const_alloc_for_constprop,
     intern_const_alloc_recursive,
 };
-pub(crate) use self::intrinsics::eval_nullary_intrinsic;
 pub use self::machine::{AllocMap, Machine, MayLeak, ReturnAction, compile_time_machine};
 pub use self::memory::{AllocInfo, AllocKind, AllocRef, AllocRefMut, FnVal, Memory, MemoryKind};
 use self::operand::Operand;
diff --git a/compiler/rustc_const_eval/src/interpret/place.rs b/compiler/rustc_const_eval/src/interpret/place.rs
index 3028568..a3cd35f 100644
--- a/compiler/rustc_const_eval/src/interpret/place.rs
+++ b/compiler/rustc_const_eval/src/interpret/place.rs
@@ -118,7 +118,7 @@ impl<'tcx, Prov: Provenance> MPlaceTy<'tcx, Prov> {
     pub fn fake_alloc_zst(layout: TyAndLayout<'tcx>) -> Self {
         assert!(layout.is_zst());
         let align = layout.align.abi;
-        let ptr = Pointer::from_addr_invalid(align.bytes()); // no provenance, absolute address
+        let ptr = Pointer::without_provenance(align.bytes()); // no provenance, absolute address
         MPlaceTy { mplace: MemPlace { ptr, meta: MemPlaceMeta::None, misaligned: None }, layout }
     }
 
diff --git a/compiler/rustc_const_eval/src/interpret/stack.rs b/compiler/rustc_const_eval/src/interpret/stack.rs
index 3361a58..543d68d 100644
--- a/compiler/rustc_const_eval/src/interpret/stack.rs
+++ b/compiler/rustc_const_eval/src/interpret/stack.rs
@@ -499,8 +499,7 @@ fn is_very_trivially_sized(ty: Ty<'_>) -> bool {
                 | ty::Closure(..)
                 | ty::CoroutineClosure(..)
                 | ty::Never
-                | ty::Error(_)
-                | ty::Dynamic(_, _, ty::DynStar) => true,
+                | ty::Error(_) => true,
 
                 ty::Str | ty::Slice(_) | ty::Dynamic(_, _, ty::Dyn) | ty::Foreign(..) => false,
 
diff --git a/compiler/rustc_const_eval/src/interpret/traits.rs b/compiler/rustc_const_eval/src/interpret/traits.rs
index 8b63495..e4b5c82 100644
--- a/compiler/rustc_const_eval/src/interpret/traits.rs
+++ b/compiler/rustc_const_eval/src/interpret/traits.rs
@@ -1,4 +1,4 @@
-use rustc_abi::{Align, FieldIdx, Size};
+use rustc_abi::{Align, Size};
 use rustc_middle::mir::interpret::{InterpResult, Pointer};
 use rustc_middle::ty::{self, ExistentialPredicateStableCmpExt, Ty, TyCtxt, VtblEntry};
 use tracing::trace;
@@ -125,24 +125,4 @@ pub(super) fn unpack_dyn_trait(
         )?;
         interp_ok(mplace)
     }
-
-    /// Turn a `dyn* Trait` type into an value with the actual dynamic type.
-    pub(super) fn unpack_dyn_star<P: Projectable<'tcx, M::Provenance>>(
-        &self,
-        val: &P,
-        expected_trait: &'tcx ty::List<ty::PolyExistentialPredicate<'tcx>>,
-    ) -> InterpResult<'tcx, P> {
-        assert!(
-            matches!(val.layout().ty.kind(), ty::Dynamic(_, _, ty::DynStar)),
-            "`unpack_dyn_star` only makes sense on `dyn*` types"
-        );
-        let data = self.project_field(val, FieldIdx::ZERO)?;
-        let vtable = self.project_field(val, FieldIdx::ONE)?;
-        let vtable = self.read_pointer(&vtable.to_op(self)?)?;
-        let ty = self.get_ptr_vtable_ty(vtable, Some(expected_trait))?;
-        // `data` is already the right thing but has the wrong type. So we transmute it.
-        let layout = self.layout_of(ty)?;
-        let data = data.transmute(layout, self)?;
-        interp_ok(data)
-    }
 }
diff --git a/compiler/rustc_const_eval/src/interpret/validity.rs b/compiler/rustc_const_eval/src/interpret/validity.rs
index 998ef37..e26cf0a 100644
--- a/compiler/rustc_const_eval/src/interpret/validity.rs
+++ b/compiler/rustc_const_eval/src/interpret/validity.rs
@@ -358,9 +358,6 @@ fn aggregate_field_path_elem(&mut self, layout: TyAndLayout<'tcx>, field: usize)
             // arrays/slices
             ty::Array(..) | ty::Slice(..) => PathElem::ArrayElem(field),
 
-            // dyn* vtables
-            ty::Dynamic(_, _, ty::DynKind::DynStar) if field == 1 => PathElem::Vtable,
-
             // dyn traits
             ty::Dynamic(..) => {
                 assert_eq!(field, 0);
@@ -518,7 +515,7 @@ fn check_safe_pointer(
             Ub(DanglingIntPointer { addr: i, .. }) => DanglingPtrNoProvenance {
                 ptr_kind,
                 // FIXME this says "null pointer" when null but we need translate
-                pointer: format!("{}", Pointer::<Option<AllocId>>::from_addr_invalid(i))
+                pointer: format!("{}", Pointer::<Option<AllocId>>::without_provenance(i))
             },
             Ub(PointerOutOfBounds { .. }) => DanglingPtrOutOfBounds {
                 ptr_kind
@@ -868,7 +865,9 @@ fn in_mutable_memory(&self, val: &PlaceTy<'tcx, M::Provenance>) -> bool {
     fn add_data_range(&mut self, ptr: Pointer<Option<M::Provenance>>, size: Size) {
         if let Some(data_bytes) = self.data_bytes.as_mut() {
             // We only have to store the offset, the rest is the same for all pointers here.
-            let (_prov, offset) = ptr.into_parts();
+            // The logic is agnostic to wether the offset is relative or absolute as long as
+            // it is consistent.
+            let (_prov, offset) = ptr.into_raw_parts();
             // Add this.
             data_bytes.add_range(offset, size);
         };
@@ -894,7 +893,7 @@ fn data_range_offset(ecx: &InterpCx<'tcx, M>, place: &PlaceTy<'tcx, M::Provenanc
             .as_mplace_or_imm()
             .expect_left("place must be in memory")
             .ptr();
-        let (_prov, offset) = ptr.into_parts();
+        let (_prov, offset) = ptr.into_raw_parts();
         offset
     }
 
@@ -903,7 +902,7 @@ fn reset_padding(&mut self, place: &PlaceTy<'tcx, M::Provenance>) -> InterpResul
         // Our value must be in memory, otherwise we would not have set up `data_bytes`.
         let mplace = self.ecx.force_allocation(place)?;
         // Determine starting offset and size.
-        let (_prov, start_offset) = mplace.ptr().into_parts();
+        let (_prov, start_offset) = mplace.ptr().into_raw_parts();
         let (size, _align) = self
             .ecx
             .size_and_align_of_val(&mplace)?
diff --git a/compiler/rustc_const_eval/src/interpret/visitor.rs b/compiler/rustc_const_eval/src/interpret/visitor.rs
index d5970b6..a27b664 100644
--- a/compiler/rustc_const_eval/src/interpret/visitor.rs
+++ b/compiler/rustc_const_eval/src/interpret/visitor.rs
@@ -101,26 +101,6 @@ fn walk_value(&mut self, v: &Self::V) -> InterpResult<'tcx> {
                 // recurse with the inner type
                 return self.visit_field(v, 0, &inner_mplace.into());
             }
-            ty::Dynamic(data, _, ty::DynStar) => {
-                // DynStar types. Very different from a dyn type (but strangely part of the
-                // same variant in `TyKind`): These are pairs where the 2nd component is the
-                // vtable, and the first component is the data (which must be ptr-sized).
-
-                // First make sure the vtable can be read at its type.
-                // The type of this vtable is fake, it claims to be a reference to some actual memory but that isn't true.
-                // So we transmute it to a raw pointer.
-                let raw_ptr_ty = Ty::new_mut_ptr(*self.ecx().tcx, self.ecx().tcx.types.unit);
-                let raw_ptr_ty = self.ecx().layout_of(raw_ptr_ty)?;
-                let vtable_field = self
-                    .ecx()
-                    .project_field(v, FieldIdx::ONE)?
-                    .transmute(raw_ptr_ty, self.ecx())?;
-                self.visit_field(v, 1, &vtable_field)?;
-
-                // Then unpack the first field, and continue.
-                let data = self.ecx().unpack_dyn_star(v, data)?;
-                return self.visit_field(v, 0, &data);
-            }
             // Slices do not need special handling here: they have `Array` field
             // placement with length 0, so we enter the `Array` case below which
             // indirectly uses the metadata to determine the actual length.
diff --git a/compiler/rustc_data_structures/src/aligned.rs b/compiler/rustc_data_structures/src/aligned.rs
index 111740e..bfc7556 100644
--- a/compiler/rustc_data_structures/src/aligned.rs
+++ b/compiler/rustc_data_structures/src/aligned.rs
@@ -1,7 +1,6 @@
+use std::marker::PointeeSized;
 use std::ptr::Alignment;
 
-use rustc_serialize::PointeeSized;
-
 /// Returns the ABI-required minimum alignment of a type in bytes.
 ///
 /// This is equivalent to [`align_of`], but also works for some unsized
diff --git a/compiler/rustc_data_structures/src/flock.rs b/compiler/rustc_data_structures/src/flock.rs
index 60ae7ad..f33f6b7 100644
--- a/compiler/rustc_data_structures/src/flock.rs
+++ b/compiler/rustc_data_structures/src/flock.rs
@@ -4,18 +4,7 @@
 //! green/native threading. This is just a bare-bones enough solution for
 //! librustdoc, it is not production quality at all.
 
-// cfg(bootstrap)
-macro_rules! cfg_select_dispatch {
-    ($($tokens:tt)*) => {
-        #[cfg(bootstrap)]
-        cfg_match! { $($tokens)* }
-
-        #[cfg(not(bootstrap))]
-        cfg_select! { $($tokens)* }
-    };
-}
-
-cfg_select_dispatch! {
+cfg_select! {
     target_os = "linux" => {
         mod linux;
         use linux as imp;
diff --git a/compiler/rustc_data_structures/src/lib.rs b/compiler/rustc_data_structures/src/lib.rs
index 0431182..53178d0 100644
--- a/compiler/rustc_data_structures/src/lib.rs
+++ b/compiler/rustc_data_structures/src/lib.rs
@@ -10,9 +10,6 @@
 #![allow(internal_features)]
 #![allow(rustc::default_hash_types)]
 #![allow(rustc::potential_query_instability)]
-#![cfg_attr(bootstrap, feature(cfg_match))]
-#![cfg_attr(not(bootstrap), feature(cfg_select))]
-#![cfg_attr(not(bootstrap), feature(sized_hierarchy))]
 #![deny(unsafe_op_in_unsafe_fn)]
 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
 #![doc(rust_logo)]
@@ -22,6 +19,7 @@
 #![feature(ascii_char_variants)]
 #![feature(assert_matches)]
 #![feature(auto_traits)]
+#![feature(cfg_select)]
 #![feature(core_intrinsics)]
 #![feature(dropck_eyepatch)]
 #![feature(extend_one)]
@@ -33,6 +31,7 @@
 #![feature(ptr_alignment_type)]
 #![feature(rustc_attrs)]
 #![feature(rustdoc_internals)]
+#![feature(sized_hierarchy)]
 #![feature(test)]
 #![feature(thread_id_value)]
 #![feature(type_alias_impl_trait)]
@@ -44,9 +43,6 @@
 pub use atomic_ref::AtomicRef;
 pub use ena::{snapshot_vec, undo_log, unify};
 pub use rustc_index::static_assert_size;
-// re-exported for `rustc_smir`
-// FIXME(sized_hierarchy): remove with `cfg(bootstrap)`, see `rustc_serialize/src/lib.rs`
-pub use rustc_serialize::PointeeSized;
 
 pub mod aligned;
 pub mod base_n;
diff --git a/compiler/rustc_data_structures/src/marker.rs b/compiler/rustc_data_structures/src/marker.rs
index 4846bc9..2be9ba2 100644
--- a/compiler/rustc_data_structures/src/marker.rs
+++ b/compiler/rustc_data_structures/src/marker.rs
@@ -1,6 +1,5 @@
 use std::alloc::Allocator;
-
-use rustc_serialize::PointeeSized;
+use std::marker::PointeeSized;
 
 #[diagnostic::on_unimplemented(message = "`{Self}` doesn't implement `DynSend`. \
             Add it to `rustc_data_structures::marker` or use `IntoDynSyncSend` if it's already `Send`")]
diff --git a/compiler/rustc_data_structures/src/profiling.rs b/compiler/rustc_data_structures/src/profiling.rs
index e3a01e4..1b4db7ad 100644
--- a/compiler/rustc_data_structures/src/profiling.rs
+++ b/compiler/rustc_data_structures/src/profiling.rs
@@ -88,6 +88,7 @@
 use std::intrinsics::unlikely;
 use std::path::Path;
 use std::sync::Arc;
+use std::sync::atomic::Ordering;
 use std::time::{Duration, Instant};
 use std::{fs, process};
 
@@ -99,12 +100,15 @@
 
 use crate::fx::FxHashMap;
 use crate::outline;
+use crate::sync::AtomicU64;
 
 bitflags::bitflags! {
     #[derive(Clone, Copy)]
     struct EventFilter: u16 {
         const GENERIC_ACTIVITIES  = 1 << 0;
         const QUERY_PROVIDERS     = 1 << 1;
+        /// Store detailed instant events, including timestamp and thread ID,
+        /// per each query cache hit. Note that this is quite expensive.
         const QUERY_CACHE_HITS    = 1 << 2;
         const QUERY_BLOCKED       = 1 << 3;
         const INCR_CACHE_LOADS    = 1 << 4;
@@ -113,16 +117,20 @@ struct EventFilter: u16 {
         const FUNCTION_ARGS       = 1 << 6;
         const LLVM                = 1 << 7;
         const INCR_RESULT_HASHING = 1 << 8;
-        const ARTIFACT_SIZES = 1 << 9;
+        const ARTIFACT_SIZES      = 1 << 9;
+        /// Store aggregated counts of cache hits per query invocation.
+        const QUERY_CACHE_HIT_COUNTS  = 1 << 10;
 
         const DEFAULT = Self::GENERIC_ACTIVITIES.bits() |
                         Self::QUERY_PROVIDERS.bits() |
                         Self::QUERY_BLOCKED.bits() |
                         Self::INCR_CACHE_LOADS.bits() |
                         Self::INCR_RESULT_HASHING.bits() |
-                        Self::ARTIFACT_SIZES.bits();
+                        Self::ARTIFACT_SIZES.bits() |
+                        Self::QUERY_CACHE_HIT_COUNTS.bits();
 
         const ARGS = Self::QUERY_KEYS.bits() | Self::FUNCTION_ARGS.bits();
+        const QUERY_CACHE_HIT_COMBINED = Self::QUERY_CACHE_HITS.bits() | Self::QUERY_CACHE_HIT_COUNTS.bits();
     }
 }
 
@@ -134,6 +142,7 @@ struct EventFilter: u16 {
     ("generic-activity", EventFilter::GENERIC_ACTIVITIES),
     ("query-provider", EventFilter::QUERY_PROVIDERS),
     ("query-cache-hit", EventFilter::QUERY_CACHE_HITS),
+    ("query-cache-hit-count", EventFilter::QUERY_CACHE_HITS),
     ("query-blocked", EventFilter::QUERY_BLOCKED),
     ("incr-cache-load", EventFilter::INCR_CACHE_LOADS),
     ("query-keys", EventFilter::QUERY_KEYS),
@@ -411,13 +420,24 @@ pub fn query_cache_hit(&self, query_invocation_id: QueryInvocationId) {
         #[inline(never)]
         #[cold]
         fn cold_call(profiler_ref: &SelfProfilerRef, query_invocation_id: QueryInvocationId) {
-            profiler_ref.instant_query_event(
-                |profiler| profiler.query_cache_hit_event_kind,
-                query_invocation_id,
-            );
+            if profiler_ref.event_filter_mask.contains(EventFilter::QUERY_CACHE_HIT_COUNTS) {
+                profiler_ref
+                    .profiler
+                    .as_ref()
+                    .unwrap()
+                    .increment_query_cache_hit_counters(QueryInvocationId(query_invocation_id.0));
+            }
+            if unlikely(profiler_ref.event_filter_mask.contains(EventFilter::QUERY_CACHE_HITS)) {
+                profiler_ref.instant_query_event(
+                    |profiler| profiler.query_cache_hit_event_kind,
+                    query_invocation_id,
+                );
+            }
         }
 
-        if unlikely(self.event_filter_mask.contains(EventFilter::QUERY_CACHE_HITS)) {
+        // We check both kinds of query cache hit events at once, to reduce overhead in the
+        // common case (with self-profile disabled).
+        if unlikely(self.event_filter_mask.intersects(EventFilter::QUERY_CACHE_HIT_COMBINED)) {
             cold_call(self, query_invocation_id);
         }
     }
@@ -489,6 +509,35 @@ pub fn get_or_alloc_cached_string(&self, s: &str) -> Option<StringId> {
         self.profiler.as_ref().map(|p| p.get_or_alloc_cached_string(s))
     }
 
+    /// Store query cache hits to the self-profile log.
+    /// Should be called once at the end of the compilation session.
+    ///
+    /// The cache hits are stored per **query invocation**, not **per query kind/type**.
+    /// `analyzeme` can later deduplicate individual query labels from the QueryInvocationId event
+    /// IDs.
+    pub fn store_query_cache_hits(&self) {
+        if self.event_filter_mask.contains(EventFilter::QUERY_CACHE_HIT_COUNTS) {
+            let profiler = self.profiler.as_ref().unwrap();
+            let query_hits = profiler.query_hits.read();
+            let builder = EventIdBuilder::new(&profiler.profiler);
+            let thread_id = get_thread_id();
+            for (query_invocation, hit_count) in query_hits.iter().enumerate() {
+                let hit_count = hit_count.load(Ordering::Relaxed);
+                // No need to record empty cache hit counts
+                if hit_count > 0 {
+                    let event_id =
+                        builder.from_label(StringId::new_virtual(query_invocation as u64));
+                    profiler.profiler.record_integer_event(
+                        profiler.query_cache_hit_count_event_kind,
+                        event_id,
+                        thread_id,
+                        hit_count,
+                    );
+                }
+            }
+        }
+    }
+
     #[inline]
     pub fn enabled(&self) -> bool {
         self.profiler.is_some()
@@ -537,6 +586,19 @@ pub struct SelfProfiler {
 
     string_cache: RwLock<FxHashMap<String, StringId>>,
 
+    /// Recording individual query cache hits as "instant" measureme events
+    /// is incredibly expensive. Instead of doing that, we simply aggregate
+    /// cache hit *counts* per query invocation, and then store the final count
+    /// of cache hits per invocation at the end of the compilation session.
+    ///
+    /// With this approach, we don't know the individual thread IDs and timestamps
+    /// of cache hits, but it has very little overhead on top of `-Zself-profile`.
+    /// Recording the cache hits as individual events made compilation 3-5x slower.
+    ///
+    /// Query invocation IDs should be monotonic integers, so we can store them in a vec,
+    /// rather than using a hashmap.
+    query_hits: RwLock<Vec<AtomicU64>>,
+
     query_event_kind: StringId,
     generic_activity_event_kind: StringId,
     incremental_load_result_event_kind: StringId,
@@ -544,6 +606,8 @@ pub struct SelfProfiler {
     query_blocked_event_kind: StringId,
     query_cache_hit_event_kind: StringId,
     artifact_size_event_kind: StringId,
+    /// Total cache hits per query invocation
+    query_cache_hit_count_event_kind: StringId,
 }
 
 impl SelfProfiler {
@@ -573,6 +637,7 @@ pub fn new(
         let query_blocked_event_kind = profiler.alloc_string("QueryBlocked");
         let query_cache_hit_event_kind = profiler.alloc_string("QueryCacheHit");
         let artifact_size_event_kind = profiler.alloc_string("ArtifactSize");
+        let query_cache_hit_count_event_kind = profiler.alloc_string("QueryCacheHitCount");
 
         let mut event_filter_mask = EventFilter::empty();
 
@@ -618,6 +683,8 @@ pub fn new(
             query_blocked_event_kind,
             query_cache_hit_event_kind,
             artifact_size_event_kind,
+            query_cache_hit_count_event_kind,
+            query_hits: Default::default(),
         })
     }
 
@@ -627,6 +694,25 @@ pub fn alloc_string<STR: SerializableString + ?Sized>(&self, s: &STR) -> StringI
         self.profiler.alloc_string(s)
     }
 
+    /// Store a cache hit of a query invocation
+    pub fn increment_query_cache_hit_counters(&self, id: QueryInvocationId) {
+        // Fast path: assume that the query was already encountered before, and just record
+        // a cache hit.
+        let mut guard = self.query_hits.upgradable_read();
+        let query_hits = &guard;
+        let index = id.0 as usize;
+        if index < query_hits.len() {
+            // We only want to increment the count, no other synchronization is required
+            query_hits[index].fetch_add(1, Ordering::Relaxed);
+        } else {
+            // If not, we need to extend the query hit map to the highest observed ID
+            guard.with_upgraded(|vec| {
+                vec.resize_with(index + 1, || AtomicU64::new(0));
+                vec[index] = AtomicU64::from(1);
+            });
+        }
+    }
+
     /// Gets a `StringId` for the given string. This method makes sure that
     /// any strings going through it will only be allocated once in the
     /// profiling data.
@@ -859,19 +945,8 @@ fn get_thread_id() -> u32 {
     std::thread::current().id().as_u64().get() as u32
 }
 
-// cfg(bootstrap)
-macro_rules! cfg_select_dispatch {
-    ($($tokens:tt)*) => {
-        #[cfg(bootstrap)]
-        cfg_match! { $($tokens)* }
-
-        #[cfg(not(bootstrap))]
-        cfg_select! { $($tokens)* }
-    };
-}
-
 // Memory reporting
-cfg_select_dispatch! {
+cfg_select! {
     windows => {
         pub fn get_resident_set_size() -> Option<usize> {
             use windows::{
diff --git a/compiler/rustc_driver_impl/src/lib.rs b/compiler/rustc_driver_impl/src/lib.rs
index 4855fc5..1849038 100644
--- a/compiler/rustc_driver_impl/src/lib.rs
+++ b/compiler/rustc_driver_impl/src/lib.rs
@@ -1112,7 +1112,9 @@ fn get_backend_from_raw_matches(
     matches: &Matches,
 ) -> Box<dyn CodegenBackend> {
     let debug_flags = matches.opt_strs("Z");
-    let backend_name = debug_flags.iter().find_map(|x| x.strip_prefix("codegen-backend="));
+    let backend_name = debug_flags
+        .iter()
+        .find_map(|x| x.strip_prefix("codegen-backend=").or(x.strip_prefix("codegen_backend=")));
     let target = parse_target_triple(early_dcx, matches);
     let sysroot = Sysroot::new(matches.opt_str("sysroot").map(PathBuf::from));
     let target = config::build_target_config(early_dcx, &target, sysroot.path());
diff --git a/compiler/rustc_errors/src/diagnostic.rs b/compiler/rustc_errors/src/diagnostic.rs
index 8da7cdd..fe97970 100644
--- a/compiler/rustc_errors/src/diagnostic.rs
+++ b/compiler/rustc_errors/src/diagnostic.rs
@@ -1005,7 +1005,7 @@ pub fn tool_only_multipart_suggestion(
     /// * may look like "to do xyz, use" or "to do xyz, use abc"
     /// * may contain a name of a function, variable, or type, but not whole expressions
     ///
-    /// See `CodeSuggestion` for more information.
+    /// See [`CodeSuggestion`] for more information.
     #[rustc_lint_diagnostics]
     pub fn span_suggestion(
         &mut self,
@@ -1166,7 +1166,7 @@ pub fn multipart_suggestions(
     /// Prints out a message with a suggested edit of the code. If the suggestion is presented
     /// inline, it will only show the message and not the suggestion.
     ///
-    /// See `CodeSuggestion` for more information.
+    /// See [`CodeSuggestion`] for more information.
     #[rustc_lint_diagnostics]
     pub fn span_suggestion_short(
         &mut self,
diff --git a/compiler/rustc_errors/src/emitter.rs b/compiler/rustc_errors/src/emitter.rs
index e333de4..3f5872f 100644
--- a/compiler/rustc_errors/src/emitter.rs
+++ b/compiler/rustc_errors/src/emitter.rs
@@ -2078,7 +2078,9 @@ fn emit_suggestion_default(
                 // file name, saving in verbosity, but if it *isn't* we do need it, otherwise we're
                 // telling users to make a change but not clarifying *where*.
                 let loc = sm.lookup_char_pos(parts[0].span.lo());
-                if loc.file.name != sm.span_to_filename(span) && loc.file.name.is_real() {
+                if (span.is_dummy() || loc.file.name != sm.span_to_filename(span))
+                    && loc.file.name.is_real()
+                {
                     // --> file.rs:line:col
                     //  |
                     let arrow = self.file_start();
diff --git a/compiler/rustc_errors/src/lib.rs b/compiler/rustc_errors/src/lib.rs
index 207aed8..69ad15c 100644
--- a/compiler/rustc_errors/src/lib.rs
+++ b/compiler/rustc_errors/src/lib.rs
@@ -6,8 +6,8 @@
 #![allow(incomplete_features)]
 #![allow(internal_features)]
 #![allow(rustc::diagnostic_outside_of_impl)]
+#![allow(rustc::direct_use_of_rustc_type_ir)]
 #![allow(rustc::untranslatable_diagnostic)]
-#![cfg_attr(not(bootstrap), allow(rustc::direct_use_of_rustc_type_ir))]
 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
 #![doc(rust_logo)]
 #![feature(array_windows)]
diff --git a/compiler/rustc_expand/messages.ftl b/compiler/rustc_expand/messages.ftl
index b7555bb..3fc0fa0 100644
--- a/compiler/rustc_expand/messages.ftl
+++ b/compiler/rustc_expand/messages.ftl
@@ -109,9 +109,6 @@
 
 expand_meta_var_dif_seq_matchers = {$msg}
 
-expand_meta_var_expr_unrecognized_var =
-    variable `{$key}` is not recognized in meta-variable expression
-
 expand_missing_fragment_specifier = missing fragment specifier
     .note = fragment specifiers must be provided
     .suggestion_add_fragspec = try adding a specifier here
@@ -136,6 +133,9 @@
 expand_must_repeat_once =
     this must repeat at least once
 
+expand_mve_unrecognized_var =
+    variable `{$key}` is not recognized in meta-variable expression
+
 expand_non_inline_modules_in_proc_macro_input_are_unstable =
     non-inline modules in proc macro input are unstable
 
diff --git a/compiler/rustc_expand/src/errors.rs b/compiler/rustc_expand/src/errors.rs
index fe4d2af..fdbc65a 100644
--- a/compiler/rustc_expand/src/errors.rs
+++ b/compiler/rustc_expand/src/errors.rs
@@ -28,14 +28,6 @@ pub(crate) struct CountRepetitionMisplaced {
 }
 
 #[derive(Diagnostic)]
-#[diag(expand_meta_var_expr_unrecognized_var)]
-pub(crate) struct MetaVarExprUnrecognizedVar {
-    #[primary_span]
-    pub span: Span,
-    pub key: MacroRulesNormalizedIdent,
-}
-
-#[derive(Diagnostic)]
 #[diag(expand_var_still_repeating)]
 pub(crate) struct VarStillRepeating {
     #[primary_span]
@@ -499,3 +491,16 @@ pub(crate) struct ProcMacroBackCompat {
     pub crate_name: String,
     pub fixed_version: String,
 }
+
+pub(crate) use metavar_exprs::*;
+mod metavar_exprs {
+    use super::*;
+
+    #[derive(Diagnostic)]
+    #[diag(expand_mve_unrecognized_var)]
+    pub(crate) struct MveUnrecognizedVar {
+        #[primary_span]
+        pub span: Span,
+        pub key: MacroRulesNormalizedIdent,
+    }
+}
diff --git a/compiler/rustc_expand/src/mbe/metavar_expr.rs b/compiler/rustc_expand/src/mbe/metavar_expr.rs
index 1ccb070..ffd3548 100644
--- a/compiler/rustc_expand/src/mbe/metavar_expr.rs
+++ b/compiler/rustc_expand/src/mbe/metavar_expr.rs
@@ -47,46 +47,7 @@ pub(crate) fn parse<'psess>(
         check_trailing_token(&mut iter, psess)?;
         let mut iter = args.iter();
         let rslt = match ident.as_str() {
-            "concat" => {
-                let mut result = Vec::new();
-                loop {
-                    let is_var = try_eat_dollar(&mut iter);
-                    let token = parse_token(&mut iter, psess, outer_span)?;
-                    let element = if is_var {
-                        MetaVarExprConcatElem::Var(parse_ident_from_token(psess, token)?)
-                    } else if let TokenKind::Literal(Lit {
-                        kind: token::LitKind::Str,
-                        symbol,
-                        suffix: None,
-                    }) = token.kind
-                    {
-                        MetaVarExprConcatElem::Literal(symbol)
-                    } else {
-                        match parse_ident_from_token(psess, token) {
-                            Err(err) => {
-                                err.cancel();
-                                return Err(psess
-                                    .dcx()
-                                    .struct_span_err(token.span, UNSUPPORTED_CONCAT_ELEM_ERR));
-                            }
-                            Ok(elem) => MetaVarExprConcatElem::Ident(elem),
-                        }
-                    };
-                    result.push(element);
-                    if iter.peek().is_none() {
-                        break;
-                    }
-                    if !try_eat_comma(&mut iter) {
-                        return Err(psess.dcx().struct_span_err(outer_span, "expected comma"));
-                    }
-                }
-                if result.len() < 2 {
-                    return Err(psess
-                        .dcx()
-                        .struct_span_err(ident.span, "`concat` must have at least two elements"));
-                }
-                MetaVarExpr::Concat(result.into())
-            }
+            "concat" => parse_concat(&mut iter, psess, outer_span, ident.span)?,
             "count" => parse_count(&mut iter, psess, ident.span)?,
             "ignore" => {
                 eat_dollar(&mut iter, psess, ident.span)?;
@@ -126,20 +87,6 @@ pub(crate) fn for_each_metavar<A>(&self, mut aux: A, mut cb: impl FnMut(A, &Iden
     }
 }
 
-/// Indicates what is placed in a `concat` parameter. For example, literals
-/// (`${concat("foo", "bar")}`) or adhoc identifiers (`${concat(foo, bar)}`).
-#[derive(Debug, Decodable, Encodable, PartialEq)]
-pub(crate) enum MetaVarExprConcatElem {
-    /// Identifier WITHOUT a preceding dollar sign, which means that this identifier should be
-    /// interpreted as a literal.
-    Ident(Ident),
-    /// For example, a number or a string.
-    Literal(Symbol),
-    /// Identifier WITH a preceding dollar sign, which means that this identifier should be
-    /// expanded and interpreted as a variable.
-    Var(Ident),
-}
-
 // Checks if there are any remaining tokens. For example, `${ignore(ident ... a b c ...)}`
 fn check_trailing_token<'psess>(
     iter: &mut TokenStreamIter<'_>,
@@ -156,6 +103,64 @@ fn check_trailing_token<'psess>(
     }
 }
 
+/// Indicates what is placed in a `concat` parameter. For example, literals
+/// (`${concat("foo", "bar")}`) or adhoc identifiers (`${concat(foo, bar)}`).
+#[derive(Debug, Decodable, Encodable, PartialEq)]
+pub(crate) enum MetaVarExprConcatElem {
+    /// Identifier WITHOUT a preceding dollar sign, which means that this identifier should be
+    /// interpreted as a literal.
+    Ident(Ident),
+    /// For example, a number or a string.
+    Literal(Symbol),
+    /// Identifier WITH a preceding dollar sign, which means that this identifier should be
+    /// expanded and interpreted as a variable.
+    Var(Ident),
+}
+
+/// Parse a meta-variable `concat` expression: `concat($metavar, ident, ...)`.
+fn parse_concat<'psess>(
+    iter: &mut TokenStreamIter<'_>,
+    psess: &'psess ParseSess,
+    outer_span: Span,
+    expr_ident_span: Span,
+) -> PResult<'psess, MetaVarExpr> {
+    let mut result = Vec::new();
+    loop {
+        let is_var = try_eat_dollar(iter);
+        let token = parse_token(iter, psess, outer_span)?;
+        let element = if is_var {
+            MetaVarExprConcatElem::Var(parse_ident_from_token(psess, token)?)
+        } else if let TokenKind::Literal(Lit { kind: token::LitKind::Str, symbol, suffix: None }) =
+            token.kind
+        {
+            MetaVarExprConcatElem::Literal(symbol)
+        } else {
+            match parse_ident_from_token(psess, token) {
+                Err(err) => {
+                    err.cancel();
+                    return Err(psess
+                        .dcx()
+                        .struct_span_err(token.span, UNSUPPORTED_CONCAT_ELEM_ERR));
+                }
+                Ok(elem) => MetaVarExprConcatElem::Ident(elem),
+            }
+        };
+        result.push(element);
+        if iter.peek().is_none() {
+            break;
+        }
+        if !try_eat_comma(iter) {
+            return Err(psess.dcx().struct_span_err(outer_span, "expected comma"));
+        }
+    }
+    if result.len() < 2 {
+        return Err(psess
+            .dcx()
+            .struct_span_err(expr_ident_span, "`concat` must have at least two elements"));
+    }
+    Ok(MetaVarExpr::Concat(result.into()))
+}
+
 /// Parse a meta-variable `count` expression: `count(ident[, depth])`
 fn parse_count<'psess>(
     iter: &mut TokenStreamIter<'_>,
diff --git a/compiler/rustc_expand/src/mbe/transcribe.rs b/compiler/rustc_expand/src/mbe/transcribe.rs
index a8c4a9e..174844d 100644
--- a/compiler/rustc_expand/src/mbe/transcribe.rs
+++ b/compiler/rustc_expand/src/mbe/transcribe.rs
@@ -17,7 +17,7 @@
 use smallvec::{SmallVec, smallvec};
 
 use crate::errors::{
-    CountRepetitionMisplaced, MetaVarExprUnrecognizedVar, MetaVarsDifSeqMatchers, MustRepeatOnce,
+    CountRepetitionMisplaced, MetaVarsDifSeqMatchers, MustRepeatOnce, MveUnrecognizedVar,
     NoSyntaxVarsExprRepeat, VarStillRepeating,
 };
 use crate::mbe::macro_parser::NamedMatch;
@@ -879,7 +879,7 @@ fn matched_from_ident<'ctx, 'interp, 'rslt>(
 {
     let span = ident.span;
     let key = MacroRulesNormalizedIdent::new(ident);
-    interp.get(&key).ok_or_else(|| dcx.create_err(MetaVarExprUnrecognizedVar { span, key }))
+    interp.get(&key).ok_or_else(|| dcx.create_err(MveUnrecognizedVar { span, key }))
 }
 
 /// Used by meta-variable expressions when an user input is out of the actual declared bounds. For
diff --git a/compiler/rustc_expand/src/proc_macro_server.rs b/compiler/rustc_expand/src/proc_macro_server.rs
index fb5abaef..af91c8b 100644
--- a/compiler/rustc_expand/src/proc_macro_server.rs
+++ b/compiler/rustc_expand/src/proc_macro_server.rs
@@ -599,8 +599,12 @@ fn expand_expr(&mut self, stream: &Self::TokenStream) -> Result<Self::TokenStrea
             ast::ExprKind::Lit(token_lit) => {
                 Ok(tokenstream::TokenStream::token_alone(token::Literal(*token_lit), expr.span))
             }
-            ast::ExprKind::IncludedBytes(bytes) => {
-                let lit = token::Lit::new(token::ByteStr, escape_byte_str_symbol(bytes), None);
+            ast::ExprKind::IncludedBytes(byte_sym) => {
+                let lit = token::Lit::new(
+                    token::ByteStr,
+                    escape_byte_str_symbol(byte_sym.as_byte_str()),
+                    None,
+                );
                 Ok(tokenstream::TokenStream::token_alone(token::TokenKind::Literal(lit), expr.span))
             }
             ast::ExprKind::Unary(ast::UnOp::Neg, e) => match &e.kind {
diff --git a/compiler/rustc_feature/src/accepted.rs b/compiler/rustc_feature/src/accepted.rs
index bc23334..83be324 100644
--- a/compiler/rustc_feature/src/accepted.rs
+++ b/compiler/rustc_feature/src/accepted.rs
@@ -83,7 +83,7 @@ macro_rules! declare_features {
     /// Allows overloading augmented assignment operations like `a += b`.
     (accepted, augmented_assignments, "1.8.0", Some(28235)),
     /// Allows using `avx512*` target features.
-    (accepted, avx512_target_feature, "CURRENT_RUSTC_VERSION", Some(44839)),
+    (accepted, avx512_target_feature, "1.89.0", Some(44839)),
     /// Allows mixing bind-by-move in patterns and references to those identifiers in guards.
     (accepted, bind_by_move_pattern_guards, "1.39.0", Some(15287)),
     /// Allows bindings in the subpattern of a binding pattern.
@@ -221,7 +221,7 @@ macro_rules! declare_features {
     /// Allows capturing variables in scope using format_args!
     (accepted, format_args_capture, "1.58.0", Some(67984)),
     /// Infer generic args for both consts and types.
-    (accepted, generic_arg_infer, "CURRENT_RUSTC_VERSION", Some(85077)),
+    (accepted, generic_arg_infer, "1.89.0", Some(85077)),
     /// Allows associated types to be generic, e.g., `type Foo<T>;` (RFC 1598).
     (accepted, generic_associated_types, "1.65.0", Some(44265)),
     /// Allows attributes on lifetime/type formal parameters in generics (RFC 1327).
@@ -262,7 +262,7 @@ macro_rules! declare_features {
     /// especially around globs and shadowing (RFC 1560).
     (accepted, item_like_imports, "1.15.0", Some(35120)),
     // Allows using the `kl` and `widekl` target features and the associated intrinsics
-    (accepted, keylocker_x86, "CURRENT_RUSTC_VERSION", Some(134813)),
+    (accepted, keylocker_x86, "1.89.0", Some(134813)),
     /// Allows `'a: { break 'a; }`.
     (accepted, label_break_value, "1.65.0", Some(48594)),
     /// Allows `if/while p && let q = r && ...` chains.
@@ -367,7 +367,7 @@ macro_rules! declare_features {
     /// Lessens the requirements for structs to implement `Unsize`.
     (accepted, relaxed_struct_unsize, "1.58.0", Some(81793)),
     /// Allows the `#[repr(i128)]` attribute for enums.
-    (accepted, repr128, "CURRENT_RUSTC_VERSION", Some(56071)),
+    (accepted, repr128, "1.89.0", Some(56071)),
     /// Allows `repr(align(16))` struct attribute (RFC 1358).
     (accepted, repr_align, "1.25.0", Some(33626)),
     /// Allows using `#[repr(align(X))]` on enums with equivalent semantics
@@ -389,7 +389,7 @@ macro_rules! declare_features {
     /// Allows `Self` struct constructor (RFC 2302).
     (accepted, self_struct_ctor, "1.32.0", Some(51994)),
     /// Allows use of x86 SHA512, SM3 and SM4 target-features and intrinsics
-    (accepted, sha512_sm_x86, "CURRENT_RUSTC_VERSION", Some(126624)),
+    (accepted, sha512_sm_x86, "1.89.0", Some(126624)),
     /// Shorten the tail expression lifetime
     (accepted, shorter_tail_lifetimes, "1.84.0", Some(123739)),
     /// Allows using subslice patterns, `[a, .., b]` and `[a, xs @ .., b]`.
diff --git a/compiler/rustc_feature/src/removed.rs b/compiler/rustc_feature/src/removed.rs
index a855e4c1..7e174c4 100644
--- a/compiler/rustc_feature/src/removed.rs
+++ b/compiler/rustc_feature/src/removed.rs
@@ -123,6 +123,9 @@ macro_rules! declare_features {
     /// [^1]: Formerly known as "object safe".
     (removed, dyn_compatible_for_dispatch, "1.87.0", Some(43561),
      Some("removed, not used heavily and represented additional complexity in dyn compatibility"), 136522),
+    /// Allows `dyn* Trait` objects.
+    (removed, dyn_star, "1.65.0", Some(102425),
+     Some("removed as it was no longer necessary for AFIDT (async fn in dyn trait) support")),
     /// Uses generic effect parameters for [const] bounds
     (removed, effects, "1.84.0", Some(102090),
      Some("removed, redundant with `#![feature(const_trait_impl)]`"), 132479),
@@ -222,7 +225,7 @@ macro_rules! declare_features {
     /// Allows exhaustive integer pattern matching with `usize::MAX`/`isize::MIN`/`isize::MAX`.
     (removed, precise_pointer_size_matching, "1.76.0", Some(56354),
      Some("removed in favor of half-open ranges"), 118598),
-    (removed, pref_align_of, "CURRENT_RUSTC_VERSION", Some(91971),
+    (removed, pref_align_of, "1.89.0", Some(91971),
      Some("removed due to marginal use and inducing compiler complications")),
     (removed, proc_macro_expr, "1.27.0", Some(54727),
      Some("subsumed by `#![feature(proc_macro_hygiene)]`"), 52121),
@@ -265,7 +268,7 @@ macro_rules! declare_features {
     (removed, unnamed_fields, "1.83.0", Some(49804), Some("feature needs redesign"), 131045),
     (removed, unsafe_no_drop_flag, "1.0.0", None, None),
     /// Allows unsized rvalues at arguments and parameters.
-    (removed, unsized_locals, "CURRENT_RUSTC_VERSION", Some(48055), Some("removed due to implementation concerns; see https://github.com/rust-lang/rust/issues/111942")),
+    (removed, unsized_locals, "1.89.0", Some(48055), Some("removed due to implementation concerns; see https://github.com/rust-lang/rust/issues/111942")),
     (removed, unsized_tuple_coercion, "1.87.0", Some(42877),
      Some("The feature restricts possible layouts for tuples, and this restriction is not worth it."), 137728),
     /// Allows `union` fields that don't implement `Copy` as long as they don't have any drop glue.
diff --git a/compiler/rustc_feature/src/unstable.rs b/compiler/rustc_feature/src/unstable.rs
index 9c62c44..efd8bde 100644
--- a/compiler/rustc_feature/src/unstable.rs
+++ b/compiler/rustc_feature/src/unstable.rs
@@ -238,7 +238,7 @@ pub fn internal(&self, feature: Symbol) -> bool {
     /// Allows using `rustc_*` attributes (RFC 572).
     (internal, rustc_attrs, "1.0.0", None),
     /// Introduces a hierarchy of `Sized` traits (RFC 3729).
-    (unstable, sized_hierarchy, "CURRENT_RUSTC_VERSION", None),
+    (unstable, sized_hierarchy, "1.89.0", None),
     /// Allows using the `#[stable]` and `#[unstable]` attributes.
     (internal, staged_api, "1.0.0", None),
     /// Added for testing unstable lints; perma-unstable.
@@ -356,7 +356,7 @@ pub fn internal(&self, feature: Symbol) -> bool {
     /// Allows `extern "cmse-nonsecure-call" fn()`.
     (unstable, abi_cmse_nonsecure_call, "CURRENT_RUSTC_VERSION", Some(81391)),
     /// Allows `extern "custom" fn()`.
-    (unstable, abi_custom, "CURRENT_RUSTC_VERSION", Some(140829)),
+    (unstable, abi_custom, "1.89.0", Some(140829)),
     /// Allows `extern "gpu-kernel" fn()`.
     (unstable, abi_gpu_kernel, "1.86.0", Some(135467)),
     /// Allows `extern "msp430-interrupt" fn()`.
@@ -376,7 +376,7 @@ pub fn internal(&self, feature: Symbol) -> bool {
     /// Allows inherent and trait methods with arbitrary self types that are raw pointers.
     (unstable, arbitrary_self_types_pointers, "1.83.0", Some(44874)),
     /// Allows #[cfg(...)] on inline assembly templates and operands.
-    (unstable, asm_cfg, "CURRENT_RUSTC_VERSION", Some(140364)),
+    (unstable, asm_cfg, "1.89.0", Some(140364)),
     /// Enables experimental inline assembly support for additional architectures.
     (unstable, asm_experimental_arch, "1.58.0", Some(93335)),
     /// Enables experimental register support in inline assembly.
@@ -481,8 +481,6 @@ pub fn internal(&self, feature: Symbol) -> bool {
     (unstable, doc_cfg_hide, "1.57.0", Some(43781)),
     /// Allows `#[doc(masked)]`.
     (unstable, doc_masked, "1.21.0", Some(44027)),
-    /// Allows `dyn* Trait` objects.
-    (incomplete, dyn_star, "1.65.0", Some(102425)),
     /// Allows the .use postfix syntax `x.use` and use closures `use |x| { ... }`
     (incomplete, ergonomic_clones, "1.87.0", Some(132290)),
     /// Allows exhaustive pattern matching on types that contain uninhabited types.
diff --git a/compiler/rustc_hir/src/arena.rs b/compiler/rustc_hir/src/arena.rs
index b0dff63..180cb64 100644
--- a/compiler/rustc_hir/src/arena.rs
+++ b/compiler/rustc_hir/src/arena.rs
@@ -8,7 +8,6 @@ macro_rules! arena_types {
             [] asm_template: rustc_ast::InlineAsmTemplatePiece,
             [] attribute: rustc_hir::Attribute,
             [] owner_info: rustc_hir::OwnerInfo<'tcx>,
-            [] lit: rustc_hir::Lit,
             [] macro_def: rustc_ast::MacroDef,
         ]);
     )
diff --git a/compiler/rustc_hir/src/hir.rs b/compiler/rustc_hir/src/hir.rs
index 75dff58..c90cd93 100644
--- a/compiler/rustc_hir/src/hir.rs
+++ b/compiler/rustc_hir/src/hir.rs
@@ -956,7 +956,7 @@ pub fn bounds_span_for_suggestions(
                     && let Some(ret_ty) = segment.args().paren_sugar_output()
                     && let ret_ty = ret_ty.peel_refs()
                     && let TyKind::TraitObject(_, tagged_ptr) = ret_ty.kind
-                    && let TraitObjectSyntax::Dyn | TraitObjectSyntax::DynStar = tagged_ptr.tag()
+                    && let TraitObjectSyntax::Dyn = tagged_ptr.tag()
                     && ret_ty.span.can_be_used_for_suggestions()
                 {
                     Some(ret_ty.span)
@@ -1807,7 +1807,7 @@ pub struct PatExpr<'hir> {
 #[derive(Debug, Clone, Copy, HashStable_Generic)]
 pub enum PatExprKind<'hir> {
     Lit {
-        lit: &'hir Lit,
+        lit: Lit,
         // FIXME: move this into `Lit` and handle negated literal expressions
         // once instead of matching on unop neg expressions everywhere.
         negated: bool,
@@ -2734,7 +2734,7 @@ pub enum ExprKind<'hir> {
     /// A unary operation (e.g., `!x`, `*x`).
     Unary(UnOp, &'hir Expr<'hir>),
     /// A literal (e.g., `1`, `"foo"`).
-    Lit(&'hir Lit),
+    Lit(Lit),
     /// A cast (e.g., `foo as f64`).
     Cast(&'hir Expr<'hir>, &'hir Ty<'hir>),
     /// A type ascription (e.g., `x: Foo`). See RFC 3307.
@@ -3141,15 +3141,6 @@ pub enum TraitItemKind<'hir> {
     /// type.
     Type(GenericBounds<'hir>, Option<&'hir Ty<'hir>>),
 }
-impl TraitItemKind<'_> {
-    pub fn descr(&self) -> &'static str {
-        match self {
-            TraitItemKind::Const(..) => "associated constant",
-            TraitItemKind::Fn(..) => "function",
-            TraitItemKind::Type(..) => "associated type",
-        }
-    }
-}
 
 // The bodies for items are stored "out of line", in a separate
 // hashmap in the `Crate`. Here we just record the hir-id of the item
@@ -3211,15 +3202,6 @@ pub enum ImplItemKind<'hir> {
     /// An associated type.
     Type(&'hir Ty<'hir>),
 }
-impl ImplItemKind<'_> {
-    pub fn descr(&self) -> &'static str {
-        match self {
-            ImplItemKind::Const(..) => "associated constant",
-            ImplItemKind::Fn(..) => "function",
-            ImplItemKind::Type(..) => "associated type",
-        }
-    }
-}
 
 /// A constraint on an associated item.
 ///
@@ -4418,27 +4400,6 @@ pub fn generics(&self) -> Option<&Generics<'_>> {
             _ => return None,
         })
     }
-
-    pub fn descr(&self) -> &'static str {
-        match self {
-            ItemKind::ExternCrate(..) => "extern crate",
-            ItemKind::Use(..) => "`use` import",
-            ItemKind::Static(..) => "static item",
-            ItemKind::Const(..) => "constant item",
-            ItemKind::Fn { .. } => "function",
-            ItemKind::Macro(..) => "macro",
-            ItemKind::Mod(..) => "module",
-            ItemKind::ForeignMod { .. } => "extern block",
-            ItemKind::GlobalAsm { .. } => "global asm item",
-            ItemKind::TyAlias(..) => "type alias",
-            ItemKind::Enum(..) => "enum",
-            ItemKind::Struct(..) => "struct",
-            ItemKind::Union(..) => "union",
-            ItemKind::Trait(..) => "trait",
-            ItemKind::TraitAlias(..) => "trait alias",
-            ItemKind::Impl(..) => "implementation",
-        }
-    }
 }
 
 /// A reference from an trait to one of its associated items. This
@@ -4545,16 +4506,6 @@ pub enum ForeignItemKind<'hir> {
     Type,
 }
 
-impl ForeignItemKind<'_> {
-    pub fn descr(&self) -> &'static str {
-        match self {
-            ForeignItemKind::Fn(..) => "function",
-            ForeignItemKind::Static(..) => "static variable",
-            ForeignItemKind::Type => "type",
-        }
-    }
-}
-
 /// A variable captured by a closure.
 #[derive(Debug, Copy, Clone, HashStable_Generic)]
 pub struct Upvar {
@@ -4862,6 +4813,10 @@ pub fn ty(self) -> Option<&'hir Ty<'hir>> {
                 ImplItemKind::Type(ty) => Some(ty),
                 _ => None,
             },
+            Node::ForeignItem(it) => match it.kind {
+                ForeignItemKind::Static(ty, ..) => Some(ty),
+                _ => None,
+            },
             _ => None,
         }
     }
diff --git a/compiler/rustc_hir/src/hir/tests.rs b/compiler/rustc_hir/src/hir/tests.rs
index 1fd793b..4f9609f 100644
--- a/compiler/rustc_hir/src/hir/tests.rs
+++ b/compiler/rustc_hir/src/hir/tests.rs
@@ -45,7 +45,6 @@ fn $name() {
 #[test]
 fn trait_object_roundtrips() {
     trait_object_roundtrips_impl(TraitObjectSyntax::Dyn);
-    trait_object_roundtrips_impl(TraitObjectSyntax::DynStar);
     trait_object_roundtrips_impl(TraitObjectSyntax::None);
 }
 
diff --git a/compiler/rustc_hir/src/intravisit.rs b/compiler/rustc_hir/src/intravisit.rs
index 57e4962..a0bc318 100644
--- a/compiler/rustc_hir/src/intravisit.rs
+++ b/compiler/rustc_hir/src/intravisit.rs
@@ -347,7 +347,7 @@ fn visit_pat_field(&mut self, f: &'v PatField<'v>) -> Self::Result {
     fn visit_pat_expr(&mut self, expr: &'v PatExpr<'v>) -> Self::Result {
         walk_pat_expr(self, expr)
     }
-    fn visit_lit(&mut self, _hir_id: HirId, _lit: &'v Lit, _negated: bool) -> Self::Result {
+    fn visit_lit(&mut self, _hir_id: HirId, _lit: Lit, _negated: bool) -> Self::Result {
         Self::Result::output()
     }
     fn visit_anon_const(&mut self, c: &'v AnonConst) -> Self::Result {
@@ -786,7 +786,7 @@ pub fn walk_pat_expr<'v, V: Visitor<'v>>(visitor: &mut V, expr: &'v PatExpr<'v>)
     let PatExpr { hir_id, span, kind } = expr;
     try_visit!(visitor.visit_id(*hir_id));
     match kind {
-        PatExprKind::Lit { lit, negated } => visitor.visit_lit(*hir_id, lit, *negated),
+        PatExprKind::Lit { lit, negated } => visitor.visit_lit(*hir_id, *lit, *negated),
         PatExprKind::ConstBlock(c) => visitor.visit_inline_const(c),
         PatExprKind::Path(qpath) => visitor.visit_qpath(qpath, *hir_id, *span),
     }
diff --git a/compiler/rustc_hir_analysis/src/check/check.rs b/compiler/rustc_hir_analysis/src/check/check.rs
index a361679..f4fcb13 100644
--- a/compiler/rustc_hir_analysis/src/check/check.rs
+++ b/compiler/rustc_hir_analysis/src/check/check.rs
@@ -10,7 +10,7 @@
 use rustc_hir::def::{CtorKind, DefKind};
 use rustc_hir::{LangItem, Node, intravisit};
 use rustc_infer::infer::{RegionVariableOrigin, TyCtxtInferExt};
-use rustc_infer::traits::{Obligation, ObligationCauseCode};
+use rustc_infer::traits::{Obligation, ObligationCauseCode, WellFormedLoc};
 use rustc_lint_defs::builtin::{
     REPR_TRANSPARENT_EXTERNAL_PRIVATE_FIELDS, UNSUPPORTED_CALLING_CONVENTIONS,
 };
@@ -36,6 +36,10 @@
 
 use super::compare_impl_item::check_type_bounds;
 use super::*;
+use crate::check::wfcheck::{
+    check_associated_item, check_trait_item, check_variances_for_type_defn, check_where_clauses,
+    enter_wf_checking_ctxt,
+};
 
 fn add_abi_diag_help<T: EmissionGuarantee>(abi: ExternAbi, diag: &mut Diag<'_, T>) {
     if let ExternAbi::Cdecl { unwind } = abi {
@@ -729,7 +733,8 @@ fn check_static_linkage(tcx: TyCtxt<'_>, def_id: LocalDefId) {
     }
 }
 
-pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) {
+pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) -> Result<(), ErrorGuaranteed> {
+    let mut res = Ok(());
     let generics = tcx.generics_of(def_id);
 
     for param in &generics.own_params {
@@ -754,15 +759,39 @@ pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) {
     }
 
     match tcx.def_kind(def_id) {
-        DefKind::Static { .. } => {
-            check_static_inhabited(tcx, def_id);
-            check_static_linkage(tcx, def_id);
+        def_kind @ (DefKind::Static { .. } | DefKind::Const) => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+            match def_kind {
+                DefKind::Static { .. } => {
+                    check_static_inhabited(tcx, def_id);
+                    check_static_linkage(tcx, def_id);
+                    res = res.and(wfcheck::check_static_item(tcx, def_id));
+
+                    // Only `Node::Item` and `Node::ForeignItem` still have HIR based
+                    // checks. Returning early here does not miss any checks and
+                    // avoids this query from having a direct dependency edge on the HIR
+                    return res;
+                }
+                DefKind::Const => {}
+                _ => unreachable!(),
+            }
         }
-        DefKind::Const => {}
         DefKind::Enum => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+            crate::collect::lower_enum_variant_types(tcx, def_id.to_def_id());
             check_enum(tcx, def_id);
+            check_variances_for_type_defn(tcx, def_id);
         }
         DefKind::Fn => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+            tcx.ensure_ok().fn_sig(def_id);
+            tcx.ensure_ok().codegen_fn_attrs(def_id);
             if let Some(i) = tcx.intrinsic(def_id) {
                 intrinsic::check_intrinsic_type(
                     tcx,
@@ -773,17 +802,31 @@ pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) {
             }
         }
         DefKind::Impl { of_trait } => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().impl_trait_header(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+            tcx.ensure_ok().associated_items(def_id);
             if of_trait && let Some(impl_trait_header) = tcx.impl_trait_header(def_id) {
-                if tcx
-                    .ensure_ok()
-                    .coherent_trait(impl_trait_header.trait_ref.instantiate_identity().def_id)
-                    .is_ok()
-                {
+                res = res.and(
+                    tcx.ensure_ok()
+                        .coherent_trait(impl_trait_header.trait_ref.instantiate_identity().def_id),
+                );
+
+                if res.is_ok() {
+                    // Checking this only makes sense if the all trait impls satisfy basic
+                    // requirements (see `coherent_trait` query), otherwise
+                    // we run into infinite recursions a lot.
                     check_impl_items_against_trait(tcx, def_id, impl_trait_header);
                 }
             }
         }
         DefKind::Trait => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().trait_def(def_id);
+            tcx.ensure_ok().explicit_super_predicates_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+            tcx.ensure_ok().associated_items(def_id);
             let assoc_items = tcx.associated_items(def_id);
             check_on_unimplemented(tcx, def_id);
 
@@ -802,11 +845,33 @@ pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) {
                 }
             }
         }
-        DefKind::Struct => {
-            check_struct(tcx, def_id);
+        DefKind::TraitAlias => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().explicit_implied_predicates_of(def_id);
+            tcx.ensure_ok().explicit_super_predicates_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
         }
-        DefKind::Union => {
-            check_union(tcx, def_id);
+        def_kind @ (DefKind::Struct | DefKind::Union) => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+
+            let adt = tcx.adt_def(def_id).non_enum_variant();
+            for f in adt.fields.iter() {
+                tcx.ensure_ok().generics_of(f.did);
+                tcx.ensure_ok().type_of(f.did);
+                tcx.ensure_ok().predicates_of(f.did);
+            }
+
+            if let Some((_, ctor_def_id)) = adt.ctor {
+                crate::collect::lower_variant_ctor(tcx, ctor_def_id.expect_local());
+            }
+            match def_kind {
+                DefKind::Struct => check_struct(tcx, def_id),
+                DefKind::Union => check_union(tcx, def_id),
+                _ => unreachable!(),
+            }
+            check_variances_for_type_defn(tcx, def_id);
         }
         DefKind::OpaqueTy => {
             check_opaque_precise_captures(tcx, def_id);
@@ -831,14 +896,37 @@ pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) {
                 tcx.ensure_ok().explicit_implied_const_bounds(def_id);
                 tcx.ensure_ok().const_conditions(def_id);
             }
+
+            // Only `Node::Item` and `Node::ForeignItem` still have HIR based
+            // checks. Returning early here does not miss any checks and
+            // avoids this query from having a direct dependency edge on the HIR
+            return res;
         }
         DefKind::TyAlias => {
+            tcx.ensure_ok().generics_of(def_id);
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
             check_type_alias_type_params_are_used(tcx, def_id);
+            if tcx.type_alias_is_lazy(def_id) {
+                res = res.and(enter_wf_checking_ctxt(tcx, def_id, |wfcx| {
+                    let ty = tcx.type_of(def_id).instantiate_identity();
+                    let span = tcx.def_span(def_id);
+                    let item_ty = wfcx.deeply_normalize(span, Some(WellFormedLoc::Ty(def_id)), ty);
+                    wfcx.register_wf_obligation(
+                        span,
+                        Some(WellFormedLoc::Ty(def_id)),
+                        item_ty.into(),
+                    );
+                    check_where_clauses(wfcx, def_id);
+                    Ok(())
+                }));
+                check_variances_for_type_defn(tcx, def_id);
+            }
         }
         DefKind::ForeignMod => {
             let it = tcx.hir_expect_item(def_id);
             let hir::ItemKind::ForeignMod { abi, items } = it.kind else {
-                return;
+                return Ok(());
             };
 
             check_abi(tcx, it.hir_id(), it.span, abi);
@@ -877,15 +965,23 @@ pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) {
                 }
 
                 let item = tcx.hir_foreign_item(item.id);
-                match &item.kind {
-                    hir::ForeignItemKind::Fn(sig, _, _) => {
+                tcx.ensure_ok().generics_of(item.owner_id);
+                tcx.ensure_ok().type_of(item.owner_id);
+                tcx.ensure_ok().predicates_of(item.owner_id);
+                if tcx.is_conditionally_const(def_id) {
+                    tcx.ensure_ok().explicit_implied_const_bounds(def_id);
+                    tcx.ensure_ok().const_conditions(def_id);
+                }
+                match item.kind {
+                    hir::ForeignItemKind::Fn(sig, ..) => {
+                        tcx.ensure_ok().codegen_fn_attrs(item.owner_id);
+                        tcx.ensure_ok().fn_sig(item.owner_id);
                         require_c_abi_if_c_variadic(tcx, sig.decl, abi, item.span);
                     }
                     hir::ForeignItemKind::Static(..) => {
-                        check_static_inhabited(tcx, def_id);
-                        check_static_linkage(tcx, def_id);
+                        tcx.ensure_ok().codegen_fn_attrs(item.owner_id);
                     }
-                    _ => {}
+                    _ => (),
                 }
             }
         }
@@ -897,9 +993,85 @@ pub(crate) fn check_item_type(tcx: TyCtxt<'_>, def_id: LocalDefId) {
             // We do not call `type_of` for closures here as that
             // depends on typecheck and would therefore hide
             // any further errors in case one typeck fails.
+
+            // Only `Node::Item` and `Node::ForeignItem` still have HIR based
+            // checks. Returning early here does not miss any checks and
+            // avoids this query from having a direct dependency edge on the HIR
+            return res;
         }
+        DefKind::AssocFn => {
+            tcx.ensure_ok().codegen_fn_attrs(def_id);
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().fn_sig(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+            res = res.and(check_associated_item(tcx, def_id));
+            let assoc_item = tcx.associated_item(def_id);
+            match assoc_item.container {
+                ty::AssocItemContainer::Impl => {}
+                ty::AssocItemContainer::Trait => {
+                    res = res.and(check_trait_item(tcx, def_id));
+                }
+            }
+
+            // Only `Node::Item` and `Node::ForeignItem` still have HIR based
+            // checks. Returning early here does not miss any checks and
+            // avoids this query from having a direct dependency edge on the HIR
+            return res;
+        }
+        DefKind::AssocConst => {
+            tcx.ensure_ok().type_of(def_id);
+            tcx.ensure_ok().predicates_of(def_id);
+            res = res.and(check_associated_item(tcx, def_id));
+            let assoc_item = tcx.associated_item(def_id);
+            match assoc_item.container {
+                ty::AssocItemContainer::Impl => {}
+                ty::AssocItemContainer::Trait => {
+                    res = res.and(check_trait_item(tcx, def_id));
+                }
+            }
+
+            // Only `Node::Item` and `Node::ForeignItem` still have HIR based
+            // checks. Returning early here does not miss any checks and
+            // avoids this query from having a direct dependency edge on the HIR
+            return res;
+        }
+        DefKind::AssocTy => {
+            tcx.ensure_ok().predicates_of(def_id);
+            res = res.and(check_associated_item(tcx, def_id));
+
+            let assoc_item = tcx.associated_item(def_id);
+            let has_type = match assoc_item.container {
+                ty::AssocItemContainer::Impl => true,
+                ty::AssocItemContainer::Trait => {
+                    tcx.ensure_ok().item_bounds(def_id);
+                    tcx.ensure_ok().item_self_bounds(def_id);
+                    res = res.and(check_trait_item(tcx, def_id));
+                    assoc_item.defaultness(tcx).has_value()
+                }
+            };
+            if has_type {
+                tcx.ensure_ok().type_of(def_id);
+            }
+
+            // Only `Node::Item` and `Node::ForeignItem` still have HIR based
+            // checks. Returning early here does not miss any checks and
+            // avoids this query from having a direct dependency edge on the HIR
+            return res;
+        }
+
+        // Only `Node::Item` and `Node::ForeignItem` still have HIR based
+        // checks. Returning early here does not miss any checks and
+        // avoids this query from having a direct dependency edge on the HIR
+        DefKind::AnonConst | DefKind::InlineConst => return res,
         _ => {}
     }
+    let node = tcx.hir_node_by_def_id(def_id);
+    res.and(match node {
+        hir::Node::Crate(_) => bug!("check_well_formed cannot be applied to the crate root"),
+        hir::Node::Item(item) => wfcheck::check_item(tcx, item),
+        hir::Node::ForeignItem(item) => wfcheck::check_foreign_item(tcx, item),
+        _ => unreachable!("{node:?}"),
+    })
 }
 
 pub(super) fn check_on_unimplemented(tcx: TyCtxt<'_>, def_id: LocalDefId) {
diff --git a/compiler/rustc_hir_analysis/src/check/wfcheck.rs b/compiler/rustc_hir_analysis/src/check/wfcheck.rs
index b9124ea..ed8d25e 100644
--- a/compiler/rustc_hir_analysis/src/check/wfcheck.rs
+++ b/compiler/rustc_hir_analysis/src/check/wfcheck.rs
@@ -25,7 +25,7 @@
 };
 use rustc_middle::{bug, span_bug};
 use rustc_session::parse::feature_err;
-use rustc_span::{DUMMY_SP, Ident, Span, sym};
+use rustc_span::{DUMMY_SP, Span, sym};
 use rustc_trait_selection::error_reporting::InferCtxtErrorExt;
 use rustc_trait_selection::regions::{InferCtxtRegionExt, OutlivesEnvironmentBuildExt};
 use rustc_trait_selection::traits::misc::{
@@ -46,7 +46,6 @@
 
 pub(super) struct WfCheckingCtxt<'a, 'tcx> {
     pub(super) ocx: ObligationCtxt<'a, 'tcx, FulfillmentError<'tcx>>,
-    span: Span,
     body_def_id: LocalDefId,
     param_env: ty::ParamEnv<'tcx>,
 }
@@ -84,7 +83,7 @@ fn normalize<T>(&self, span: Span, loc: Option<WellFormedLoc>, value: T) -> T
     /// signature types for implied bounds when checking regions.
     // FIXME(-Znext-solver): This should be removed when we compute implied outlives
     // bounds using the unnormalized signature of the function we're checking.
-    fn deeply_normalize<T>(&self, span: Span, loc: Option<WellFormedLoc>, value: T) -> T
+    pub(super) fn deeply_normalize<T>(&self, span: Span, loc: Option<WellFormedLoc>, value: T) -> T
     where
         T: TypeFoldable<TyCtxt<'tcx>>,
     {
@@ -105,7 +104,12 @@ fn deeply_normalize<T>(&self, span: Span, loc: Option<WellFormedLoc>, value: T)
         }
     }
 
-    fn register_wf_obligation(&self, span: Span, loc: Option<WellFormedLoc>, term: ty::Term<'tcx>) {
+    pub(super) fn register_wf_obligation(
+        &self,
+        span: Span,
+        loc: Option<WellFormedLoc>,
+        term: ty::Term<'tcx>,
+    ) {
         let cause = traits::ObligationCause::new(
             span,
             self.body_def_id,
@@ -122,7 +126,6 @@ fn register_wf_obligation(&self, span: Span, loc: Option<WellFormedLoc>, term: t
 
 pub(super) fn enter_wf_checking_ctxt<'tcx, F>(
     tcx: TyCtxt<'tcx>,
-    span: Span,
     body_def_id: LocalDefId,
     f: F,
 ) -> Result<(), ErrorGuaranteed>
@@ -133,7 +136,7 @@ pub(super) fn enter_wf_checking_ctxt<'tcx, F>(
     let infcx = &tcx.infer_ctxt().build(TypingMode::non_body_analysis());
     let ocx = ObligationCtxt::new_with_diagnostics(infcx);
 
-    let mut wfcx = WfCheckingCtxt { ocx, span, body_def_id, param_env };
+    let mut wfcx = WfCheckingCtxt { ocx, body_def_id, param_env };
 
     if !tcx.features().trivial_bounds() {
         wfcx.check_false_global_bounds()
@@ -187,23 +190,10 @@ pub(super) fn enter_wf_checking_ctxt<'tcx, F>(
 }
 
 fn check_well_formed(tcx: TyCtxt<'_>, def_id: LocalDefId) -> Result<(), ErrorGuaranteed> {
-    let node = tcx.hir_node_by_def_id(def_id);
-    let mut res = match node {
-        hir::Node::Crate(_) => bug!("check_well_formed cannot be applied to the crate root"),
-        hir::Node::Item(item) => check_item(tcx, item),
-        hir::Node::TraitItem(item) => check_trait_item(tcx, item),
-        hir::Node::ImplItem(item) => check_impl_item(tcx, item),
-        hir::Node::ForeignItem(item) => check_foreign_item(tcx, item),
-        hir::Node::ConstBlock(_) | hir::Node::Expr(_) | hir::Node::OpaqueTy(_) => {
-            Ok(crate::check::check::check_item_type(tcx, def_id))
-        }
-        _ => unreachable!("{node:?}"),
-    };
+    let mut res = crate::check::check::check_item_type(tcx, def_id);
 
-    if let Some(generics) = node.generics() {
-        for param in generics.params {
-            res = res.and(check_param_wf(tcx, param));
-        }
+    for param in &tcx.generics_of(def_id).own_params {
+        res = res.and(check_param_wf(tcx, param));
     }
 
     res
@@ -223,16 +213,18 @@ fn check_well_formed(tcx: TyCtxt<'_>, def_id: LocalDefId) -> Result<(), ErrorGua
 /// not included it frequently leads to confusing errors in fn bodies. So it's better to check
 /// the types first.
 #[instrument(skip(tcx), level = "debug")]
-fn check_item<'tcx>(tcx: TyCtxt<'tcx>, item: &'tcx hir::Item<'tcx>) -> Result<(), ErrorGuaranteed> {
+pub(super) fn check_item<'tcx>(
+    tcx: TyCtxt<'tcx>,
+    item: &'tcx hir::Item<'tcx>,
+) -> Result<(), ErrorGuaranteed> {
     let def_id = item.owner_id.def_id;
 
     debug!(
         ?item.owner_id,
         item.name = ? tcx.def_path_str(def_id)
     );
-    crate::collect::lower_item(tcx, item.item_id());
 
-    let res = match item.kind {
+    match item.kind {
         // Right now we check that every default trait implementation
         // has an implementation of itself. Basically, a case like:
         //
@@ -295,57 +287,18 @@ fn check_item<'tcx>(tcx: TyCtxt<'tcx>, item: &'tcx hir::Item<'tcx>) -> Result<()
             }
             res
         }
-        hir::ItemKind::Fn { ident, sig, .. } => {
-            check_item_fn(tcx, def_id, ident, item.span, sig.decl)
-        }
-        hir::ItemKind::Static(_, _, ty, _) => {
-            check_static_item(tcx, def_id, ty.span, UnsizedHandling::Forbid)
-        }
-        hir::ItemKind::Const(_, _, ty, _) => check_const_item(tcx, def_id, ty.span, item.span),
-        hir::ItemKind::Struct(_, generics, _) => {
-            let res = check_type_defn(tcx, item, false);
-            check_variances_for_type_defn(tcx, item, generics);
-            res
-        }
-        hir::ItemKind::Union(_, generics, _) => {
-            let res = check_type_defn(tcx, item, true);
-            check_variances_for_type_defn(tcx, item, generics);
-            res
-        }
-        hir::ItemKind::Enum(_, generics, _) => {
-            let res = check_type_defn(tcx, item, true);
-            check_variances_for_type_defn(tcx, item, generics);
-            res
-        }
+        hir::ItemKind::Fn { sig, .. } => check_item_fn(tcx, def_id, sig.decl),
+        hir::ItemKind::Const(_, _, ty, _) => check_const_item(tcx, def_id, ty.span),
+        hir::ItemKind::Struct(..) => check_type_defn(tcx, item, false),
+        hir::ItemKind::Union(..) => check_type_defn(tcx, item, true),
+        hir::ItemKind::Enum(..) => check_type_defn(tcx, item, true),
         hir::ItemKind::Trait(..) => check_trait(tcx, item),
         hir::ItemKind::TraitAlias(..) => check_trait(tcx, item),
-        // `ForeignItem`s are handled separately.
-        hir::ItemKind::ForeignMod { .. } => Ok(()),
-        hir::ItemKind::TyAlias(_, generics, hir_ty) if tcx.type_alias_is_lazy(item.owner_id) => {
-            let res = enter_wf_checking_ctxt(tcx, item.span, def_id, |wfcx| {
-                let ty = tcx.type_of(def_id).instantiate_identity();
-                let item_ty =
-                    wfcx.deeply_normalize(hir_ty.span, Some(WellFormedLoc::Ty(def_id)), ty);
-                wfcx.register_wf_obligation(
-                    hir_ty.span,
-                    Some(WellFormedLoc::Ty(def_id)),
-                    item_ty.into(),
-                );
-                check_where_clauses(wfcx, item.span, def_id);
-                Ok(())
-            });
-            check_variances_for_type_defn(tcx, item, generics);
-            res
-        }
         _ => Ok(()),
-    };
-
-    crate::check::check::check_item_type(tcx, def_id);
-
-    res
+    }
 }
 
-fn check_foreign_item<'tcx>(
+pub(super) fn check_foreign_item<'tcx>(
     tcx: TyCtxt<'tcx>,
     item: &'tcx hir::ForeignItem<'tcx>,
 ) -> Result<(), ErrorGuaranteed> {
@@ -357,43 +310,23 @@ fn check_foreign_item<'tcx>(
     );
 
     match item.kind {
-        hir::ForeignItemKind::Fn(sig, ..) => {
-            check_item_fn(tcx, def_id, item.ident, item.span, sig.decl)
-        }
-        hir::ForeignItemKind::Static(ty, ..) => {
-            check_static_item(tcx, def_id, ty.span, UnsizedHandling::AllowIfForeignTail)
-        }
-        hir::ForeignItemKind::Type => Ok(()),
+        hir::ForeignItemKind::Fn(sig, ..) => check_item_fn(tcx, def_id, sig.decl),
+        hir::ForeignItemKind::Static(..) | hir::ForeignItemKind::Type => Ok(()),
     }
 }
 
-fn check_trait_item<'tcx>(
+pub(crate) fn check_trait_item<'tcx>(
     tcx: TyCtxt<'tcx>,
-    trait_item: &'tcx hir::TraitItem<'tcx>,
+    def_id: LocalDefId,
 ) -> Result<(), ErrorGuaranteed> {
-    let def_id = trait_item.owner_id.def_id;
-
-    crate::collect::lower_trait_item(tcx, trait_item.trait_item_id());
-
-    let (method_sig, span) = match trait_item.kind {
-        hir::TraitItemKind::Fn(ref sig, _) => (Some(sig), trait_item.span),
-        hir::TraitItemKind::Type(_bounds, Some(ty)) => (None, ty.span),
-        _ => (None, trait_item.span),
-    };
-
     // Check that an item definition in a subtrait is shadowing a supertrait item.
     lint_item_shadowing_supertrait_item(tcx, def_id);
 
-    let mut res = check_associated_item(tcx, def_id, span, method_sig);
+    let mut res = Ok(());
 
-    if matches!(trait_item.kind, hir::TraitItemKind::Fn(..)) {
+    if matches!(tcx.def_kind(def_id), DefKind::AssocFn) {
         for &assoc_ty_def_id in tcx.associated_types_for_impl_traits_in_associated_fn(def_id) {
-            res = res.and(check_associated_item(
-                tcx,
-                assoc_ty_def_id.expect_local(),
-                tcx.def_span(assoc_ty_def_id),
-                None,
-            ));
+            res = res.and(check_associated_item(tcx, assoc_ty_def_id.expect_local()));
         }
     }
     res
@@ -872,67 +805,54 @@ fn lint_item_shadowing_supertrait_item<'tcx>(tcx: TyCtxt<'tcx>, trait_item_def_i
     }
 }
 
-fn check_impl_item<'tcx>(
-    tcx: TyCtxt<'tcx>,
-    impl_item: &'tcx hir::ImplItem<'tcx>,
-) -> Result<(), ErrorGuaranteed> {
-    crate::collect::lower_impl_item(tcx, impl_item.impl_item_id());
-
-    let (method_sig, span) = match impl_item.kind {
-        hir::ImplItemKind::Fn(ref sig, _) => (Some(sig), impl_item.span),
-        // Constrain binding and overflow error spans to `<Ty>` in `type foo = <Ty>`.
-        hir::ImplItemKind::Type(ty) if ty.span != DUMMY_SP => (None, ty.span),
-        _ => (None, impl_item.span),
-    };
-    check_associated_item(tcx, impl_item.owner_id.def_id, span, method_sig)
-}
-
-fn check_param_wf(tcx: TyCtxt<'_>, param: &hir::GenericParam<'_>) -> Result<(), ErrorGuaranteed> {
+fn check_param_wf(tcx: TyCtxt<'_>, param: &ty::GenericParamDef) -> Result<(), ErrorGuaranteed> {
     match param.kind {
         // We currently only check wf of const params here.
-        hir::GenericParamKind::Lifetime { .. } | hir::GenericParamKind::Type { .. } => Ok(()),
+        ty::GenericParamDefKind::Lifetime | ty::GenericParamDefKind::Type { .. } => Ok(()),
 
         // Const parameters are well formed if their type is structural match.
-        hir::GenericParamKind::Const { ty: hir_ty, default: _, synthetic: _ } => {
+        ty::GenericParamDefKind::Const { .. } => {
             let ty = tcx.type_of(param.def_id).instantiate_identity();
+            let span = tcx.def_span(param.def_id);
+            let def_id = param.def_id.expect_local();
 
             if tcx.features().unsized_const_params() {
-                enter_wf_checking_ctxt(tcx, hir_ty.span, tcx.local_parent(param.def_id), |wfcx| {
+                enter_wf_checking_ctxt(tcx, tcx.local_parent(def_id), |wfcx| {
                     wfcx.register_bound(
-                        ObligationCause::new(
-                            hir_ty.span,
-                            param.def_id,
-                            ObligationCauseCode::ConstParam(ty),
-                        ),
+                        ObligationCause::new(span, def_id, ObligationCauseCode::ConstParam(ty)),
                         wfcx.param_env,
                         ty,
-                        tcx.require_lang_item(LangItem::UnsizedConstParamTy, hir_ty.span),
+                        tcx.require_lang_item(LangItem::UnsizedConstParamTy, span),
                     );
                     Ok(())
                 })
             } else if tcx.features().adt_const_params() {
-                enter_wf_checking_ctxt(tcx, hir_ty.span, tcx.local_parent(param.def_id), |wfcx| {
+                enter_wf_checking_ctxt(tcx, tcx.local_parent(def_id), |wfcx| {
                     wfcx.register_bound(
-                        ObligationCause::new(
-                            hir_ty.span,
-                            param.def_id,
-                            ObligationCauseCode::ConstParam(ty),
-                        ),
+                        ObligationCause::new(span, def_id, ObligationCauseCode::ConstParam(ty)),
                         wfcx.param_env,
                         ty,
-                        tcx.require_lang_item(LangItem::ConstParamTy, hir_ty.span),
+                        tcx.require_lang_item(LangItem::ConstParamTy, span),
                     );
                     Ok(())
                 })
             } else {
+                let span = || {
+                    let hir::GenericParamKind::Const { ty: &hir::Ty { span, .. }, .. } =
+                        tcx.hir_node_by_def_id(def_id).expect_generic_param().kind
+                    else {
+                        bug!()
+                    };
+                    span
+                };
                 let mut diag = match ty.kind() {
                     ty::Bool | ty::Char | ty::Int(_) | ty::Uint(_) | ty::Error(_) => return Ok(()),
                     ty::FnPtr(..) => tcx.dcx().struct_span_err(
-                        hir_ty.span,
+                        span(),
                         "using function pointers as const generic parameters is forbidden",
                     ),
                     ty::RawPtr(_, _) => tcx.dcx().struct_span_err(
-                        hir_ty.span,
+                        span(),
                         "using raw pointers as const generic parameters is forbidden",
                     ),
                     _ => {
@@ -940,7 +860,7 @@ fn check_param_wf(tcx: TyCtxt<'_>, param: &hir::GenericParam<'_>) -> Result<(),
                         ty.error_reported()?;
 
                         tcx.dcx().struct_span_err(
-                            hir_ty.span,
+                            span(),
                             format!(
                                 "`{ty}` is forbidden as the type of a const generic parameter",
                             ),
@@ -950,7 +870,7 @@ fn check_param_wf(tcx: TyCtxt<'_>, param: &hir::GenericParam<'_>) -> Result<(),
 
                 diag.note("the only supported types are integers, `bool`, and `char`");
 
-                let cause = ObligationCause::misc(hir_ty.span, param.def_id);
+                let cause = ObligationCause::misc(span(), def_id);
                 let adt_const_params_feature_string =
                     " more complex and user defined types".to_string();
                 let may_suggest_feature = match type_allowed_to_implement_const_param_ty(
@@ -1010,15 +930,13 @@ fn ty_is_local(ty: Ty<'_>) -> bool {
     }
 }
 
-#[instrument(level = "debug", skip(tcx, span, sig_if_method))]
-fn check_associated_item(
+#[instrument(level = "debug", skip(tcx))]
+pub(crate) fn check_associated_item(
     tcx: TyCtxt<'_>,
     item_id: LocalDefId,
-    span: Span,
-    sig_if_method: Option<&hir::FnSig<'_>>,
 ) -> Result<(), ErrorGuaranteed> {
     let loc = Some(WellFormedLoc::Ty(item_id));
-    enter_wf_checking_ctxt(tcx, span, item_id, |wfcx| {
+    enter_wf_checking_ctxt(tcx, item_id, |wfcx| {
         let item = tcx.associated_item(item_id);
 
         // Avoid bogus "type annotations needed `Foo: Bar`" errors on `impl Bar for Foo` in case
@@ -1033,6 +951,8 @@ fn check_associated_item(
             }
         };
 
+        let span = tcx.def_span(item_id);
+
         match item.kind {
             ty::AssocKind::Const { .. } => {
                 let ty = tcx.type_of(item.def_id).instantiate_identity();
@@ -1049,14 +969,9 @@ fn check_associated_item(
             }
             ty::AssocKind::Fn { .. } => {
                 let sig = tcx.fn_sig(item.def_id).instantiate_identity();
-                let hir_sig = sig_if_method.expect("bad signature for method");
-                check_fn_or_method(
-                    wfcx,
-                    item.ident(tcx).span,
-                    sig,
-                    hir_sig.decl,
-                    item.def_id.expect_local(),
-                );
+                let hir_sig =
+                    tcx.hir_node_by_def_id(item_id).fn_sig().expect("bad signature for method");
+                check_fn_or_method(wfcx, sig, hir_sig.decl, item_id);
                 check_method_receiver(wfcx, hir_sig, item, self_ty)
             }
             ty::AssocKind::Type { .. } => {
@@ -1083,7 +998,7 @@ fn check_type_defn<'tcx>(
     let _ = tcx.representability(item.owner_id.def_id);
     let adt_def = tcx.adt_def(item.owner_id);
 
-    enter_wf_checking_ctxt(tcx, item.span, item.owner_id.def_id, |wfcx| {
+    enter_wf_checking_ctxt(tcx, item.owner_id.def_id, |wfcx| {
         let variants = adt_def.variants();
         let packed = adt_def.repr().packed();
 
@@ -1185,7 +1100,7 @@ fn check_type_defn<'tcx>(
             }
         }
 
-        check_where_clauses(wfcx, item.span, item.owner_id.def_id);
+        check_where_clauses(wfcx, item.owner_id.def_id);
         Ok(())
     })
 }
@@ -1215,8 +1130,8 @@ fn check_trait(tcx: TyCtxt<'_>, item: &hir::Item<'_>) -> Result<(), ErrorGuarant
         }
     }
 
-    let res = enter_wf_checking_ctxt(tcx, item.span, def_id, |wfcx| {
-        check_where_clauses(wfcx, item.span, def_id);
+    let res = enter_wf_checking_ctxt(tcx, def_id, |wfcx| {
+        check_where_clauses(wfcx, def_id);
         Ok(())
     });
 
@@ -1252,72 +1167,63 @@ fn check_associated_type_bounds(wfcx: &WfCheckingCtxt<'_, '_>, item: ty::AssocIt
 fn check_item_fn(
     tcx: TyCtxt<'_>,
     def_id: LocalDefId,
-    ident: Ident,
-    span: Span,
     decl: &hir::FnDecl<'_>,
 ) -> Result<(), ErrorGuaranteed> {
-    enter_wf_checking_ctxt(tcx, span, def_id, |wfcx| {
+    enter_wf_checking_ctxt(tcx, def_id, |wfcx| {
         let sig = tcx.fn_sig(def_id).instantiate_identity();
-        check_fn_or_method(wfcx, ident.span, sig, decl, def_id);
+        check_fn_or_method(wfcx, sig, decl, def_id);
         Ok(())
     })
 }
 
-enum UnsizedHandling {
-    Forbid,
-    AllowIfForeignTail,
-}
-
-#[instrument(level = "debug", skip(tcx, ty_span, unsized_handling))]
-fn check_static_item(
+#[instrument(level = "debug", skip(tcx))]
+pub(super) fn check_static_item(
     tcx: TyCtxt<'_>,
     item_id: LocalDefId,
-    ty_span: Span,
-    unsized_handling: UnsizedHandling,
 ) -> Result<(), ErrorGuaranteed> {
-    enter_wf_checking_ctxt(tcx, ty_span, item_id, |wfcx| {
+    enter_wf_checking_ctxt(tcx, item_id, |wfcx| {
         let ty = tcx.type_of(item_id).instantiate_identity();
-        let item_ty = wfcx.deeply_normalize(ty_span, Some(WellFormedLoc::Ty(item_id)), ty);
+        let item_ty = wfcx.deeply_normalize(DUMMY_SP, Some(WellFormedLoc::Ty(item_id)), ty);
 
-        let forbid_unsized = match unsized_handling {
-            UnsizedHandling::Forbid => true,
-            UnsizedHandling::AllowIfForeignTail => {
-                let tail =
-                    tcx.struct_tail_for_codegen(item_ty, wfcx.infcx.typing_env(wfcx.param_env));
-                !matches!(tail.kind(), ty::Foreign(_))
-            }
+        let is_foreign_item = tcx.is_foreign_item(item_id);
+
+        let forbid_unsized = !is_foreign_item || {
+            let tail = tcx.struct_tail_for_codegen(item_ty, wfcx.infcx.typing_env(wfcx.param_env));
+            !matches!(tail.kind(), ty::Foreign(_))
         };
 
-        wfcx.register_wf_obligation(ty_span, Some(WellFormedLoc::Ty(item_id)), item_ty.into());
+        wfcx.register_wf_obligation(DUMMY_SP, Some(WellFormedLoc::Ty(item_id)), item_ty.into());
         if forbid_unsized {
+            let span = tcx.def_span(item_id);
             wfcx.register_bound(
                 traits::ObligationCause::new(
-                    ty_span,
+                    span,
                     wfcx.body_def_id,
                     ObligationCauseCode::SizedConstOrStatic,
                 ),
                 wfcx.param_env,
                 item_ty,
-                tcx.require_lang_item(LangItem::Sized, ty_span),
+                tcx.require_lang_item(LangItem::Sized, span),
             );
         }
 
         // Ensure that the end result is `Sync` in a non-thread local `static`.
         let should_check_for_sync = tcx.static_mutability(item_id.to_def_id())
             == Some(hir::Mutability::Not)
-            && !tcx.is_foreign_item(item_id.to_def_id())
+            && !is_foreign_item
             && !tcx.is_thread_local_static(item_id.to_def_id());
 
         if should_check_for_sync {
+            let span = tcx.def_span(item_id);
             wfcx.register_bound(
                 traits::ObligationCause::new(
-                    ty_span,
+                    span,
                     wfcx.body_def_id,
                     ObligationCauseCode::SharedStatic,
                 ),
                 wfcx.param_env,
                 item_ty,
-                tcx.require_lang_item(LangItem::Sync, ty_span),
+                tcx.require_lang_item(LangItem::Sync, span),
             );
         }
         Ok(())
@@ -1328,9 +1234,8 @@ fn check_const_item(
     tcx: TyCtxt<'_>,
     def_id: LocalDefId,
     ty_span: Span,
-    item_span: Span,
 ) -> Result<(), ErrorGuaranteed> {
-    enter_wf_checking_ctxt(tcx, ty_span, def_id, |wfcx| {
+    enter_wf_checking_ctxt(tcx, def_id, |wfcx| {
         let ty = tcx.type_of(def_id).instantiate_identity();
         let ty = wfcx.deeply_normalize(ty_span, Some(WellFormedLoc::Ty(def_id)), ty);
 
@@ -1346,7 +1251,7 @@ fn check_const_item(
             tcx.require_lang_item(LangItem::Sized, ty_span),
         );
 
-        check_where_clauses(wfcx, item_span, def_id);
+        check_where_clauses(wfcx, def_id);
 
         Ok(())
     })
@@ -1359,7 +1264,7 @@ fn check_impl<'tcx>(
     hir_self_ty: &hir::Ty<'_>,
     hir_trait_ref: &Option<hir::TraitRef<'_>>,
 ) -> Result<(), ErrorGuaranteed> {
-    enter_wf_checking_ctxt(tcx, item.span, item.owner_id.def_id, |wfcx| {
+    enter_wf_checking_ctxt(tcx, item.owner_id.def_id, |wfcx| {
         match hir_trait_ref {
             Some(hir_trait_ref) => {
                 // `#[rustc_reservation_impl]` impls are not real impls and
@@ -1443,14 +1348,14 @@ fn check_impl<'tcx>(
             }
         }
 
-        check_where_clauses(wfcx, item.span, item.owner_id.def_id);
+        check_where_clauses(wfcx, item.owner_id.def_id);
         Ok(())
     })
 }
 
 /// Checks where-clauses and inline bounds that are declared on `def_id`.
 #[instrument(level = "debug", skip(wfcx))]
-fn check_where_clauses<'tcx>(wfcx: &WfCheckingCtxt<'_, 'tcx>, span: Span, def_id: LocalDefId) {
+pub(super) fn check_where_clauses<'tcx>(wfcx: &WfCheckingCtxt<'_, 'tcx>, def_id: LocalDefId) {
     let infcx = wfcx.infcx;
     let tcx = wfcx.tcx();
 
@@ -1605,21 +1510,18 @@ fn visit_const(&mut self, c: ty::Const<'tcx>) -> Self::Result {
 
     let predicates = predicates.instantiate_identity(tcx);
 
-    let predicates = wfcx.normalize(span, None, predicates);
-
-    debug!(?predicates.predicates);
     assert_eq!(predicates.predicates.len(), predicates.spans.len());
     let wf_obligations = predicates.into_iter().flat_map(|(p, sp)| {
+        let p = wfcx.normalize(sp, None, p);
         traits::wf::clause_obligations(infcx, wfcx.param_env, wfcx.body_def_id, p, sp)
     });
     let obligations: Vec<_> = wf_obligations.chain(default_obligations).collect();
     wfcx.register_obligations(obligations);
 }
 
-#[instrument(level = "debug", skip(wfcx, span, hir_decl))]
+#[instrument(level = "debug", skip(wfcx, hir_decl))]
 fn check_fn_or_method<'tcx>(
     wfcx: &WfCheckingCtxt<'_, 'tcx>,
-    span: Span,
     sig: ty::PolyFnSig<'tcx>,
     hir_decl: &hir::FnDecl<'_>,
     def_id: LocalDefId,
@@ -1657,7 +1559,7 @@ fn check_fn_or_method<'tcx>(
         );
     }
 
-    check_where_clauses(wfcx, span, def_id);
+    check_where_clauses(wfcx, def_id);
 
     if sig.abi == ExternAbi::RustCall {
         let span = tcx.def_span(def_id);
@@ -1746,17 +1648,18 @@ fn check_method_receiver<'tcx>(
     }
 
     let span = fn_sig.decl.inputs[0].span;
+    let loc = Some(WellFormedLoc::Param { function: method.def_id.expect_local(), param_idx: 0 });
 
     let sig = tcx.fn_sig(method.def_id).instantiate_identity();
     let sig = tcx.liberate_late_bound_regions(method.def_id, sig);
-    let sig = wfcx.normalize(span, None, sig);
+    let sig = wfcx.normalize(DUMMY_SP, loc, sig);
 
     debug!("check_method_receiver: sig={:?}", sig);
 
-    let self_ty = wfcx.normalize(span, None, self_ty);
+    let self_ty = wfcx.normalize(DUMMY_SP, loc, self_ty);
 
     let receiver_ty = sig.inputs()[0];
-    let receiver_ty = wfcx.normalize(span, None, receiver_ty);
+    let receiver_ty = wfcx.normalize(DUMMY_SP, loc, receiver_ty);
 
     // If the receiver already has errors reported, consider it valid to avoid
     // unnecessary errors (#58712).
@@ -2004,27 +1907,23 @@ fn legacy_receiver_is_implemented<'tcx>(
     }
 }
 
-fn check_variances_for_type_defn<'tcx>(
-    tcx: TyCtxt<'tcx>,
-    item: &'tcx hir::Item<'tcx>,
-    hir_generics: &hir::Generics<'tcx>,
-) {
-    match item.kind {
-        ItemKind::Enum(..) | ItemKind::Struct(..) | ItemKind::Union(..) => {
+pub(super) fn check_variances_for_type_defn<'tcx>(tcx: TyCtxt<'tcx>, def_id: LocalDefId) {
+    match tcx.def_kind(def_id) {
+        DefKind::Enum | DefKind::Struct | DefKind::Union => {
             // Ok
         }
-        ItemKind::TyAlias(..) => {
+        DefKind::TyAlias => {
             assert!(
-                tcx.type_alias_is_lazy(item.owner_id),
+                tcx.type_alias_is_lazy(def_id),
                 "should not be computing variance of non-free type alias"
             );
         }
-        kind => span_bug!(item.span, "cannot compute the variances of {kind:?}"),
+        kind => span_bug!(tcx.def_span(def_id), "cannot compute the variances of {kind:?}"),
     }
 
-    let ty_predicates = tcx.predicates_of(item.owner_id);
+    let ty_predicates = tcx.predicates_of(def_id);
     assert_eq!(ty_predicates.parent, None);
-    let variances = tcx.variances_of(item.owner_id);
+    let variances = tcx.variances_of(def_id);
 
     let mut constrained_parameters: FxHashSet<_> = variances
         .iter()
@@ -2037,8 +1936,10 @@ fn check_variances_for_type_defn<'tcx>(
 
     // Lazily calculated because it is only needed in case of an error.
     let explicitly_bounded_params = LazyCell::new(|| {
-        let icx = crate::collect::ItemCtxt::new(tcx, item.owner_id.def_id);
-        hir_generics
+        let icx = crate::collect::ItemCtxt::new(tcx, def_id);
+        tcx.hir_node_by_def_id(def_id)
+            .generics()
+            .unwrap()
             .predicates
             .iter()
             .filter_map(|predicate| match predicate.kind {
@@ -2053,8 +1954,6 @@ fn check_variances_for_type_defn<'tcx>(
             .collect::<FxHashSet<_>>()
     });
 
-    let ty_generics = tcx.generics_of(item.owner_id);
-
     for (index, _) in variances.iter().enumerate() {
         let parameter = Parameter(index as u32);
 
@@ -2062,9 +1961,13 @@ fn check_variances_for_type_defn<'tcx>(
             continue;
         }
 
-        let ty_param = &ty_generics.own_params[index];
+        let node = tcx.hir_node_by_def_id(def_id);
+        let item = node.expect_item();
+        let hir_generics = node.generics().unwrap();
         let hir_param = &hir_generics.params[index];
 
+        let ty_param = &tcx.generics_of(item.owner_id).own_params[index];
+
         if ty_param.def_id != hir_param.def_id.into() {
             // Valid programs always have lifetimes before types in the generic parameter list.
             // ty_generics are normalized to be in this required order, and variances are built
@@ -2082,7 +1985,7 @@ fn check_variances_for_type_defn<'tcx>(
 
         // Look for `ErrorGuaranteed` deeply within this type.
         if let ControlFlow::Break(ErrorGuaranteed { .. }) = tcx
-            .type_of(item.owner_id)
+            .type_of(def_id)
             .instantiate_identity()
             .visit_with(&mut HasErrorDeep { tcx, seen: Default::default() })
         {
@@ -2301,7 +2204,7 @@ impl<'tcx> WfCheckingCtxt<'_, 'tcx> {
     #[instrument(level = "debug", skip(self))]
     fn check_false_global_bounds(&mut self) {
         let tcx = self.ocx.infcx.tcx;
-        let mut span = self.span;
+        let mut span = tcx.def_span(self.body_def_id);
         let empty_env = ty::ParamEnv::empty();
 
         let predicates_with_span = tcx.predicates_of(self.body_def_id).predicates.iter().copied();
diff --git a/compiler/rustc_hir_analysis/src/collect.rs b/compiler/rustc_hir_analysis/src/collect.rs
index d756855..b10d5b5 100644
--- a/compiler/rustc_hir_analysis/src/collect.rs
+++ b/compiler/rustc_hir_analysis/src/collect.rs
@@ -277,17 +277,7 @@ fn report_placeholder_type_error(
             }
             _ => self.item_def_id,
         };
-        // FIXME: just invoke `tcx.def_descr` instead of going through the HIR
-        // Can also remove most `descr` methods then.
-        let kind = match self.tcx.hir_node_by_def_id(kind_id) {
-            Node::Item(it) => it.kind.descr(),
-            Node::ImplItem(it) => it.kind.descr(),
-            Node::TraitItem(it) => it.kind.descr(),
-            Node::ForeignItem(it) => it.kind.descr(),
-            Node::OpaqueTy(_) => "opaque type",
-            Node::Synthetic => self.tcx.def_descr(kind_id.into()),
-            node => todo!("{node:#?}"),
-        };
+        let kind = self.tcx.def_descr(kind_id.into());
         let mut diag = placeholder_type_error_diag(
             self,
             generics,
@@ -615,159 +605,13 @@ fn get_new_lifetime_name<'tcx>(
     (1..).flat_map(a_to_z_repeat_n).find(|lt| !existing_lifetimes.contains(lt.as_str())).unwrap()
 }
 
-#[instrument(level = "debug", skip_all)]
-pub(super) fn lower_item(tcx: TyCtxt<'_>, item_id: hir::ItemId) {
-    let it = tcx.hir_item(item_id);
-    debug!(item = ?it.kind.ident(), id = %it.hir_id());
-    let def_id = item_id.owner_id.def_id;
-
-    match &it.kind {
-        // These don't define types.
-        hir::ItemKind::ExternCrate(..)
-        | hir::ItemKind::Use(..)
-        | hir::ItemKind::Macro(..)
-        | hir::ItemKind::Mod(..)
-        | hir::ItemKind::GlobalAsm { .. } => {}
-        hir::ItemKind::ForeignMod { items, .. } => {
-            for item in *items {
-                let item = tcx.hir_foreign_item(item.id);
-                tcx.ensure_ok().generics_of(item.owner_id);
-                tcx.ensure_ok().type_of(item.owner_id);
-                tcx.ensure_ok().predicates_of(item.owner_id);
-                if tcx.is_conditionally_const(def_id) {
-                    tcx.ensure_ok().explicit_implied_const_bounds(def_id);
-                    tcx.ensure_ok().const_conditions(def_id);
-                }
-                match item.kind {
-                    hir::ForeignItemKind::Fn(..) => {
-                        tcx.ensure_ok().codegen_fn_attrs(item.owner_id);
-                        tcx.ensure_ok().fn_sig(item.owner_id)
-                    }
-                    hir::ForeignItemKind::Static(..) => {
-                        tcx.ensure_ok().codegen_fn_attrs(item.owner_id);
-                    }
-                    _ => (),
-                }
-            }
-        }
-        hir::ItemKind::Enum(..) => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.ensure_ok().type_of(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-            lower_enum_variant_types(tcx, def_id.to_def_id());
-        }
-        hir::ItemKind::Impl { .. } => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.ensure_ok().type_of(def_id);
-            tcx.ensure_ok().impl_trait_header(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-            tcx.ensure_ok().associated_items(def_id);
-        }
-        hir::ItemKind::Trait(..) => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.ensure_ok().trait_def(def_id);
-            tcx.at(it.span).explicit_super_predicates_of(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-            tcx.ensure_ok().associated_items(def_id);
-        }
-        hir::ItemKind::TraitAlias(..) => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.at(it.span).explicit_implied_predicates_of(def_id);
-            tcx.at(it.span).explicit_super_predicates_of(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-        }
-        hir::ItemKind::Struct(_, _, struct_def) | hir::ItemKind::Union(_, _, struct_def) => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.ensure_ok().type_of(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-
-            for f in struct_def.fields() {
-                tcx.ensure_ok().generics_of(f.def_id);
-                tcx.ensure_ok().type_of(f.def_id);
-                tcx.ensure_ok().predicates_of(f.def_id);
-            }
-
-            if let Some(ctor_def_id) = struct_def.ctor_def_id() {
-                lower_variant_ctor(tcx, ctor_def_id);
-            }
-        }
-
-        hir::ItemKind::TyAlias(..) => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.ensure_ok().type_of(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-        }
-
-        hir::ItemKind::Static(..) | hir::ItemKind::Const(..) => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.ensure_ok().type_of(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-        }
-
-        hir::ItemKind::Fn { .. } => {
-            tcx.ensure_ok().generics_of(def_id);
-            tcx.ensure_ok().type_of(def_id);
-            tcx.ensure_ok().predicates_of(def_id);
-            tcx.ensure_ok().fn_sig(def_id);
-            tcx.ensure_ok().codegen_fn_attrs(def_id);
-        }
-    }
-}
-
-pub(crate) fn lower_trait_item(tcx: TyCtxt<'_>, trait_item_id: hir::TraitItemId) {
-    let trait_item = tcx.hir_trait_item(trait_item_id);
-    let def_id = trait_item_id.owner_id;
-    tcx.ensure_ok().generics_of(def_id);
-
-    match trait_item.kind {
-        hir::TraitItemKind::Fn(..) => {
-            tcx.ensure_ok().codegen_fn_attrs(def_id);
-            tcx.ensure_ok().type_of(def_id);
-            tcx.ensure_ok().fn_sig(def_id);
-        }
-
-        hir::TraitItemKind::Const(..) => {
-            tcx.ensure_ok().type_of(def_id);
-        }
-
-        hir::TraitItemKind::Type(_, Some(_)) => {
-            tcx.ensure_ok().item_bounds(def_id);
-            tcx.ensure_ok().item_self_bounds(def_id);
-            tcx.ensure_ok().type_of(def_id);
-        }
-
-        hir::TraitItemKind::Type(_, None) => {
-            tcx.ensure_ok().item_bounds(def_id);
-            tcx.ensure_ok().item_self_bounds(def_id);
-        }
-    };
-
-    tcx.ensure_ok().predicates_of(def_id);
-}
-
-pub(super) fn lower_impl_item(tcx: TyCtxt<'_>, impl_item_id: hir::ImplItemId) {
-    let def_id = impl_item_id.owner_id;
-    tcx.ensure_ok().generics_of(def_id);
-    tcx.ensure_ok().type_of(def_id);
-    tcx.ensure_ok().predicates_of(def_id);
-    let impl_item = tcx.hir_impl_item(impl_item_id);
-    match impl_item.kind {
-        hir::ImplItemKind::Fn(..) => {
-            tcx.ensure_ok().codegen_fn_attrs(def_id);
-            tcx.ensure_ok().fn_sig(def_id);
-        }
-        hir::ImplItemKind::Type(_) => {}
-        hir::ImplItemKind::Const(..) => {}
-    }
-}
-
-fn lower_variant_ctor(tcx: TyCtxt<'_>, def_id: LocalDefId) {
+pub(super) fn lower_variant_ctor(tcx: TyCtxt<'_>, def_id: LocalDefId) {
     tcx.ensure_ok().generics_of(def_id);
     tcx.ensure_ok().type_of(def_id);
     tcx.ensure_ok().predicates_of(def_id);
 }
 
-fn lower_enum_variant_types(tcx: TyCtxt<'_>, def_id: DefId) {
+pub(super) fn lower_enum_variant_types(tcx: TyCtxt<'_>, def_id: DefId) {
     let def = tcx.adt_def(def_id);
     let repr_type = def.repr().discr_type();
     let initial = repr_type.initial_discriminant(tcx);
diff --git a/compiler/rustc_hir_analysis/src/hir_ty_lowering/mod.rs b/compiler/rustc_hir_analysis/src/hir_ty_lowering/mod.rs
index 7473935..6b2854d 100644
--- a/compiler/rustc_hir_analysis/src/hir_ty_lowering/mod.rs
+++ b/compiler/rustc_hir_analysis/src/hir_ty_lowering/mod.rs
@@ -2364,9 +2364,9 @@ fn try_lower_anon_const_lit(
         };
 
         let lit_input = match expr.kind {
-            hir::ExprKind::Lit(lit) => Some(LitToConstInput { lit: &lit.node, ty, neg: false }),
+            hir::ExprKind::Lit(lit) => Some(LitToConstInput { lit: lit.node, ty, neg: false }),
             hir::ExprKind::Unary(hir::UnOp::Neg, expr) => match expr.kind {
-                hir::ExprKind::Lit(lit) => Some(LitToConstInput { lit: &lit.node, ty, neg: true }),
+                hir::ExprKind::Lit(lit) => Some(LitToConstInput { lit: lit.node, ty, neg: true }),
                 _ => None,
             },
             _ => None,
@@ -2433,7 +2433,6 @@ pub fn lower_ty(&self, hir_ty: &hir::Ty<'tcx>) -> Ty<'tcx> {
                 } else {
                     let repr = match repr {
                         TraitObjectSyntax::Dyn | TraitObjectSyntax::None => ty::Dyn,
-                        TraitObjectSyntax::DynStar => ty::DynStar,
                     };
                     self.lower_trait_object_ty(hir_ty.span, hir_ty.hir_id, bounds, lifetime, repr)
                 }
diff --git a/compiler/rustc_hir_pretty/src/lib.rs b/compiler/rustc_hir_pretty/src/lib.rs
index 087167d..c523a03 100644
--- a/compiler/rustc_hir_pretty/src/lib.rs
+++ b/compiler/rustc_hir_pretty/src/lib.rs
@@ -420,7 +420,6 @@ fn print_type(&mut self, ty: &hir::Ty<'_>) {
                 let syntax = lifetime.tag();
                 match syntax {
                     ast::TraitObjectSyntax::Dyn => self.word_nbsp("dyn"),
-                    ast::TraitObjectSyntax::DynStar => self.word_nbsp("dyn*"),
                     ast::TraitObjectSyntax::None => {}
                 }
                 let mut first = true;
@@ -1480,7 +1479,7 @@ fn print_expr(&mut self, expr: &hir::Expr<'_>) {
                 self.print_expr_addr_of(k, m, expr);
             }
             hir::ExprKind::Lit(lit) => {
-                self.print_literal(lit);
+                self.print_literal(&lit);
             }
             hir::ExprKind::Cast(expr, ty) => {
                 self.print_expr_cond_paren(expr, self.precedence(expr) < ExprPrecedence::Cast);
diff --git a/compiler/rustc_hir_typeck/src/cast.rs b/compiler/rustc_hir_typeck/src/cast.rs
index 6f8abc1..3eeb0ea 100644
--- a/compiler/rustc_hir_typeck/src/cast.rs
+++ b/compiler/rustc_hir_typeck/src/cast.rs
@@ -143,7 +143,6 @@ fn pointer_kind(
             | ty::Coroutine(..)
             | ty::Adt(..)
             | ty::Never
-            | ty::Dynamic(_, _, ty::DynStar)
             | ty::Error(_) => {
                 let guar = self
                     .dcx()
@@ -734,14 +733,6 @@ fn do_check(&self, fcx: &FnCtxt<'a, 'tcx>) -> Result<CastKind, CastError<'tcx>>
         use rustc_middle::ty::cast::CastTy::*;
         use rustc_middle::ty::cast::IntTy::*;
 
-        if self.cast_ty.is_dyn_star() {
-            // This coercion will fail if the feature is not enabled, OR
-            // if the coercion is (currently) illegal (e.g. `dyn* Foo + Send`
-            // to `dyn* Foo`). Report "casting is invalid" rather than
-            // "non-primitive cast".
-            return Err(CastError::IllegalCast);
-        }
-
         let (t_from, t_cast) = match (CastTy::from_ty(self.expr_ty), CastTy::from_ty(self.cast_ty))
         {
             (Some(t_from), Some(t_cast)) => (t_from, t_cast),
diff --git a/compiler/rustc_hir_typeck/src/coercion.rs b/compiler/rustc_hir_typeck/src/coercion.rs
index 6fa473d..3ca04ba 100644
--- a/compiler/rustc_hir_typeck/src/coercion.rs
+++ b/compiler/rustc_hir_typeck/src/coercion.rs
@@ -231,9 +231,6 @@ fn coerce(&self, a: Ty<'tcx>, b: Ty<'tcx>) -> CoerceResult<'tcx> {
             ty::Ref(r_b, _, mutbl_b) => {
                 return self.coerce_borrowed_pointer(a, b, r_b, mutbl_b);
             }
-            ty::Dynamic(predicates, region, ty::DynStar) if self.tcx.features().dyn_star() => {
-                return self.coerce_dyn_star(a, b, predicates, region);
-            }
             ty::Adt(pin, _)
                 if self.tcx.features().pin_ergonomics()
                     && self.tcx.is_lang_item(pin.did(), hir::LangItem::Pin) =>
@@ -278,8 +275,8 @@ fn coerce(&self, a: Ty<'tcx>, b: Ty<'tcx>) -> CoerceResult<'tcx> {
     /// fall back to subtyping (`unify_and`).
     fn coerce_from_inference_variable(&self, a: Ty<'tcx>, b: Ty<'tcx>) -> CoerceResult<'tcx> {
         debug!("coerce_from_inference_variable(a={:?}, b={:?})", a, b);
-        assert!(a.is_ty_var() && self.shallow_resolve(a) == a);
-        assert!(self.shallow_resolve(b) == b);
+        debug_assert!(a.is_ty_var() && self.shallow_resolve(a) == a);
+        debug_assert!(self.shallow_resolve(b) == b);
 
         if b.is_ty_var() {
             // Two unresolved type variables: create a `Coerce` predicate.
@@ -323,6 +320,8 @@ fn coerce_borrowed_pointer(
         mutbl_b: hir::Mutability,
     ) -> CoerceResult<'tcx> {
         debug!("coerce_borrowed_pointer(a={:?}, b={:?})", a, b);
+        debug_assert!(self.shallow_resolve(a) == a);
+        debug_assert!(self.shallow_resolve(b) == b);
 
         // If we have a parameter of type `&M T_a` and the value
         // provided is `expr`, we will be adding an implicit borrow,
@@ -514,10 +513,10 @@ fn coerce_borrowed_pointer(
     ///
     /// [unsized coercion](https://doc.rust-lang.org/reference/type-coercions.html#unsized-coercions)
     #[instrument(skip(self), level = "debug")]
-    fn coerce_unsized(&self, mut source: Ty<'tcx>, mut target: Ty<'tcx>) -> CoerceResult<'tcx> {
-        source = self.shallow_resolve(source);
-        target = self.shallow_resolve(target);
+    fn coerce_unsized(&self, source: Ty<'tcx>, target: Ty<'tcx>) -> CoerceResult<'tcx> {
         debug!(?source, ?target);
+        debug_assert!(self.shallow_resolve(source) == source);
+        debug_assert!(self.shallow_resolve(target) == target);
 
         // We don't apply any coercions incase either the source or target
         // aren't sufficiently well known but tend to instead just equate
@@ -531,6 +530,54 @@ fn coerce_unsized(&self, mut source: Ty<'tcx>, mut target: Ty<'tcx>) -> CoerceRe
             return Err(TypeError::Mismatch);
         }
 
+        // This is an optimization because coercion is one of the most common
+        // operations that we do in typeck, since it happens at every assignment
+        // and call arg (among other positions).
+        //
+        // These targets are known to never be RHS in `LHS: CoerceUnsized<RHS>`.
+        // That's because these are built-in types for which a core-provided impl
+        // doesn't exist, and for which a user-written impl is invalid.
+        //
+        // This is technically incomplete when users write impossible bounds like
+        // `where T: CoerceUnsized<usize>`, for example, but that trait is unstable
+        // and coercion is allowed to be incomplete. The only case where this matters
+        // is impossible bounds.
+        //
+        // Note that some of these types implement `LHS: Unsize<RHS>`, but they
+        // do not implement *`CoerceUnsized`* which is the root obligation of the
+        // check below.
+        match target.kind() {
+            ty::Bool
+            | ty::Char
+            | ty::Int(_)
+            | ty::Uint(_)
+            | ty::Float(_)
+            | ty::Infer(ty::IntVar(_) | ty::FloatVar(_))
+            | ty::Str
+            | ty::Array(_, _)
+            | ty::Slice(_)
+            | ty::FnDef(_, _)
+            | ty::FnPtr(_, _)
+            | ty::Dynamic(_, _, _)
+            | ty::Closure(_, _)
+            | ty::CoroutineClosure(_, _)
+            | ty::Coroutine(_, _)
+            | ty::CoroutineWitness(_, _)
+            | ty::Never
+            | ty::Tuple(_) => return Err(TypeError::Mismatch),
+            _ => {}
+        }
+        // Additionally, we ignore `&str -> &str` coercions, which happen very
+        // commonly since strings are one of the most used argument types in Rust,
+        // we do coercions when type checking call expressions.
+        if let ty::Ref(_, source_pointee, ty::Mutability::Not) = *source.kind()
+            && source_pointee.is_str()
+            && let ty::Ref(_, target_pointee, ty::Mutability::Not) = *target.kind()
+            && target_pointee.is_str()
+        {
+            return Err(TypeError::Mismatch);
+        }
+
         let traits =
             (self.tcx.lang_items().unsize_trait(), self.tcx.lang_items().coerce_unsized_trait());
         let (Some(unsize_did), Some(coerce_unsized_did)) = traits else {
@@ -723,71 +770,6 @@ fn coerce_unsized(&self, mut source: Ty<'tcx>, mut target: Ty<'tcx>) -> CoerceRe
         Ok(coercion)
     }
 
-    fn coerce_dyn_star(
-        &self,
-        a: Ty<'tcx>,
-        b: Ty<'tcx>,
-        predicates: &'tcx ty::List<ty::PolyExistentialPredicate<'tcx>>,
-        b_region: ty::Region<'tcx>,
-    ) -> CoerceResult<'tcx> {
-        if !self.tcx.features().dyn_star() {
-            return Err(TypeError::Mismatch);
-        }
-
-        // FIXME(dyn_star): We should probably allow things like casting from
-        // `dyn* Foo + Send` to `dyn* Foo`.
-        if let ty::Dynamic(a_data, _, ty::DynStar) = a.kind()
-            && let ty::Dynamic(b_data, _, ty::DynStar) = b.kind()
-            && a_data.principal_def_id() == b_data.principal_def_id()
-        {
-            return self.unify(a, b);
-        }
-
-        // Check the obligations of the cast -- for example, when casting
-        // `usize` to `dyn* Clone + 'static`:
-        let obligations = predicates
-            .iter()
-            .map(|predicate| {
-                // For each existential predicate (e.g., `?Self: Clone`) instantiate
-                // the type of the expression (e.g., `usize` in our example above)
-                // and then require that the resulting predicate (e.g., `usize: Clone`)
-                // holds (it does).
-                let predicate = predicate.with_self_ty(self.tcx, a);
-                Obligation::new(self.tcx, self.cause.clone(), self.param_env, predicate)
-            })
-            .chain([
-                // Enforce the region bound (e.g., `usize: 'static`, in our example).
-                Obligation::new(
-                    self.tcx,
-                    self.cause.clone(),
-                    self.param_env,
-                    ty::Binder::dummy(ty::PredicateKind::Clause(ty::ClauseKind::TypeOutlives(
-                        ty::OutlivesPredicate(a, b_region),
-                    ))),
-                ),
-                // Enforce that the type is `usize`/pointer-sized.
-                Obligation::new(
-                    self.tcx,
-                    self.cause.clone(),
-                    self.param_env,
-                    ty::TraitRef::new(
-                        self.tcx,
-                        self.tcx.require_lang_item(hir::LangItem::PointerLike, self.cause.span),
-                        [a],
-                    ),
-                ),
-            ])
-            .collect();
-
-        Ok(InferOk {
-            value: (
-                vec![Adjustment { kind: Adjust::Pointer(PointerCoercion::DynStar), target: b }],
-                b,
-            ),
-            obligations,
-        })
-    }
-
     /// Applies reborrowing for `Pin`
     ///
     /// We currently only support reborrowing `Pin<&mut T>` as `Pin<&mut T>`. This is accomplished
@@ -800,6 +782,9 @@ fn coerce_dyn_star(
     /// - `Pin<Box<T>>` as `Pin<&mut T>`
     #[instrument(skip(self), level = "trace")]
     fn coerce_pin_ref(&self, a: Ty<'tcx>, b: Ty<'tcx>) -> CoerceResult<'tcx> {
+        debug_assert!(self.shallow_resolve(a) == a);
+        debug_assert!(self.shallow_resolve(b) == b);
+
         // We need to make sure the two types are compatible for coercion.
         // Then we will build a ReborrowPin adjustment and return that as an InferOk.
 
@@ -848,6 +833,8 @@ fn coerce_from_safe_fn(
         b: Ty<'tcx>,
         adjustment: Option<Adjust>,
     ) -> CoerceResult<'tcx> {
+        debug_assert!(self.shallow_resolve(b) == b);
+
         self.commit_if_ok(|snapshot| {
             let outer_universe = self.infcx.universe();
 
@@ -888,24 +875,19 @@ fn coerce_from_fn_pointer(
         fn_ty_a: ty::PolyFnSig<'tcx>,
         b: Ty<'tcx>,
     ) -> CoerceResult<'tcx> {
-        //! Attempts to coerce from the type of a Rust function item
-        //! into a closure or a `proc`.
-        //!
-
-        let b = self.shallow_resolve(b);
         debug!(?fn_ty_a, ?b, "coerce_from_fn_pointer");
+        debug_assert!(self.shallow_resolve(b) == b);
 
         self.coerce_from_safe_fn(fn_ty_a, b, None)
     }
 
     fn coerce_from_fn_item(&self, a: Ty<'tcx>, b: Ty<'tcx>) -> CoerceResult<'tcx> {
-        //! Attempts to coerce from the type of a Rust function item
-        //! into a closure or a `proc`.
+        debug!("coerce_from_fn_item(a={:?}, b={:?})", a, b);
+        debug_assert!(self.shallow_resolve(a) == a);
+        debug_assert!(self.shallow_resolve(b) == b);
 
-        let b = self.shallow_resolve(b);
         let InferOk { value: b, mut obligations } =
             self.at(&self.cause, self.param_env).normalize(b);
-        debug!("coerce_from_fn_item(a={:?}, b={:?})", a, b);
 
         match b.kind() {
             ty::FnPtr(_, b_hdr) => {
@@ -955,6 +937,8 @@ fn coerce_from_fn_item(&self, a: Ty<'tcx>, b: Ty<'tcx>) -> CoerceResult<'tcx> {
         }
     }
 
+    /// Attempts to coerce from the type of a non-capturing closure
+    /// into a function pointer.
     fn coerce_closure_to_fn(
         &self,
         a: Ty<'tcx>,
@@ -962,11 +946,8 @@ fn coerce_closure_to_fn(
         args_a: GenericArgsRef<'tcx>,
         b: Ty<'tcx>,
     ) -> CoerceResult<'tcx> {
-        //! Attempts to coerce from the type of a non-capturing closure
-        //! into a function pointer.
-        //!
-
-        let b = self.shallow_resolve(b);
+        debug_assert!(self.shallow_resolve(a) == a);
+        debug_assert!(self.shallow_resolve(b) == b);
 
         match b.kind() {
             // At this point we haven't done capture analysis, which means
@@ -1010,6 +991,8 @@ fn coerce_raw_ptr(
         mutbl_b: hir::Mutability,
     ) -> CoerceResult<'tcx> {
         debug!("coerce_raw_ptr(a={:?}, b={:?})", a, b);
+        debug_assert!(self.shallow_resolve(a) == a);
+        debug_assert!(self.shallow_resolve(b) == b);
 
         let (is_ref, mt_a) = match *a.kind() {
             ty::Ref(_, ty, mutbl) => (true, ty::TypeAndMut { ty, mutbl }),
diff --git a/compiler/rustc_hir_typeck/src/fn_ctxt/checks.rs b/compiler/rustc_hir_typeck/src/fn_ctxt/checks.rs
index c7b9cb4..3c53a06 100644
--- a/compiler/rustc_hir_typeck/src/fn_ctxt/checks.rs
+++ b/compiler/rustc_hir_typeck/src/fn_ctxt/checks.rs
@@ -1637,7 +1637,7 @@ pub(in super::super) fn check_expr_lit(
             ast::LitKind::ByteStr(ref v, _) => Ty::new_imm_ref(
                 tcx,
                 tcx.lifetimes.re_static,
-                Ty::new_array(tcx, tcx.types.u8, v.len() as u64),
+                Ty::new_array(tcx, tcx.types.u8, v.as_byte_str().len() as u64),
             ),
             ast::LitKind::Byte(_) => tcx.types.u8,
             ast::LitKind::Char(_) => tcx.types.char,
diff --git a/compiler/rustc_hir_typeck/src/fn_ctxt/suggestions.rs b/compiler/rustc_hir_typeck/src/fn_ctxt/suggestions.rs
index 7e5f1d9..dd6eb73 100644
--- a/compiler/rustc_hir_typeck/src/fn_ctxt/suggestions.rs
+++ b/compiler/rustc_hir_typeck/src/fn_ctxt/suggestions.rs
@@ -1624,7 +1624,7 @@ pub(crate) fn suggest_floating_point_literal(
                 node: rustc_ast::LitKind::Int(lit, rustc_ast::LitIntType::Unsuffixed),
                 span,
             }) => {
-                let Ok(snippet) = self.tcx.sess.source_map().span_to_snippet(*span) else {
+                let Ok(snippet) = self.tcx.sess.source_map().span_to_snippet(span) else {
                     return false;
                 };
                 if !(snippet.starts_with("0x") || snippet.starts_with("0X")) {
@@ -1683,7 +1683,7 @@ pub(crate) fn suggest_null_ptr_for_literal_zero_given_to_ptr_arg(
 
         // We have satisfied all requirements to provide a suggestion. Emit it.
         err.span_suggestion(
-            *span,
+            span,
             format!("if you meant to create a null pointer, use `{null_path_str}()`"),
             null_path_str + "()",
             Applicability::MachineApplicable,
diff --git a/compiler/rustc_hir_typeck/src/method/suggest.rs b/compiler/rustc_hir_typeck/src/method/suggest.rs
index d0a4887..df1ee0e 100644
--- a/compiler/rustc_hir_typeck/src/method/suggest.rs
+++ b/compiler/rustc_hir_typeck/src/method/suggest.rs
@@ -3055,7 +3055,7 @@ fn suggest_unwrapping_inner_self(
     pub(crate) fn note_unmet_impls_on_type(
         &self,
         err: &mut Diag<'_>,
-        errors: Vec<FulfillmentError<'tcx>>,
+        errors: &[FulfillmentError<'tcx>],
         suggest_derive: bool,
     ) {
         let preds: Vec<_> = errors
diff --git a/compiler/rustc_hir_typeck/src/op.rs b/compiler/rustc_hir_typeck/src/op.rs
index b9d2450..87a7cd6 100644
--- a/compiler/rustc_hir_typeck/src/op.rs
+++ b/compiler/rustc_hir_typeck/src/op.rs
@@ -322,7 +322,7 @@ fn check_overloaded_binop(
                             lhs_expr.span,
                             format!("cannot use `{}` on type `{}`", s, lhs_ty_str),
                         );
-                        self.note_unmet_impls_on_type(&mut err, errors, false);
+                        self.note_unmet_impls_on_type(&mut err, &errors, false);
                         (err, None)
                     }
                     Op::BinOp(bin_op) => {
@@ -382,7 +382,7 @@ fn check_overloaded_binop(
                             err.span_label(rhs_expr.span, rhs_ty_str);
                         }
                         let suggest_derive = self.can_eq(self.param_env, lhs_ty, rhs_ty);
-                        self.note_unmet_impls_on_type(&mut err, errors, suggest_derive);
+                        self.note_unmet_impls_on_type(&mut err, &errors, suggest_derive);
                         (err, output_def_id)
                     }
                 };
@@ -582,22 +582,6 @@ fn check_overloaded_binop(
                         // concatenation (e.g., "Hello " + "World!"). This means
                         // we don't want the note in the else clause to be emitted
                     } else if lhs_ty.has_non_region_param() {
-                        // Look for a TraitPredicate in the Fulfillment errors,
-                        // and use it to generate a suggestion.
-                        //
-                        // Note that lookup_op_method must be called again but
-                        // with a specific rhs_ty instead of a placeholder so
-                        // the resulting predicate generates a more specific
-                        // suggestion for the user.
-                        let errors = self
-                            .lookup_op_method(
-                                (lhs_expr, lhs_ty),
-                                Some((rhs_expr, rhs_ty)),
-                                lang_item_for_binop(self.tcx, op),
-                                op.span(),
-                                expected,
-                            )
-                            .unwrap_err();
                         if !errors.is_empty() {
                             for error in errors {
                                 if let Some(trait_pred) =
@@ -946,7 +930,7 @@ pub(crate) fn check_user_unop(
                             ty::Str | ty::Never | ty::Char | ty::Tuple(_) | ty::Array(_, _) => {}
                             ty::Ref(_, lty, _) if *lty.kind() == ty::Str => {}
                             _ => {
-                                self.note_unmet_impls_on_type(&mut err, errors, true);
+                                self.note_unmet_impls_on_type(&mut err, &errors, true);
                             }
                         }
                     }
diff --git a/compiler/rustc_infer/src/infer/freshen.rs b/compiler/rustc_infer/src/infer/freshen.rs
index cae6741..ddc0b11 100644
--- a/compiler/rustc_infer/src/infer/freshen.rs
+++ b/compiler/rustc_infer/src/infer/freshen.rs
@@ -110,17 +110,16 @@ fn cx(&self) -> TyCtxt<'tcx> {
 
     fn fold_region(&mut self, r: ty::Region<'tcx>) -> ty::Region<'tcx> {
         match r.kind() {
-            ty::ReBound(..) => {
-                // leave bound regions alone
-                r
-            }
+            // Leave bound regions alone, since they affect selection via the leak check.
+            ty::ReBound(..) => r,
+            // Leave error regions alone, since they affect selection b/c of incompleteness.
+            ty::ReError(_) => r,
 
             ty::ReEarlyParam(..)
             | ty::ReLateParam(_)
             | ty::ReVar(_)
             | ty::RePlaceholder(..)
             | ty::ReStatic
-            | ty::ReError(_)
             | ty::ReErased => self.cx().lifetimes.re_erased,
         }
     }
diff --git a/compiler/rustc_infer/src/lib.rs b/compiler/rustc_infer/src/lib.rs
index 18cee03..285e291 100644
--- a/compiler/rustc_infer/src/lib.rs
+++ b/compiler/rustc_infer/src/lib.rs
@@ -15,8 +15,8 @@
 // tidy-alphabetical-start
 #![allow(internal_features)]
 #![allow(rustc::diagnostic_outside_of_impl)]
+#![allow(rustc::direct_use_of_rustc_type_ir)]
 #![allow(rustc::untranslatable_diagnostic)]
-#![cfg_attr(not(bootstrap), allow(rustc::direct_use_of_rustc_type_ir))]
 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
 #![doc(rust_logo)]
 #![feature(assert_matches)]
diff --git a/compiler/rustc_interface/src/passes.rs b/compiler/rustc_interface/src/passes.rs
index edfb05e..3fe7c5e 100644
--- a/compiler/rustc_interface/src/passes.rs
+++ b/compiler/rustc_interface/src/passes.rs
@@ -298,6 +298,16 @@ fn configure_and_expand(
 fn print_macro_stats(ecx: &ExtCtxt<'_>) {
     use std::fmt::Write;
 
+    let crate_name = ecx.ecfg.crate_name.as_str();
+    let crate_name = if crate_name == "build_script_build" {
+        // This is a build script. Get the package name from the environment.
+        let pkg_name =
+            std::env::var("CARGO_PKG_NAME").unwrap_or_else(|_| "<unknown crate>".to_string());
+        format!("{pkg_name} build script")
+    } else {
+        crate_name.to_string()
+    };
+
     // No instability because we immediately sort the produced vector.
     #[allow(rustc::potential_query_instability)]
     let mut macro_stats: Vec<_> = ecx
@@ -327,7 +337,7 @@ fn print_macro_stats(ecx: &ExtCtxt<'_>) {
     // non-interleaving, though.
     let mut s = String::new();
     _ = writeln!(s, "{prefix} {}", "=".repeat(banner_w));
-    _ = writeln!(s, "{prefix} MACRO EXPANSION STATS: {}", ecx.ecfg.crate_name);
+    _ = writeln!(s, "{prefix} MACRO EXPANSION STATS: {}", crate_name);
     _ = writeln!(
         s,
         "{prefix} {:<name_w$}{:>uses_w$}{:>lines_w$}{:>avg_lines_w$}{:>bytes_w$}{:>avg_bytes_w$}",
@@ -341,20 +351,30 @@ fn print_macro_stats(ecx: &ExtCtxt<'_>) {
     }
     for (bytes, lines, uses, name, kind) in macro_stats {
         let mut name = ExpnKind::Macro(kind, *name).descr();
+        let uses_with_underscores = thousands::usize_with_underscores(uses);
         let avg_lines = lines as f64 / uses as f64;
         let avg_bytes = bytes as f64 / uses as f64;
-        if name.len() >= name_w {
-            // If the name is long, print it on a line by itself, then
-            // set the name to empty and print things normally, to show the
-            // stats on the next line.
+
+        // Ensure the "Macro Name" and "Uses" columns are as compact as possible.
+        let mut uses_w = uses_w;
+        if name.len() + uses_with_underscores.len() >= name_w + uses_w {
+            // The name would abut or overlap the uses value. Print the name
+            // on a line by itself, then set the name to empty and print things
+            // normally, to show the stats on the next line.
             _ = writeln!(s, "{prefix} {:<name_w$}", name);
             name = String::new();
-        }
+        } else if name.len() >= name_w {
+            // The name won't abut or overlap with the uses value, but it does
+            // overlap with the empty part of the uses column. Shrink the width
+            // of the uses column to account for the excess name length.
+            uses_w = uses_with_underscores.len() + 1
+        };
+
         _ = writeln!(
             s,
             "{prefix} {:<name_w$}{:>uses_w$}{:>lines_w$}{:>avg_lines_w$}{:>bytes_w$}{:>avg_bytes_w$}",
             name,
-            thousands::usize_with_underscores(uses),
+            uses_with_underscores,
             thousands::usize_with_underscores(lines),
             thousands::f64p1_with_underscores(avg_lines),
             thousands::usize_with_underscores(bytes),
diff --git a/compiler/rustc_lint/src/invalid_from_utf8.rs b/compiler/rustc_lint/src/invalid_from_utf8.rs
index 11eb079..41b670c 100644
--- a/compiler/rustc_lint/src/invalid_from_utf8.rs
+++ b/compiler/rustc_lint/src/invalid_from_utf8.rs
@@ -108,8 +108,8 @@ fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) {
             }
             match init.kind {
                 ExprKind::Lit(Spanned { node: lit, .. }) => {
-                    if let LitKind::ByteStr(bytes, _) = &lit
-                        && let Err(utf8_error) = std::str::from_utf8(bytes)
+                    if let LitKind::ByteStr(byte_sym, _) = &lit
+                        && let Err(utf8_error) = std::str::from_utf8(byte_sym.as_byte_str())
                     {
                         lint(init.span, utf8_error);
                     }
diff --git a/compiler/rustc_lint/src/late.rs b/compiler/rustc_lint/src/late.rs
index 852bb01..c681dee 100644
--- a/compiler/rustc_lint/src/late.rs
+++ b/compiler/rustc_lint/src/late.rs
@@ -152,7 +152,7 @@ fn visit_pat(&mut self, p: &'tcx hir::Pat<'tcx>) {
         hir_visit::walk_pat(self, p);
     }
 
-    fn visit_lit(&mut self, hir_id: HirId, lit: &'tcx hir::Lit, negated: bool) {
+    fn visit_lit(&mut self, hir_id: HirId, lit: hir::Lit, negated: bool) {
         lint_callback!(self, check_lit, hir_id, lit, negated);
     }
 
diff --git a/compiler/rustc_lint/src/passes.rs b/compiler/rustc_lint/src/passes.rs
index 409a23d..affea1b 100644
--- a/compiler/rustc_lint/src/passes.rs
+++ b/compiler/rustc_lint/src/passes.rs
@@ -23,7 +23,7 @@ macro_rules! late_lint_methods {
             fn check_stmt(a: &'tcx rustc_hir::Stmt<'tcx>);
             fn check_arm(a: &'tcx rustc_hir::Arm<'tcx>);
             fn check_pat(a: &'tcx rustc_hir::Pat<'tcx>);
-            fn check_lit(hir_id: rustc_hir::HirId, a: &'tcx rustc_hir::Lit, negated: bool);
+            fn check_lit(hir_id: rustc_hir::HirId, a: rustc_hir::Lit, negated: bool);
             fn check_expr(a: &'tcx rustc_hir::Expr<'tcx>);
             fn check_expr_post(a: &'tcx rustc_hir::Expr<'tcx>);
             fn check_ty(a: &'tcx rustc_hir::Ty<'tcx, rustc_hir::AmbigArg>);
diff --git a/compiler/rustc_lint/src/types.rs b/compiler/rustc_lint/src/types.rs
index aaba0c1..ea5485d8 100644
--- a/compiler/rustc_lint/src/types.rs
+++ b/compiler/rustc_lint/src/types.rs
@@ -547,18 +547,12 @@ fn lint_fn_pointer<'tcx>(
 }
 
 impl<'tcx> LateLintPass<'tcx> for TypeLimits {
-    fn check_lit(
-        &mut self,
-        cx: &LateContext<'tcx>,
-        hir_id: HirId,
-        lit: &'tcx hir::Lit,
-        negated: bool,
-    ) {
+    fn check_lit(&mut self, cx: &LateContext<'tcx>, hir_id: HirId, lit: hir::Lit, negated: bool) {
         if negated {
             self.negated_expr_id = Some(hir_id);
             self.negated_expr_span = Some(lit.span);
         }
-        lint_literal(cx, self, hir_id, lit.span, lit, negated);
+        lint_literal(cx, self, hir_id, lit.span, &lit, negated);
     }
 
     fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx hir::Expr<'tcx>) {
diff --git a/compiler/rustc_metadata/src/rmeta/decoder.rs b/compiler/rustc_metadata/src/rmeta/decoder.rs
index 2696c47..e6aedc6 100644
--- a/compiler/rustc_metadata/src/rmeta/decoder.rs
+++ b/compiler/rustc_metadata/src/rmeta/decoder.rs
@@ -32,7 +32,9 @@
 use rustc_session::config::TargetModifier;
 use rustc_session::cstore::{CrateSource, ExternCrate};
 use rustc_span::hygiene::HygieneDecodeContext;
-use rustc_span::{BytePos, DUMMY_SP, Pos, SpanData, SpanDecoder, SyntaxContext, kw};
+use rustc_span::{
+    BytePos, ByteSymbol, DUMMY_SP, Pos, SpanData, SpanDecoder, Symbol, SyntaxContext, kw,
+};
 use tracing::debug;
 
 use crate::creader::CStore;
@@ -384,6 +386,28 @@ fn read_lazy_table<I, T>(&mut self, width: usize, len: usize) -> LazyTable<I, T>
     fn read_raw_bytes(&mut self, len: usize) -> &[u8] {
         self.opaque.read_raw_bytes(len)
     }
+
+    fn decode_symbol_or_byte_symbol<S>(
+        &mut self,
+        new_from_index: impl Fn(u32) -> S,
+        read_and_intern_str_or_byte_str_this: impl Fn(&mut Self) -> S,
+        read_and_intern_str_or_byte_str_opaque: impl Fn(&mut MemDecoder<'a>) -> S,
+    ) -> S {
+        let tag = self.read_u8();
+
+        match tag {
+            SYMBOL_STR => read_and_intern_str_or_byte_str_this(self),
+            SYMBOL_OFFSET => {
+                // read str offset
+                let pos = self.read_usize();
+
+                // move to str offset and read
+                self.opaque.with_position(pos, |d| read_and_intern_str_or_byte_str_opaque(d))
+            }
+            SYMBOL_PREDEFINED => new_from_index(self.read_u32()),
+            _ => unreachable!(),
+        }
+    }
 }
 
 impl<'a, 'tcx> TyDecoder<'tcx> for DecodeContext<'a, 'tcx> {
@@ -545,29 +569,19 @@ fn decode_span(&mut self) -> Span {
     }
 
     fn decode_symbol(&mut self) -> Symbol {
-        let tag = self.read_u8();
+        self.decode_symbol_or_byte_symbol(
+            Symbol::new,
+            |this| Symbol::intern(this.read_str()),
+            |opaque| Symbol::intern(opaque.read_str()),
+        )
+    }
 
-        match tag {
-            SYMBOL_STR => {
-                let s = self.read_str();
-                Symbol::intern(s)
-            }
-            SYMBOL_OFFSET => {
-                // read str offset
-                let pos = self.read_usize();
-
-                // move to str offset and read
-                self.opaque.with_position(pos, |d| {
-                    let s = d.read_str();
-                    Symbol::intern(s)
-                })
-            }
-            SYMBOL_PREDEFINED => {
-                let symbol_index = self.read_u32();
-                Symbol::new(symbol_index)
-            }
-            _ => unreachable!(),
-        }
+    fn decode_byte_symbol(&mut self) -> ByteSymbol {
+        self.decode_symbol_or_byte_symbol(
+            ByteSymbol::new,
+            |this| ByteSymbol::intern(this.read_byte_str()),
+            |opaque| ByteSymbol::intern(opaque.read_byte_str()),
+        )
     }
 }
 
@@ -1496,11 +1510,18 @@ fn get_stable_order_of_exportable_impls(self) -> impl Iterator<Item = (DefId, us
             .map(move |v| (self.local_def_id(v.0), v.1))
     }
 
-    fn exported_symbols<'tcx>(
+    fn exported_non_generic_symbols<'tcx>(
         self,
         tcx: TyCtxt<'tcx>,
     ) -> &'tcx [(ExportedSymbol<'tcx>, SymbolExportInfo)] {
-        tcx.arena.alloc_from_iter(self.root.exported_symbols.decode((self, tcx)))
+        tcx.arena.alloc_from_iter(self.root.exported_non_generic_symbols.decode((self, tcx)))
+    }
+
+    fn exported_generic_symbols<'tcx>(
+        self,
+        tcx: TyCtxt<'tcx>,
+    ) -> &'tcx [(ExportedSymbol<'tcx>, SymbolExportInfo)] {
+        tcx.arena.alloc_from_iter(self.root.exported_generic_symbols.decode((self, tcx)))
     }
 
     fn get_macro(self, id: DefIndex, sess: &Session) -> ast::MacroDef {
diff --git a/compiler/rustc_metadata/src/rmeta/decoder/cstore_impl.rs b/compiler/rustc_metadata/src/rmeta/decoder/cstore_impl.rs
index 375928c..6943d41 100644
--- a/compiler/rustc_metadata/src/rmeta/decoder/cstore_impl.rs
+++ b/compiler/rustc_metadata/src/rmeta/decoder/cstore_impl.rs
@@ -358,7 +358,7 @@ fn into_args(self) -> (DefId, SimplifiedType) {
     specialization_enabled_in => { cdata.root.specialization_enabled_in }
     reachable_non_generics => {
         let reachable_non_generics = tcx
-            .exported_symbols(cdata.cnum)
+            .exported_non_generic_symbols(cdata.cnum)
             .iter()
             .filter_map(|&(exported_symbol, export_info)| {
                 if let ExportedSymbol::NonGeneric(def_id) = exported_symbol {
@@ -408,15 +408,8 @@ fn into_args(self) -> (DefId, SimplifiedType) {
 
     exportable_items => { tcx.arena.alloc_from_iter(cdata.get_exportable_items()) }
     stable_order_of_exportable_impls => { tcx.arena.alloc(cdata.get_stable_order_of_exportable_impls().collect()) }
-    exported_symbols => {
-        let syms = cdata.exported_symbols(tcx);
-
-        // FIXME rust-lang/rust#64319, rust-lang/rust#64872: We want
-        // to block export of generics from dylibs, but we must fix
-        // rust-lang/rust#65890 before we can do that robustly.
-
-        syms
-    }
+    exported_non_generic_symbols => { cdata.exported_non_generic_symbols(tcx) }
+    exported_generic_symbols => { cdata.exported_generic_symbols(tcx) }
 
     crate_extern_paths => { cdata.source().paths().cloned().collect() }
     expn_that_defined => { cdata.get_expn_that_defined(def_id.index, tcx.sess) }
diff --git a/compiler/rustc_metadata/src/rmeta/encoder.rs b/compiler/rustc_metadata/src/rmeta/encoder.rs
index d7491823..90bc427 100644
--- a/compiler/rustc_metadata/src/rmeta/encoder.rs
+++ b/compiler/rustc_metadata/src/rmeta/encoder.rs
@@ -29,8 +29,8 @@
 use rustc_session::config::{CrateType, OptLevel, TargetModifier};
 use rustc_span::hygiene::HygieneEncodeContext;
 use rustc_span::{
-    ExternalSource, FileName, SourceFile, SpanData, SpanEncoder, StableSourceFileId, SyntaxContext,
-    sym,
+    ByteSymbol, ExternalSource, FileName, SourceFile, SpanData, SpanEncoder, StableSourceFileId,
+    Symbol, SyntaxContext, sym,
 };
 use tracing::{debug, instrument, trace};
 
@@ -63,7 +63,8 @@ pub(super) struct EncodeContext<'a, 'tcx> {
     required_source_files: Option<FxIndexSet<usize>>,
     is_proc_macro: bool,
     hygiene_ctxt: &'a HygieneEncodeContext,
-    symbol_table: FxHashMap<Symbol, usize>,
+    // Used for both `Symbol`s and `ByteSymbol`s.
+    symbol_index_table: FxHashMap<u32, usize>,
 }
 
 /// If the current crate is a proc-macro, returns early with `LazyArray::default()`.
@@ -200,27 +201,14 @@ fn encode_span(&mut self, span: Span) {
         }
     }
 
-    fn encode_symbol(&mut self, symbol: Symbol) {
-        // if symbol predefined, emit tag and symbol index
-        if symbol.is_predefined() {
-            self.opaque.emit_u8(SYMBOL_PREDEFINED);
-            self.opaque.emit_u32(symbol.as_u32());
-        } else {
-            // otherwise write it as string or as offset to it
-            match self.symbol_table.entry(symbol) {
-                Entry::Vacant(o) => {
-                    self.opaque.emit_u8(SYMBOL_STR);
-                    let pos = self.opaque.position();
-                    o.insert(pos);
-                    self.emit_str(symbol.as_str());
-                }
-                Entry::Occupied(o) => {
-                    let x = *o.get();
-                    self.emit_u8(SYMBOL_OFFSET);
-                    self.emit_usize(x);
-                }
-            }
-        }
+    fn encode_symbol(&mut self, sym: Symbol) {
+        self.encode_symbol_or_byte_symbol(sym.as_u32(), |this| this.emit_str(sym.as_str()));
+    }
+
+    fn encode_byte_symbol(&mut self, byte_sym: ByteSymbol) {
+        self.encode_symbol_or_byte_symbol(byte_sym.as_u32(), |this| {
+            this.emit_byte_str(byte_sym.as_byte_str())
+        });
     }
 }
 
@@ -492,6 +480,33 @@ fn lazy_array<T: ParameterizedOverTcx, I: IntoIterator<Item = B>, B: Borrow<T::V
         LazyArray::from_position_and_num_elems(pos, len)
     }
 
+    fn encode_symbol_or_byte_symbol(
+        &mut self,
+        index: u32,
+        emit_str_or_byte_str: impl Fn(&mut Self),
+    ) {
+        // if symbol/byte symbol is predefined, emit tag and symbol index
+        if Symbol::is_predefined(index) {
+            self.opaque.emit_u8(SYMBOL_PREDEFINED);
+            self.opaque.emit_u32(index);
+        } else {
+            // otherwise write it as string or as offset to it
+            match self.symbol_index_table.entry(index) {
+                Entry::Vacant(o) => {
+                    self.opaque.emit_u8(SYMBOL_STR);
+                    let pos = self.opaque.position();
+                    o.insert(pos);
+                    emit_str_or_byte_str(self);
+                }
+                Entry::Occupied(o) => {
+                    let x = *o.get();
+                    self.emit_u8(SYMBOL_OFFSET);
+                    self.emit_usize(x);
+                }
+            }
+        }
+    }
+
     fn encode_def_path_table(&mut self) {
         let table = self.tcx.def_path_table();
         if self.is_proc_macro {
@@ -677,9 +692,13 @@ macro_rules! stat {
             stat!("exportable-items", || self.encode_stable_order_of_exportable_impls());
 
         // Encode exported symbols info. This is prefetched in `encode_metadata`.
-        let exported_symbols = stat!("exported-symbols", || {
-            self.encode_exported_symbols(tcx.exported_symbols(LOCAL_CRATE))
-        });
+        let (exported_non_generic_symbols, exported_generic_symbols) =
+            stat!("exported-symbols", || {
+                (
+                    self.encode_exported_symbols(tcx.exported_non_generic_symbols(LOCAL_CRATE)),
+                    self.encode_exported_symbols(tcx.exported_generic_symbols(LOCAL_CRATE)),
+                )
+            });
 
         // Encode the hygiene data.
         // IMPORTANT: this *must* be the last thing that we encode (other than `SourceMap`). The
@@ -745,7 +764,8 @@ macro_rules! stat {
                 incoherent_impls,
                 exportable_items,
                 stable_order_of_exportable_impls,
-                exported_symbols,
+                exported_non_generic_symbols,
+                exported_generic_symbols,
                 interpret_alloc_index,
                 tables,
                 syntax_contexts,
@@ -2360,7 +2380,13 @@ pub fn encode_metadata(tcx: TyCtxt<'_>, path: &Path, ref_path: Option<&Path>) {
         // Prefetch some queries used by metadata encoding.
         // This is not necessary for correctness, but is only done for performance reasons.
         // It can be removed if it turns out to cause trouble or be detrimental to performance.
-        join(|| prefetch_mir(tcx), || tcx.exported_symbols(LOCAL_CRATE));
+        join(
+            || prefetch_mir(tcx),
+            || {
+                let _ = tcx.exported_non_generic_symbols(LOCAL_CRATE);
+                let _ = tcx.exported_generic_symbols(LOCAL_CRATE);
+            },
+        );
     }
 
     with_encode_metadata_header(tcx, path, |ecx| {
@@ -2427,7 +2453,7 @@ fn with_encode_metadata_header(
         required_source_files,
         is_proc_macro: tcx.crate_types().contains(&CrateType::ProcMacro),
         hygiene_ctxt: &hygiene_ctxt,
-        symbol_table: Default::default(),
+        symbol_index_table: Default::default(),
     };
 
     // Encode the rustc version string in a predictable location.
diff --git a/compiler/rustc_metadata/src/rmeta/mod.rs b/compiler/rustc_metadata/src/rmeta/mod.rs
index 0778352..a962a78 100644
--- a/compiler/rustc_metadata/src/rmeta/mod.rs
+++ b/compiler/rustc_metadata/src/rmeta/mod.rs
@@ -282,7 +282,8 @@ pub(crate) struct CrateRoot {
 
     exportable_items: LazyArray<DefIndex>,
     stable_order_of_exportable_impls: LazyArray<(DefIndex, usize)>,
-    exported_symbols: LazyArray<(ExportedSymbol<'static>, SymbolExportInfo)>,
+    exported_non_generic_symbols: LazyArray<(ExportedSymbol<'static>, SymbolExportInfo)>,
+    exported_generic_symbols: LazyArray<(ExportedSymbol<'static>, SymbolExportInfo)>,
 
     syntax_contexts: SyntaxContextTable,
     expn_data: ExpnDataTable,
diff --git a/compiler/rustc_middle/src/lib.rs b/compiler/rustc_middle/src/lib.rs
index b30b9b6..803b645 100644
--- a/compiler/rustc_middle/src/lib.rs
+++ b/compiler/rustc_middle/src/lib.rs
@@ -27,9 +27,8 @@
 // tidy-alphabetical-start
 #![allow(internal_features)]
 #![allow(rustc::diagnostic_outside_of_impl)]
+#![allow(rustc::direct_use_of_rustc_type_ir)]
 #![allow(rustc::untranslatable_diagnostic)]
-#![cfg_attr(not(bootstrap), allow(rustc::direct_use_of_rustc_type_ir))]
-#![cfg_attr(not(bootstrap), feature(sized_hierarchy))]
 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
 #![doc(rust_logo)]
 #![feature(allocator_api)]
@@ -55,6 +54,7 @@
 #![feature(round_char_boundary)]
 #![feature(rustc_attrs)]
 #![feature(rustdoc_internals)]
+#![feature(sized_hierarchy)]
 #![feature(try_blocks)]
 #![feature(try_trait_v2)]
 #![feature(try_trait_v2_yeet)]
diff --git a/compiler/rustc_middle/src/mir/consts.rs b/compiler/rustc_middle/src/mir/consts.rs
index 2b2ffa7..16edc24 100644
--- a/compiler/rustc_middle/src/mir/consts.rs
+++ b/compiler/rustc_middle/src/mir/consts.rs
@@ -168,8 +168,9 @@ pub fn try_get_slice_bytes_for_diagnostics(&self, tcx: TyCtxt<'tcx>) -> Option<&
                     return Some(&[]);
                 }
                 // Non-empty slice, must have memory. We know this is a relative pointer.
-                let (inner_prov, offset) = ptr.into_parts();
-                let data = tcx.global_alloc(inner_prov?.alloc_id()).unwrap_memory();
+                let (inner_prov, offset) =
+                    ptr.into_pointer_or_addr().ok()?.prov_and_relative_offset();
+                let data = tcx.global_alloc(inner_prov.alloc_id()).unwrap_memory();
                 (data, offset.bytes(), offset.bytes() + len)
             }
         };
diff --git a/compiler/rustc_middle/src/mir/interpret/allocation.rs b/compiler/rustc_middle/src/mir/interpret/allocation.rs
index dd55d03..4198b19 100644
--- a/compiler/rustc_middle/src/mir/interpret/allocation.rs
+++ b/compiler/rustc_middle/src/mir/interpret/allocation.rs
@@ -526,7 +526,7 @@ pub fn adjust_from_tcx<'tcx, Prov: Provenance, Bytes: AllocBytes>(
             let ptr_bytes = &mut bytes[idx..idx + ptr_size];
             let bits = read_target_uint(endian, ptr_bytes).unwrap();
             let (ptr_prov, ptr_offset) =
-                adjust_ptr(Pointer::new(alloc_id, Size::from_bytes(bits)))?.into_parts();
+                adjust_ptr(Pointer::new(alloc_id, Size::from_bytes(bits)))?.into_raw_parts();
             write_target_uint(endian, ptr_bytes, ptr_offset.bytes().into()).unwrap();
             new_provenance.push((offset, ptr_prov));
         }
@@ -769,7 +769,7 @@ pub fn write_scalar(
         // as-is into memory. This also double-checks that `val.size()` matches `range.size`.
         let (bytes, provenance) = match val.to_bits_or_ptr_internal(range.size)? {
             Right(ptr) => {
-                let (provenance, offset) = ptr.into_parts();
+                let (provenance, offset) = ptr.into_raw_parts();
                 (u128::from(offset.bytes()), Some(provenance))
             }
             Left(data) => (data, None),
diff --git a/compiler/rustc_middle/src/mir/interpret/mod.rs b/compiler/rustc_middle/src/mir/interpret/mod.rs
index ea2f84d..da9e5bd 100644
--- a/compiler/rustc_middle/src/mir/interpret/mod.rs
+++ b/compiler/rustc_middle/src/mir/interpret/mod.rs
@@ -77,7 +77,7 @@ pub fn display(self, tcx: TyCtxt<'tcx>) -> String {
 #[derive(Copy, Clone, Debug, Eq, PartialEq, Hash, HashStable)]
 pub struct LitToConstInput<'tcx> {
     /// The absolute value of the resultant constant.
-    pub lit: &'tcx LitKind,
+    pub lit: LitKind,
     /// The type of the constant.
     pub ty: Ty<'tcx>,
     /// If the constant is negative.
diff --git a/compiler/rustc_middle/src/mir/interpret/pointer.rs b/compiler/rustc_middle/src/mir/interpret/pointer.rs
index 25c7c26..0ff14f1 100644
--- a/compiler/rustc_middle/src/mir/interpret/pointer.rs
+++ b/compiler/rustc_middle/src/mir/interpret/pointer.rs
@@ -288,7 +288,7 @@ fn from(prov: CtfeProvenance) -> Self {
 impl<Prov> From<Pointer<Prov>> for Pointer<Option<Prov>> {
     #[inline(always)]
     fn from(ptr: Pointer<Prov>) -> Self {
-        let (prov, offset) = ptr.into_parts();
+        let (prov, offset) = ptr.into_raw_parts();
         Pointer::new(Some(prov), offset)
     }
 }
@@ -314,19 +314,17 @@ pub fn addr(self) -> Size
         assert!(Prov::OFFSET_IS_ADDR);
         self.offset
     }
-}
 
-impl<Prov> Pointer<Option<Prov>> {
     /// Creates a pointer to the given address, with invalid provenance (i.e., cannot be used for
     /// any memory access).
     #[inline(always)]
-    pub fn from_addr_invalid(addr: u64) -> Self {
+    pub fn without_provenance(addr: u64) -> Self {
         Pointer { provenance: None, offset: Size::from_bytes(addr) }
     }
 
     #[inline(always)]
     pub fn null() -> Self {
-        Pointer::from_addr_invalid(0)
+        Pointer::without_provenance(0)
     }
 }
 
@@ -336,11 +334,11 @@ pub fn new(provenance: Prov, offset: Size) -> Self {
         Pointer { provenance, offset }
     }
 
-    /// Obtain the constituents of this pointer. Not that the meaning of the offset depends on the type `Prov`!
-    /// This function must only be used in the implementation of `Machine::ptr_get_alloc`,
-    /// and when a `Pointer` is taken apart to be stored efficiently in an `Allocation`.
+    /// Obtain the constituents of this pointer. Note that the meaning of the offset depends on the
+    /// type `Prov`! This is a low-level function that should only be used when absolutely
+    /// necessary. Prefer `prov_and_relative_offset` if possible.
     #[inline(always)]
-    pub fn into_parts(self) -> (Prov, Size) {
+    pub fn into_raw_parts(self) -> (Prov, Size) {
         (self.provenance, self.offset)
     }
 
@@ -361,3 +359,12 @@ pub fn wrapping_signed_offset(self, i: i64, cx: &impl HasDataLayout) -> Self {
         self.wrapping_offset(Size::from_bytes(i as u64), cx)
     }
 }
+
+impl Pointer<CtfeProvenance> {
+    /// Return the provenance and relative offset stored in this pointer. Safer alternative to
+    /// `into_raw_parts` since the type ensures that the offset is indeed relative.
+    #[inline(always)]
+    pub fn prov_and_relative_offset(self) -> (CtfeProvenance, Size) {
+        (self.provenance, self.offset)
+    }
+}
diff --git a/compiler/rustc_middle/src/mir/interpret/value.rs b/compiler/rustc_middle/src/mir/interpret/value.rs
index 7ba0e5b..8092f63 100644
--- a/compiler/rustc_middle/src/mir/interpret/value.rs
+++ b/compiler/rustc_middle/src/mir/interpret/value.rs
@@ -109,7 +109,7 @@ pub fn from_pointer(ptr: Pointer<Prov>, cx: &impl HasDataLayout) -> Self {
     /// Create a Scalar from a pointer with an `Option<_>` provenance (where `None` represents a
     /// plain integer / "invalid" pointer).
     pub fn from_maybe_pointer(ptr: Pointer<Option<Prov>>, cx: &impl HasDataLayout) -> Self {
-        match ptr.into_parts() {
+        match ptr.into_raw_parts() {
             (Some(prov), offset) => Scalar::from_pointer(Pointer::new(prov, offset), cx),
             (None, offset) => {
                 Scalar::Int(ScalarInt::try_from_uint(offset.bytes(), cx.pointer_size()).unwrap())
@@ -276,7 +276,7 @@ pub fn to_pointer(self, cx: &impl HasDataLayout) -> InterpResult<'tcx, Pointer<O
             Right(ptr) => interp_ok(ptr.into()),
             Left(bits) => {
                 let addr = u64::try_from(bits).unwrap();
-                interp_ok(Pointer::from_addr_invalid(addr))
+                interp_ok(Pointer::without_provenance(addr))
             }
         }
     }
@@ -299,7 +299,7 @@ pub fn try_to_scalar_int(self) -> Result<ScalarInt, Scalar<AllocId>> {
                     Ok(ScalarInt::try_from_uint(ptr.offset.bytes(), Size::from_bytes(sz)).unwrap())
                 } else {
                     // We know `offset` is relative, since `OFFSET_IS_ADDR == false`.
-                    let (prov, offset) = ptr.into_parts();
+                    let (prov, offset) = ptr.into_raw_parts();
                     // Because `OFFSET_IS_ADDR == false`, this unwrap can never fail.
                     Err(Scalar::Ptr(Pointer::new(prov.get_alloc_id().unwrap(), offset), sz))
                 }
diff --git a/compiler/rustc_middle/src/mir/mod.rs b/compiler/rustc_middle/src/mir/mod.rs
index adc1009..33e9776 100644
--- a/compiler/rustc_middle/src/mir/mod.rs
+++ b/compiler/rustc_middle/src/mir/mod.rs
@@ -1336,6 +1336,7 @@ pub fn start_location(self) -> Location {
 ///
 /// See [`BasicBlock`] for documentation on what basic blocks are at a high level.
 #[derive(Clone, Debug, TyEncodable, TyDecodable, HashStable, TypeFoldable, TypeVisitable)]
+#[non_exhaustive]
 pub struct BasicBlockData<'tcx> {
     /// List of statements in this block.
     pub statements: Vec<Statement<'tcx>>,
@@ -1359,7 +1360,15 @@ pub struct BasicBlockData<'tcx> {
 
 impl<'tcx> BasicBlockData<'tcx> {
     pub fn new(terminator: Option<Terminator<'tcx>>, is_cleanup: bool) -> BasicBlockData<'tcx> {
-        BasicBlockData { statements: vec![], terminator, is_cleanup }
+        BasicBlockData::new_stmts(Vec::new(), terminator, is_cleanup)
+    }
+
+    pub fn new_stmts(
+        statements: Vec<Statement<'tcx>>,
+        terminator: Option<Terminator<'tcx>>,
+        is_cleanup: bool,
+    ) -> BasicBlockData<'tcx> {
+        BasicBlockData { statements, terminator, is_cleanup }
     }
 
     /// Accessor for terminator.
diff --git a/compiler/rustc_middle/src/mir/statement.rs b/compiler/rustc_middle/src/mir/statement.rs
index d98b40f..683d7b4 100644
--- a/compiler/rustc_middle/src/mir/statement.rs
+++ b/compiler/rustc_middle/src/mir/statement.rs
@@ -11,17 +11,22 @@
 
 /// A statement in a basic block, including information about its source code.
 #[derive(Clone, TyEncodable, TyDecodable, HashStable, TypeFoldable, TypeVisitable)]
+#[non_exhaustive]
 pub struct Statement<'tcx> {
     pub source_info: SourceInfo,
     pub kind: StatementKind<'tcx>,
 }
 
-impl Statement<'_> {
+impl<'tcx> Statement<'tcx> {
     /// Changes a statement to a nop. This is both faster than deleting instructions and avoids
     /// invalidating statement indices in `Location`s.
     pub fn make_nop(&mut self) {
         self.kind = StatementKind::Nop
     }
+
+    pub fn new(source_info: SourceInfo, kind: StatementKind<'tcx>) -> Self {
+        Statement { source_info, kind }
+    }
 }
 
 impl<'tcx> StatementKind<'tcx> {
diff --git a/compiler/rustc_middle/src/query/erase.rs b/compiler/rustc_middle/src/query/erase.rs
index 26a31cb..f138c5c 100644
--- a/compiler/rustc_middle/src/query/erase.rs
+++ b/compiler/rustc_middle/src/query/erase.rs
@@ -266,6 +266,7 @@ impl EraseType for $ty {
     Option<rustc_target::spec::PanicStrategy>,
     Option<usize>,
     Option<rustc_middle::ty::IntrinsicDef>,
+    Option<rustc_abi::Align>,
     Result<(), rustc_errors::ErrorGuaranteed>,
     Result<(), rustc_middle::traits::query::NoSolution>,
     Result<rustc_middle::traits::EvaluationResult, rustc_middle::traits::OverflowError>,
diff --git a/compiler/rustc_middle/src/query/mod.rs b/compiler/rustc_middle/src/query/mod.rs
index 8a3d26e..3e68f0f 100644
--- a/compiler/rustc_middle/src/query/mod.rs
+++ b/compiler/rustc_middle/src/query/mod.rs
@@ -67,6 +67,7 @@
 use std::path::PathBuf;
 use std::sync::Arc;
 
+use rustc_abi::Align;
 use rustc_arena::TypedArena;
 use rustc_ast::expand::StrippedCfgItem;
 use rustc_ast::expand::allocator::AllocatorKind;
@@ -1481,6 +1482,10 @@
         desc { |tcx| "computing should_inherit_track_caller of `{}`", tcx.def_path_str(def_id) }
     }
 
+    query inherited_align(def_id: DefId) -> Option<Align> {
+        desc { |tcx| "computing inherited_align of `{}`", tcx.def_path_str(def_id) }
+    }
+
     query lookup_deprecation_entry(def_id: DefId) -> Option<DeprecationEntry> {
         desc { |tcx| "checking whether `{}` is deprecated", tcx.def_path_str(def_id) }
         cache_on_disk_if { def_id.is_local() }
@@ -2312,13 +2317,32 @@
         separate_provide_extern
     }
 
-    /// The list of symbols exported from the given crate.
+    /// The list of non-generic symbols exported from the given crate.
     ///
-    /// - All names contained in `exported_symbols(cnum)` are guaranteed to
-    ///   correspond to a publicly visible symbol in `cnum` machine code.
-    /// - The `exported_symbols` sets of different crates do not intersect.
-    query exported_symbols(cnum: CrateNum) -> &'tcx [(ExportedSymbol<'tcx>, SymbolExportInfo)] {
-        desc { "collecting exported symbols for crate `{}`", cnum}
+    /// This is separate from exported_generic_symbols to avoid having
+    /// to deserialize all non-generic symbols too for upstream crates
+    /// in the upstream_monomorphizations query.
+    ///
+    /// - All names contained in `exported_non_generic_symbols(cnum)` are
+    ///   guaranteed to correspond to a publicly visible symbol in `cnum`
+    ///   machine code.
+    /// - The `exported_non_generic_symbols` and `exported_generic_symbols`
+    ///   sets of different crates do not intersect.
+    query exported_non_generic_symbols(cnum: CrateNum) -> &'tcx [(ExportedSymbol<'tcx>, SymbolExportInfo)] {
+        desc { "collecting exported non-generic symbols for crate `{}`", cnum}
+        cache_on_disk_if { *cnum == LOCAL_CRATE }
+        separate_provide_extern
+    }
+
+    /// The list of generic symbols exported from the given crate.
+    ///
+    /// - All names contained in `exported_generic_symbols(cnum)` are
+    ///   guaranteed to correspond to a publicly visible symbol in `cnum`
+    ///   machine code.
+    /// - The `exported_non_generic_symbols` and `exported_generic_symbols`
+    ///   sets of different crates do not intersect.
+    query exported_generic_symbols(cnum: CrateNum) -> &'tcx [(ExportedSymbol<'tcx>, SymbolExportInfo)] {
+        desc { "collecting exported generic symbols for crate `{}`", cnum}
         cache_on_disk_if { *cnum == LOCAL_CRATE }
         separate_provide_extern
     }
diff --git a/compiler/rustc_middle/src/query/on_disk_cache.rs b/compiler/rustc_middle/src/query/on_disk_cache.rs
index e1876f8..a7ac34428 100644
--- a/compiler/rustc_middle/src/query/on_disk_cache.rs
+++ b/compiler/rustc_middle/src/query/on_disk_cache.rs
@@ -20,8 +20,8 @@
 };
 use rustc_span::source_map::Spanned;
 use rustc_span::{
-    BytePos, CachingSourceMapView, ExpnData, ExpnHash, Pos, RelativeBytePos, SourceFile, Span,
-    SpanDecoder, SpanEncoder, StableSourceFileId, Symbol,
+    BytePos, ByteSymbol, CachingSourceMapView, ExpnData, ExpnHash, Pos, RelativeBytePos,
+    SourceFile, Span, SpanDecoder, SpanEncoder, StableSourceFileId, Symbol,
 };
 
 use crate::dep_graph::{DepNodeIndex, SerializedDepNodeIndex};
@@ -42,7 +42,7 @@
 const TAG_SYNTAX_CONTEXT: u8 = 0;
 const TAG_EXPN_DATA: u8 = 1;
 
-// Tags for encoding Symbol's
+// Tags for encoding Symbols and ByteSymbols
 const SYMBOL_STR: u8 = 0;
 const SYMBOL_OFFSET: u8 = 1;
 const SYMBOL_PREDEFINED: u8 = 2;
@@ -253,7 +253,7 @@ pub fn serialize(&self, tcx: TyCtxt<'_>, encoder: FileEncoder) -> FileEncodeResu
                 source_map: CachingSourceMapView::new(tcx.sess.source_map()),
                 file_to_file_index,
                 hygiene_context: &hygiene_encode_context,
-                symbol_table: Default::default(),
+                symbol_index_table: Default::default(),
             };
 
             // Encode query results.
@@ -479,6 +479,30 @@ fn file_index_to_file(&self, index: SourceFileIndex) -> Arc<SourceFile> {
                 .expect("failed to lookup `SourceFile` in new context")
         }))
     }
+
+    // copy&paste impl from rustc_metadata
+    #[inline]
+    fn decode_symbol_or_byte_symbol<S>(
+        &mut self,
+        new_from_index: impl Fn(u32) -> S,
+        read_and_intern_str_or_byte_str_this: impl Fn(&mut Self) -> S,
+        read_and_intern_str_or_byte_str_opaque: impl Fn(&mut MemDecoder<'a>) -> S,
+    ) -> S {
+        let tag = self.read_u8();
+
+        match tag {
+            SYMBOL_STR => read_and_intern_str_or_byte_str_this(self),
+            SYMBOL_OFFSET => {
+                // read str offset
+                let pos = self.read_usize();
+
+                // move to str offset and read
+                self.opaque.with_position(pos, |d| read_and_intern_str_or_byte_str_opaque(d))
+            }
+            SYMBOL_PREDEFINED => new_from_index(self.read_u32()),
+            _ => unreachable!(),
+        }
+    }
 }
 
 // Decodes something that was encoded with `encode_tagged()` and verify that the
@@ -653,32 +677,20 @@ fn decode_span(&mut self) -> Span {
         Span::new(lo, hi, ctxt, parent)
     }
 
-    // copy&paste impl from rustc_metadata
-    #[inline]
     fn decode_symbol(&mut self) -> Symbol {
-        let tag = self.read_u8();
+        self.decode_symbol_or_byte_symbol(
+            Symbol::new,
+            |this| Symbol::intern(this.read_str()),
+            |opaque| Symbol::intern(opaque.read_str()),
+        )
+    }
 
-        match tag {
-            SYMBOL_STR => {
-                let s = self.read_str();
-                Symbol::intern(s)
-            }
-            SYMBOL_OFFSET => {
-                // read str offset
-                let pos = self.read_usize();
-
-                // move to str offset and read
-                self.opaque.with_position(pos, |d| {
-                    let s = d.read_str();
-                    Symbol::intern(s)
-                })
-            }
-            SYMBOL_PREDEFINED => {
-                let symbol_index = self.read_u32();
-                Symbol::new(symbol_index)
-            }
-            _ => unreachable!(),
-        }
+    fn decode_byte_symbol(&mut self) -> ByteSymbol {
+        self.decode_symbol_or_byte_symbol(
+            ByteSymbol::new,
+            |this| ByteSymbol::intern(this.read_byte_str()),
+            |opaque| ByteSymbol::intern(opaque.read_byte_str()),
+        )
     }
 
     fn decode_crate_num(&mut self) -> CrateNum {
@@ -807,7 +819,8 @@ pub struct CacheEncoder<'a, 'tcx> {
     source_map: CachingSourceMapView<'tcx>,
     file_to_file_index: FxHashMap<*const SourceFile, SourceFileIndex>,
     hygiene_context: &'a HygieneEncodeContext,
-    symbol_table: FxHashMap<Symbol, usize>,
+    // Used for both `Symbol`s and `ByteSymbol`s.
+    symbol_index_table: FxHashMap<u32, usize>,
 }
 
 impl<'a, 'tcx> CacheEncoder<'a, 'tcx> {
@@ -831,6 +844,34 @@ pub fn encode_tagged<T: Encodable<Self>, V: Encodable<Self>>(&mut self, tag: T,
         ((end_pos - start_pos) as u64).encode(self);
     }
 
+    // copy&paste impl from rustc_metadata
+    fn encode_symbol_or_byte_symbol(
+        &mut self,
+        index: u32,
+        emit_str_or_byte_str: impl Fn(&mut Self),
+    ) {
+        // if symbol/byte symbol is predefined, emit tag and symbol index
+        if Symbol::is_predefined(index) {
+            self.encoder.emit_u8(SYMBOL_PREDEFINED);
+            self.encoder.emit_u32(index);
+        } else {
+            // otherwise write it as string or as offset to it
+            match self.symbol_index_table.entry(index) {
+                Entry::Vacant(o) => {
+                    self.encoder.emit_u8(SYMBOL_STR);
+                    let pos = self.encoder.position();
+                    o.insert(pos);
+                    emit_str_or_byte_str(self);
+                }
+                Entry::Occupied(o) => {
+                    let x = *o.get();
+                    self.emit_u8(SYMBOL_OFFSET);
+                    self.emit_usize(x);
+                }
+            }
+        }
+    }
+
     #[inline]
     fn finish(mut self) -> FileEncodeResult {
         self.encoder.finish()
@@ -889,28 +930,14 @@ fn encode_span(&mut self, span: Span) {
         len.encode(self);
     }
 
-    // copy&paste impl from rustc_metadata
-    fn encode_symbol(&mut self, symbol: Symbol) {
-        // if symbol predefined, emit tag and symbol index
-        if symbol.is_predefined() {
-            self.encoder.emit_u8(SYMBOL_PREDEFINED);
-            self.encoder.emit_u32(symbol.as_u32());
-        } else {
-            // otherwise write it as string or as offset to it
-            match self.symbol_table.entry(symbol) {
-                Entry::Vacant(o) => {
-                    self.encoder.emit_u8(SYMBOL_STR);
-                    let pos = self.encoder.position();
-                    o.insert(pos);
-                    self.emit_str(symbol.as_str());
-                }
-                Entry::Occupied(o) => {
-                    let x = *o.get();
-                    self.emit_u8(SYMBOL_OFFSET);
-                    self.emit_usize(x);
-                }
-            }
-        }
+    fn encode_symbol(&mut self, sym: Symbol) {
+        self.encode_symbol_or_byte_symbol(sym.as_u32(), |this| this.emit_str(sym.as_str()));
+    }
+
+    fn encode_byte_symbol(&mut self, byte_sym: ByteSymbol) {
+        self.encode_symbol_or_byte_symbol(byte_sym.as_u32(), |this| {
+            this.emit_byte_str(byte_sym.as_byte_str())
+        });
     }
 
     fn encode_crate_num(&mut self, crate_num: CrateNum) {
diff --git a/compiler/rustc_middle/src/thir.rs b/compiler/rustc_middle/src/thir.rs
index d0e72a8..bda8dca 100644
--- a/compiler/rustc_middle/src/thir.rs
+++ b/compiler/rustc_middle/src/thir.rs
@@ -526,7 +526,7 @@ pub enum ExprKind<'tcx> {
     Closure(Box<ClosureExpr<'tcx>>),
     /// A literal.
     Literal {
-        lit: &'tcx hir::Lit,
+        lit: hir::Lit,
         neg: bool,
     },
     /// For literals that don't correspond to anything in the HIR
diff --git a/compiler/rustc_middle/src/ty/adjustment.rs b/compiler/rustc_middle/src/ty/adjustment.rs
index 3bacdfe..7457345 100644
--- a/compiler/rustc_middle/src/ty/adjustment.rs
+++ b/compiler/rustc_middle/src/ty/adjustment.rs
@@ -36,9 +36,6 @@ pub enum PointerCoercion {
     /// type. Codegen backends and miri figure out what has to be done
     /// based on the precise source/target type at hand.
     Unsize,
-
-    /// Go from a pointer-like type to a `dyn*` object.
-    DynStar,
 }
 
 /// Represents coercing a value to a different type of value.
diff --git a/compiler/rustc_middle/src/ty/codec.rs b/compiler/rustc_middle/src/ty/codec.rs
index 3d7965f..335b889 100644
--- a/compiler/rustc_middle/src/ty/codec.rs
+++ b/compiler/rustc_middle/src/ty/codec.rs
@@ -8,12 +8,12 @@
 
 use std::hash::Hash;
 use std::intrinsics;
-use std::marker::DiscriminantKind;
+use std::marker::{DiscriminantKind, PointeeSized};
 
 use rustc_abi::{FieldIdx, VariantIdx};
 use rustc_data_structures::fx::FxHashMap;
 use rustc_hir::def_id::LocalDefId;
-use rustc_serialize::{Decodable, Encodable, PointeeSized};
+use rustc_serialize::{Decodable, Encodable};
 use rustc_span::source_map::Spanned;
 use rustc_span::{Span, SpanDecoder, SpanEncoder};
 
diff --git a/compiler/rustc_middle/src/ty/context.rs b/compiler/rustc_middle/src/ty/context.rs
index 457a4f4..f5c55f9 100644
--- a/compiler/rustc_middle/src/ty/context.rs
+++ b/compiler/rustc_middle/src/ty/context.rs
@@ -10,13 +10,14 @@
 use std::env::VarError;
 use std::ffi::OsStr;
 use std::hash::{Hash, Hasher};
-use std::marker::PhantomData;
+use std::marker::{PhantomData, PointeeSized};
 use std::ops::{Bound, Deref};
 use std::sync::{Arc, OnceLock};
 use std::{fmt, iter, mem};
 
 use rustc_abi::{ExternAbi, FieldIdx, Layout, LayoutData, TargetDataLayout, VariantIdx};
 use rustc_ast as ast;
+use rustc_attr_data_structures::{AttributeKind, find_attr};
 use rustc_data_structures::defer;
 use rustc_data_structures::fingerprint::Fingerprint;
 use rustc_data_structures::fx::FxHashMap;
@@ -43,7 +44,6 @@
 use rustc_query_system::cache::WithDepNode;
 use rustc_query_system::dep_graph::DepNodeIndex;
 use rustc_query_system::ich::StableHashingContext;
-use rustc_serialize::PointeeSized;
 use rustc_serialize::opaque::{FileEncodeResult, FileEncoder};
 use rustc_session::config::CrateType;
 use rustc_session::cstore::{CrateStoreDyn, Untracked};
@@ -1648,32 +1648,9 @@ pub fn is_default_trait(self, def_id: DefId) -> bool {
     /// `rustc_layout_scalar_valid_range` attribute.
     // FIXME(eddyb) this is an awkward spot for this method, maybe move it?
     pub fn layout_scalar_valid_range(self, def_id: DefId) -> (Bound<u128>, Bound<u128>) {
-        let get = |name| {
-            let Some(attr) = self.get_attr(def_id, name) else {
-                return Bound::Unbounded;
-            };
-            debug!("layout_scalar_valid_range: attr={:?}", attr);
-            if let Some(
-                &[
-                    ast::MetaItemInner::Lit(ast::MetaItemLit {
-                        kind: ast::LitKind::Int(a, _), ..
-                    }),
-                ],
-            ) = attr.meta_item_list().as_deref()
-            {
-                Bound::Included(a.get())
-            } else {
-                self.dcx().span_delayed_bug(
-                    attr.span(),
-                    "invalid rustc_layout_scalar_valid_range attribute",
-                );
-                Bound::Unbounded
-            }
-        };
-        (
-            get(sym::rustc_layout_scalar_valid_range_start),
-            get(sym::rustc_layout_scalar_valid_range_end),
-        )
+        let start = find_attr!(self.get_all_attrs(def_id), AttributeKind::RustcLayoutScalarValidRangeStart(n, _) => Bound::Included(**n)).unwrap_or(Bound::Unbounded);
+        let end = find_attr!(self.get_all_attrs(def_id), AttributeKind::RustcLayoutScalarValidRangeEnd(n, _) => Bound::Included(**n)).unwrap_or(Bound::Unbounded);
+        (start, end)
     }
 
     pub fn lift<T: Lift<TyCtxt<'tcx>>>(self, value: T) -> Option<T::Lifted> {
diff --git a/compiler/rustc_middle/src/ty/layout.rs b/compiler/rustc_middle/src/ty/layout.rs
index 90b832d..09379d9 100644
--- a/compiler/rustc_middle/src/ty/layout.rs
+++ b/compiler/rustc_middle/src/ty/layout.rs
@@ -946,21 +946,6 @@ fn field_ty_or_layout<'tcx>(
                     }
                 }
 
-                ty::Dynamic(_, _, ty::DynStar) => {
-                    if i == 0 {
-                        TyMaybeWithLayout::Ty(Ty::new_mut_ptr(tcx, tcx.types.unit))
-                    } else if i == 1 {
-                        // FIXME(dyn-star) same FIXME as above applies here too
-                        TyMaybeWithLayout::Ty(Ty::new_imm_ref(
-                            tcx,
-                            tcx.lifetimes.re_static,
-                            Ty::new_array(tcx, tcx.types.usize, 3),
-                        ))
-                    } else {
-                        bug!("no field {i} on dyn*")
-                    }
-                }
-
                 ty::Alias(..)
                 | ty::Bound(..)
                 | ty::Placeholder(..)
diff --git a/compiler/rustc_middle/src/ty/print/pretty.rs b/compiler/rustc_middle/src/ty/print/pretty.rs
index 1392d1d..b4c4f48 100644
--- a/compiler/rustc_middle/src/ty/print/pretty.rs
+++ b/compiler/rustc_middle/src/ty/print/pretty.rs
@@ -810,7 +810,6 @@ fn pretty_print_type(&mut self, ty: Ty<'tcx>) -> Result<(), PrintError> {
                 }
                 match repr {
                     ty::Dyn => p!("dyn "),
-                    ty::DynStar => p!("dyn* "),
                 }
                 p!(print(data));
                 if print_r {
@@ -1755,7 +1754,7 @@ fn pretty_print_const_scalar_ptr(
     ) -> Result<(), PrintError> {
         define_scoped_cx!(self);
 
-        let (prov, offset) = ptr.into_parts();
+        let (prov, offset) = ptr.prov_and_relative_offset();
         match ty.kind() {
             // Byte strings (&[u8; N])
             ty::Ref(_, inner, _) => {
diff --git a/compiler/rustc_middle/src/ty/sty.rs b/compiler/rustc_middle/src/ty/sty.rs
index 3971ac1..399a6d6 100644
--- a/compiler/rustc_middle/src/ty/sty.rs
+++ b/compiler/rustc_middle/src/ty/sty.rs
@@ -1322,11 +1322,6 @@ pub fn is_trait(self) -> bool {
     }
 
     #[inline]
-    pub fn is_dyn_star(self) -> bool {
-        matches!(self.kind(), Dynamic(_, _, ty::DynStar))
-    }
-
-    #[inline]
     pub fn is_enum(self) -> bool {
         matches!(self.kind(), Adt(adt_def, _) if adt_def.is_enum())
     }
@@ -1629,8 +1624,6 @@ pub fn ptr_metadata_ty_or_tail(
             | ty::Error(_)
             // Extern types have metadata = ().
             | ty::Foreign(..)
-            // `dyn*` has metadata = ().
-            | ty::Dynamic(_, _, ty::DynStar)
             // If returned by `struct_tail_raw` this is a unit struct
             // without any fields, or not a struct, and therefore is Sized.
             | ty::Adt(..)
@@ -1820,8 +1813,7 @@ pub fn has_trivial_sizedness(self, tcx: TyCtxt<'tcx>, sizedness: SizedTraitKind)
             | ty::Closure(..)
             | ty::CoroutineClosure(..)
             | ty::Never
-            | ty::Error(_)
-            | ty::Dynamic(_, _, ty::DynStar) => true,
+            | ty::Error(_) => true,
 
             ty::Str | ty::Slice(_) | ty::Dynamic(_, _, ty::Dyn) => match sizedness {
                 SizedTraitKind::Sized => false,
diff --git a/compiler/rustc_mir_build/src/builder/cfg.rs b/compiler/rustc_mir_build/src/builder/cfg.rs
index 082cdc2..2faccc4 100644
--- a/compiler/rustc_mir_build/src/builder/cfg.rs
+++ b/compiler/rustc_mir_build/src/builder/cfg.rs
@@ -42,7 +42,7 @@ pub(crate) fn push_assign(
     ) {
         self.push(
             block,
-            Statement { source_info, kind: StatementKind::Assign(Box::new((place, rvalue))) },
+            Statement::new(source_info, StatementKind::Assign(Box::new((place, rvalue)))),
         );
     }
 
@@ -88,7 +88,7 @@ pub(crate) fn push_fake_read(
         place: Place<'tcx>,
     ) {
         let kind = StatementKind::FakeRead(Box::new((cause, place)));
-        let stmt = Statement { source_info, kind };
+        let stmt = Statement::new(source_info, kind);
         self.push(block, stmt);
     }
 
@@ -99,7 +99,7 @@ pub(crate) fn push_place_mention(
         place: Place<'tcx>,
     ) {
         let kind = StatementKind::PlaceMention(Box::new(place));
-        let stmt = Statement { source_info, kind };
+        let stmt = Statement::new(source_info, kind);
         self.push(block, stmt);
     }
 
@@ -110,7 +110,7 @@ pub(crate) fn push_place_mention(
     /// syntax (e.g. `continue` or `if !`) that would otherwise not appear in MIR.
     pub(crate) fn push_coverage_span_marker(&mut self, block: BasicBlock, source_info: SourceInfo) {
         let kind = StatementKind::Coverage(coverage::CoverageKind::SpanMarker);
-        let stmt = Statement { source_info, kind };
+        let stmt = Statement::new(source_info, kind);
         self.push(block, stmt);
     }
 
diff --git a/compiler/rustc_mir_build/src/builder/coverageinfo.rs b/compiler/rustc_mir_build/src/builder/coverageinfo.rs
index a80bd4f..aa43b27 100644
--- a/compiler/rustc_mir_build/src/builder/coverageinfo.rs
+++ b/compiler/rustc_mir_build/src/builder/coverageinfo.rs
@@ -61,10 +61,10 @@ fn inject_block_marker(
         block: BasicBlock,
     ) -> BlockMarkerId {
         let id = self.next_block_marker_id();
-        let marker_statement = mir::Statement {
+        let marker_statement = mir::Statement::new(
             source_info,
-            kind: mir::StatementKind::Coverage(CoverageKind::BlockMarker { id }),
-        };
+            mir::StatementKind::Coverage(CoverageKind::BlockMarker { id }),
+        );
         cfg.push(block, marker_statement);
 
         id
diff --git a/compiler/rustc_mir_build/src/builder/custom/parse.rs b/compiler/rustc_mir_build/src/builder/custom/parse.rs
index 91e2846..1015446 100644
--- a/compiler/rustc_mir_build/src/builder/custom/parse.rs
+++ b/compiler/rustc_mir_build/src/builder/custom/parse.rs
@@ -315,10 +315,8 @@ fn parse_block_def(&self, expr_id: ExprId, is_cleanup: bool) -> PResult<BasicBlo
             let stmt = self.statement_as_expr(*stmt_id)?;
             let span = self.thir[stmt].span;
             let statement = self.parse_statement(stmt)?;
-            data.statements.push(Statement {
-                source_info: SourceInfo { span, scope: self.source_scope },
-                kind: statement,
-            });
+            data.statements
+                .push(Statement::new(SourceInfo { span, scope: self.source_scope }, statement));
         }
 
         let Some(trailing) = block.expr else { return Err(self.expr_error(expr_id, "terminator")) };
diff --git a/compiler/rustc_mir_build/src/builder/expr/as_constant.rs b/compiler/rustc_mir_build/src/builder/expr/as_constant.rs
index eb8e98e..d0d0c21 100644
--- a/compiler/rustc_mir_build/src/builder/expr/as_constant.rs
+++ b/compiler/rustc_mir_build/src/builder/expr/as_constant.rs
@@ -49,7 +49,7 @@ pub(crate) fn as_constant_inner<'tcx>(
     let Expr { ty, temp_lifetime: _, span, ref kind } = *expr;
     match *kind {
         ExprKind::Literal { lit, neg } => {
-            let const_ = lit_to_mir_constant(tcx, LitToConstInput { lit: &lit.node, ty, neg });
+            let const_ = lit_to_mir_constant(tcx, LitToConstInput { lit: lit.node, ty, neg });
 
             ConstOperand { span, user_ty: None, const_ }
         }
@@ -128,34 +128,35 @@ fn lit_to_mir_constant<'tcx>(tcx: TyCtxt<'tcx>, lit_input: LitToConstInput<'tcx>
         (ast::LitKind::ByteStr(data, _), ty::Ref(_, inner_ty, _))
             if matches!(inner_ty.kind(), ty::Slice(_)) =>
         {
-            let allocation = Allocation::from_bytes_byte_aligned_immutable(data as &[u8], ());
+            let allocation = Allocation::from_bytes_byte_aligned_immutable(data.as_byte_str(), ());
             let allocation = tcx.mk_const_alloc(allocation);
             ConstValue::Slice { data: allocation, meta: allocation.inner().size().bytes() }
         }
-        (ast::LitKind::ByteStr(data, _), ty::Ref(_, inner_ty, _)) if inner_ty.is_array() => {
-            let id = tcx.allocate_bytes_dedup(data, CTFE_ALLOC_SALT);
+        (ast::LitKind::ByteStr(byte_sym, _), ty::Ref(_, inner_ty, _)) if inner_ty.is_array() => {
+            let id = tcx.allocate_bytes_dedup(byte_sym.as_byte_str(), CTFE_ALLOC_SALT);
             ConstValue::Scalar(Scalar::from_pointer(id.into(), &tcx))
         }
-        (ast::LitKind::CStr(data, _), ty::Ref(_, inner_ty, _)) if matches!(inner_ty.kind(), ty::Adt(def, _) if tcx.is_lang_item(def.did(), LangItem::CStr)) =>
+        (ast::LitKind::CStr(byte_sym, _), ty::Ref(_, inner_ty, _)) if matches!(inner_ty.kind(), ty::Adt(def, _) if tcx.is_lang_item(def.did(), LangItem::CStr)) =>
         {
-            let allocation = Allocation::from_bytes_byte_aligned_immutable(data as &[u8], ());
+            let allocation =
+                Allocation::from_bytes_byte_aligned_immutable(byte_sym.as_byte_str(), ());
             let allocation = tcx.mk_const_alloc(allocation);
             ConstValue::Slice { data: allocation, meta: allocation.inner().size().bytes() }
         }
         (ast::LitKind::Byte(n), ty::Uint(ty::UintTy::U8)) => {
-            ConstValue::Scalar(Scalar::from_uint(*n, Size::from_bytes(1)))
+            ConstValue::Scalar(Scalar::from_uint(n, Size::from_bytes(1)))
         }
         (ast::LitKind::Int(n, _), ty::Uint(_)) if !neg => trunc(n.get()),
         (ast::LitKind::Int(n, _), ty::Int(_)) => {
             trunc(if neg { (n.get() as i128).overflowing_neg().0 as u128 } else { n.get() })
         }
         (ast::LitKind::Float(n, _), ty::Float(fty)) => {
-            parse_float_into_constval(*n, *fty, neg).unwrap()
+            parse_float_into_constval(n, *fty, neg).unwrap()
         }
-        (ast::LitKind::Bool(b), ty::Bool) => ConstValue::Scalar(Scalar::from_bool(*b)),
-        (ast::LitKind::Char(c), ty::Char) => ConstValue::Scalar(Scalar::from_char(*c)),
+        (ast::LitKind::Bool(b), ty::Bool) => ConstValue::Scalar(Scalar::from_bool(b)),
+        (ast::LitKind::Char(c), ty::Char) => ConstValue::Scalar(Scalar::from_char(c)),
         (ast::LitKind::Err(guar), _) => {
-            return Const::Ty(Ty::new_error(tcx, *guar), ty::Const::new_error(tcx, *guar));
+            return Const::Ty(Ty::new_error(tcx, guar), ty::Const::new_error(tcx, guar));
         }
         _ => bug!("invalid lit/ty combination in `lit_to_mir_constant`: {lit:?}: {ty:?}"),
     };
diff --git a/compiler/rustc_mir_build/src/builder/expr/as_place.rs b/compiler/rustc_mir_build/src/builder/expr/as_place.rs
index 9914850..7c851ec 100644
--- a/compiler/rustc_mir_build/src/builder/expr/as_place.rs
+++ b/compiler/rustc_mir_build/src/builder/expr/as_place.rs
@@ -489,16 +489,16 @@ fn expr_as_place(
                     let place = place_builder.to_place(this);
                     this.cfg.push(
                         block,
-                        Statement {
-                            source_info: ty_source_info,
-                            kind: StatementKind::AscribeUserType(
+                        Statement::new(
+                            ty_source_info,
+                            StatementKind::AscribeUserType(
                                 Box::new((
                                     place,
                                     UserTypeProjection { base: annotation_index, projs: vec![] },
                                 )),
                                 Variance::Invariant,
                             ),
-                        },
+                        ),
                     );
                 }
                 block.and(place_builder)
@@ -518,16 +518,16 @@ fn expr_as_place(
                         });
                     this.cfg.push(
                         block,
-                        Statement {
-                            source_info: ty_source_info,
-                            kind: StatementKind::AscribeUserType(
+                        Statement::new(
+                            ty_source_info,
+                            StatementKind::AscribeUserType(
                                 Box::new((
                                     Place::from(temp),
                                     UserTypeProjection { base: annotation_index, projs: vec![] },
                                 )),
                                 Variance::Invariant,
                             ),
-                        },
+                        ),
                     );
                 }
                 block.and(PlaceBuilder::from(temp))
diff --git a/compiler/rustc_mir_build/src/builder/expr/as_rvalue.rs b/compiler/rustc_mir_build/src/builder/expr/as_rvalue.rs
index 9e07dd5..975226b 100644
--- a/compiler/rustc_mir_build/src/builder/expr/as_rvalue.rs
+++ b/compiler/rustc_mir_build/src/builder/expr/as_rvalue.rs
@@ -175,10 +175,8 @@ pub(crate) fn as_rvalue(
                 // and therefore is not considered during coroutine auto-trait
                 // determination. See the comment about `box` at `yield_in_scope`.
                 let result = this.local_decls.push(LocalDecl::new(expr.ty, expr_span));
-                this.cfg.push(
-                    block,
-                    Statement { source_info, kind: StatementKind::StorageLive(result) },
-                );
+                this.cfg
+                    .push(block, Statement::new(source_info, StatementKind::StorageLive(result)));
                 if let Some(scope) = scope.temp_lifetime {
                     // schedule a shallow free of that memory, lest we unwind:
                     this.schedule_drop_storage_and_value(expr_span, scope, result);
@@ -278,12 +276,12 @@ pub(crate) fn as_rvalue(
                         };
                         this.cfg.push(
                             block,
-                            Statement {
+                            Statement::new(
                                 source_info,
-                                kind: StatementKind::Intrinsic(Box::new(
-                                    NonDivergingIntrinsic::Assume(Operand::Move(assert_place)),
-                                )),
-                            },
+                                StatementKind::Intrinsic(Box::new(NonDivergingIntrinsic::Assume(
+                                    Operand::Move(assert_place),
+                                ))),
+                            ),
                         );
                     }
 
@@ -789,7 +787,7 @@ fn limit_capture_mutability(
         let source_info = this.source_info(upvar_span);
         let temp = this.local_decls.push(LocalDecl::new(upvar_ty, upvar_span));
 
-        this.cfg.push(block, Statement { source_info, kind: StatementKind::StorageLive(temp) });
+        this.cfg.push(block, Statement::new(source_info, StatementKind::StorageLive(temp)));
 
         let arg_place_builder = unpack!(block = this.as_place_builder(block, arg));
 
diff --git a/compiler/rustc_mir_build/src/builder/expr/as_temp.rs b/compiler/rustc_mir_build/src/builder/expr/as_temp.rs
index 0bd6116..b0ce352 100644
--- a/compiler/rustc_mir_build/src/builder/expr/as_temp.rs
+++ b/compiler/rustc_mir_build/src/builder/expr/as_temp.rs
@@ -102,8 +102,7 @@ fn as_temp_inner(
                 if let Block { expr: None, targeted_by_break: false, .. } = this.thir[block]
                     && expr_ty.is_never() => {}
             _ => {
-                this.cfg
-                    .push(block, Statement { source_info, kind: StatementKind::StorageLive(temp) });
+                this.cfg.push(block, Statement::new(source_info, StatementKind::StorageLive(temp)));
 
                 // In constants, `temp_lifetime` is `None` for temporaries that
                 // live for the `'static` lifetime. Thus we do not drop these
diff --git a/compiler/rustc_mir_build/src/builder/matches/mod.rs b/compiler/rustc_mir_build/src/builder/matches/mod.rs
index 270a7d4..9600067 100644
--- a/compiler/rustc_mir_build/src/builder/matches/mod.rs
+++ b/compiler/rustc_mir_build/src/builder/matches/mod.rs
@@ -646,9 +646,9 @@ pub(super) fn expr_into_pattern(
                 let base = self.canonical_user_type_annotations.push(annotation.clone());
                 self.cfg.push(
                     block,
-                    Statement {
-                        source_info: ty_source_info,
-                        kind: StatementKind::AscribeUserType(
+                    Statement::new(
+                        ty_source_info,
+                        StatementKind::AscribeUserType(
                             Box::new((place, UserTypeProjection { base, projs: Vec::new() })),
                             // We always use invariant as the variance here. This is because the
                             // variance field from the ascription refers to the variance to use
@@ -666,7 +666,7 @@ pub(super) fn expr_into_pattern(
                             // `<expr>`.
                             ty::Invariant,
                         ),
-                    },
+                    ),
                 );
 
                 self.schedule_drop_for_binding(var, irrefutable_pat.span, OutsideGuard);
@@ -828,7 +828,7 @@ pub(crate) fn storage_live_binding(
     ) -> Place<'tcx> {
         let local_id = self.var_local_id(var, for_guard);
         let source_info = self.source_info(span);
-        self.cfg.push(block, Statement { source_info, kind: StatementKind::StorageLive(local_id) });
+        self.cfg.push(block, Statement::new(source_info, StatementKind::StorageLive(local_id)));
         // Although there is almost always scope for given variable in corner cases
         // like #92893 we might get variable with no scope.
         if let Some(region_scope) = self.region_scope_tree.var_scope(var.0.local_id)
@@ -2578,16 +2578,16 @@ fn ascribe_types(
             let base = self.canonical_user_type_annotations.push(ascription.annotation);
             self.cfg.push(
                 block,
-                Statement {
+                Statement::new(
                     source_info,
-                    kind: StatementKind::AscribeUserType(
+                    StatementKind::AscribeUserType(
                         Box::new((
                             ascription.source,
                             UserTypeProjection { base, projs: Vec::new() },
                         )),
                         ascription.variance,
                     ),
-                },
+                ),
             );
         }
     }
diff --git a/compiler/rustc_mir_build/src/builder/scope.rs b/compiler/rustc_mir_build/src/builder/scope.rs
index 1d15e7e..405d47c 100644
--- a/compiler/rustc_mir_build/src/builder/scope.rs
+++ b/compiler/rustc_mir_build/src/builder/scope.rs
@@ -431,13 +431,13 @@ fn link_blocks<'tcx>(
                     cfg.terminate(block, drop_node.data.source_info, terminator);
                 }
                 DropKind::ForLint => {
-                    let stmt = Statement {
-                        source_info: drop_node.data.source_info,
-                        kind: StatementKind::BackwardIncompatibleDropHint {
+                    let stmt = Statement::new(
+                        drop_node.data.source_info,
+                        StatementKind::BackwardIncompatibleDropHint {
                             place: Box::new(drop_node.data.local.into()),
                             reason: BackwardIncompatibleDropReason::Edition2024,
                         },
-                    };
+                    );
                     cfg.push(block, stmt);
                     let target = blocks[drop_node.next].unwrap();
                     if target != block {
@@ -454,10 +454,10 @@ fn link_blocks<'tcx>(
                 // Root nodes don't correspond to a drop.
                 DropKind::Storage if drop_idx == ROOT_NODE => {}
                 DropKind::Storage => {
-                    let stmt = Statement {
-                        source_info: drop_node.data.source_info,
-                        kind: StatementKind::StorageDead(drop_node.data.local),
-                    };
+                    let stmt = Statement::new(
+                        drop_node.data.source_info,
+                        StatementKind::StorageDead(drop_node.data.local),
+                    );
                     cfg.push(block, stmt);
                     let target = blocks[drop_node.next].unwrap();
                     if target != block {
@@ -1124,13 +1124,13 @@ pub(crate) fn break_for_tail_call(
                     DropKind::ForLint => {
                         self.cfg.push(
                             block,
-                            Statement {
+                            Statement::new(
                                 source_info,
-                                kind: StatementKind::BackwardIncompatibleDropHint {
+                                StatementKind::BackwardIncompatibleDropHint {
                                     place: Box::new(local.into()),
                                     reason: BackwardIncompatibleDropReason::Edition2024,
                                 },
-                            },
+                            ),
                         );
                     }
                     DropKind::Storage => {
@@ -1138,7 +1138,7 @@ pub(crate) fn break_for_tail_call(
                         assert!(local.index() > self.arg_count);
                         self.cfg.push(
                             block,
-                            Statement { source_info, kind: StatementKind::StorageDead(local) },
+                            Statement::new(source_info, StatementKind::StorageDead(local)),
                         );
                     }
                 }
@@ -1880,13 +1880,13 @@ fn build_scope_drops<'tcx, F>(
 
                 cfg.push(
                     block,
-                    Statement {
+                    Statement::new(
                         source_info,
-                        kind: StatementKind::BackwardIncompatibleDropHint {
+                        StatementKind::BackwardIncompatibleDropHint {
                             place: Box::new(local.into()),
                             reason: BackwardIncompatibleDropReason::Edition2024,
                         },
-                    },
+                    ),
                 );
             }
             DropKind::Storage => {
@@ -1910,7 +1910,7 @@ fn build_scope_drops<'tcx, F>(
                 }
                 // Only temps and vars need their storage dead.
                 assert!(local.index() > arg_count);
-                cfg.push(block, Statement { source_info, kind: StatementKind::StorageDead(local) });
+                cfg.push(block, Statement::new(source_info, StatementKind::StorageDead(local)));
             }
         }
     }
diff --git a/compiler/rustc_mir_build/src/thir/constant.rs b/compiler/rustc_mir_build/src/thir/constant.rs
index b4fa55e..8e218a3 100644
--- a/compiler/rustc_mir_build/src/thir/constant.rs
+++ b/compiler/rustc_mir_build/src/thir/constant.rs
@@ -43,27 +43,23 @@ pub(crate) fn lit_to_const<'tcx>(
             let str_bytes = s.as_str().as_bytes();
             ty::ValTree::from_raw_bytes(tcx, str_bytes)
         }
-        (ast::LitKind::ByteStr(data, _), ty::Ref(_, inner_ty, _))
+        (ast::LitKind::ByteStr(byte_sym, _), ty::Ref(_, inner_ty, _))
             if matches!(inner_ty.kind(), ty::Slice(_) | ty::Array(..)) =>
         {
-            let bytes = data as &[u8];
-            ty::ValTree::from_raw_bytes(tcx, bytes)
+            ty::ValTree::from_raw_bytes(tcx, byte_sym.as_byte_str())
         }
-        (ast::LitKind::ByteStr(data, _), ty::Slice(_) | ty::Array(..))
+        (ast::LitKind::ByteStr(byte_sym, _), ty::Slice(_) | ty::Array(..))
             if tcx.features().deref_patterns() =>
         {
             // Byte string literal patterns may have type `[u8]` or `[u8; N]` if `deref_patterns` is
             // enabled, in order to allow, e.g., `deref!(b"..."): Vec<u8>`.
-            let bytes = data as &[u8];
-            ty::ValTree::from_raw_bytes(tcx, bytes)
+            ty::ValTree::from_raw_bytes(tcx, byte_sym.as_byte_str())
         }
         (ast::LitKind::Byte(n), ty::Uint(ty::UintTy::U8)) => {
-            ty::ValTree::from_scalar_int(tcx, (*n).into())
+            ty::ValTree::from_scalar_int(tcx, n.into())
         }
-        (ast::LitKind::CStr(data, _), ty::Ref(_, inner_ty, _)) if matches!(inner_ty.kind(), ty::Adt(def, _) if tcx.is_lang_item(def.did(), LangItem::CStr)) =>
-        {
-            let bytes = data as &[u8];
-            ty::ValTree::from_raw_bytes(tcx, bytes)
+        (ast::LitKind::CStr(byte_sym, _), ty::Ref(_, inner_ty, _)) if matches!(inner_ty.kind(), ty::Adt(def, _) if tcx.is_lang_item(def.did(), LangItem::CStr)) => {
+            ty::ValTree::from_raw_bytes(tcx, byte_sym.as_byte_str())
         }
         (ast::LitKind::Int(n, _), ty::Uint(ui)) if !neg => {
             let scalar_int = trunc(n.get(), *ui);
@@ -76,15 +72,15 @@ pub(crate) fn lit_to_const<'tcx>(
             );
             ty::ValTree::from_scalar_int(tcx, scalar_int)
         }
-        (ast::LitKind::Bool(b), ty::Bool) => ty::ValTree::from_scalar_int(tcx, (*b).into()),
+        (ast::LitKind::Bool(b), ty::Bool) => ty::ValTree::from_scalar_int(tcx, b.into()),
         (ast::LitKind::Float(n, _), ty::Float(fty)) => {
-            let bits = parse_float_into_scalar(*n, *fty, neg).unwrap_or_else(|| {
+            let bits = parse_float_into_scalar(n, *fty, neg).unwrap_or_else(|| {
                 tcx.dcx().bug(format!("couldn't parse float literal: {:?}", lit_input.lit))
             });
             ty::ValTree::from_scalar_int(tcx, bits)
         }
-        (ast::LitKind::Char(c), ty::Char) => ty::ValTree::from_scalar_int(tcx, (*c).into()),
-        (ast::LitKind::Err(guar), _) => return ty::Const::new_error(tcx, *guar),
+        (ast::LitKind::Char(c), ty::Char) => ty::ValTree::from_scalar_int(tcx, c.into()),
+        (ast::LitKind::Err(guar), _) => return ty::Const::new_error(tcx, guar),
         _ => return ty::Const::new_misc_error(tcx),
     };
 
diff --git a/compiler/rustc_mir_build/src/thir/pattern/mod.rs b/compiler/rustc_mir_build/src/thir/pattern/mod.rs
index fcd106d..e44a440 100644
--- a/compiler/rustc_mir_build/src/thir/pattern/mod.rs
+++ b/compiler/rustc_mir_build/src/thir/pattern/mod.rs
@@ -680,7 +680,7 @@ fn lower_pat_expr(
                     Some(pat_ty) => pat_ty,
                     None => self.typeck_results.node_type(expr.hir_id),
                 };
-                let lit_input = LitToConstInput { lit: &lit.node, ty: ct_ty, neg: *negated };
+                let lit_input = LitToConstInput { lit: lit.node, ty: ct_ty, neg: *negated };
                 let constant = self.tcx.at(expr.span).lit_to_const(lit_input);
                 self.const_to_pat(constant, ct_ty, expr.hir_id, lit.span).kind
             }
diff --git a/compiler/rustc_mir_dataflow/src/framework/tests.rs b/compiler/rustc_mir_dataflow/src/framework/tests.rs
index 8602bb5..23e28a1 100644
--- a/compiler/rustc_mir_dataflow/src/framework/tests.rs
+++ b/compiler/rustc_mir_dataflow/src/framework/tests.rs
@@ -17,13 +17,13 @@ fn mock_body<'tcx>() -> mir::Body<'tcx> {
 
     let mut blocks = IndexVec::new();
     let mut block = |n, kind| {
-        let nop = mir::Statement { source_info, kind: mir::StatementKind::Nop };
+        let nop = mir::Statement::new(source_info, mir::StatementKind::Nop);
 
-        blocks.push(mir::BasicBlockData {
-            statements: std::iter::repeat(&nop).cloned().take(n).collect(),
-            terminator: Some(mir::Terminator { source_info, kind }),
-            is_cleanup: false,
-        })
+        blocks.push(mir::BasicBlockData::new_stmts(
+            std::iter::repeat(&nop).cloned().take(n).collect(),
+            Some(mir::Terminator { source_info, kind }),
+            false,
+        ))
     };
 
     let dummy_place = mir::Place { local: mir::RETURN_PLACE, projection: ty::List::empty() };
diff --git a/compiler/rustc_mir_transform/src/add_call_guards.rs b/compiler/rustc_mir_transform/src/add_call_guards.rs
index bacff28..26839eb 100644
--- a/compiler/rustc_mir_transform/src/add_call_guards.rs
+++ b/compiler/rustc_mir_transform/src/add_call_guards.rs
@@ -44,11 +44,10 @@ fn run_pass(&self, _tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
 
         let cur_len = body.basic_blocks.len();
         let mut new_block = |source_info: SourceInfo, is_cleanup: bool, target: BasicBlock| {
-            let block = BasicBlockData {
-                statements: vec![],
+            let block = BasicBlockData::new(
+                Some(Terminator { source_info, kind: TerminatorKind::Goto { target } }),
                 is_cleanup,
-                terminator: Some(Terminator { source_info, kind: TerminatorKind::Goto { target } }),
-            };
+            );
             let idx = cur_len + new_blocks.len();
             new_blocks.push(block);
             BasicBlock::new(idx)
diff --git a/compiler/rustc_mir_transform/src/add_moves_for_packed_drops.rs b/compiler/rustc_mir_transform/src/add_moves_for_packed_drops.rs
index a414d12..7ae2eba 100644
--- a/compiler/rustc_mir_transform/src/add_moves_for_packed_drops.rs
+++ b/compiler/rustc_mir_transform/src/add_moves_for_packed_drops.rs
@@ -93,11 +93,11 @@ fn add_move_for_packed_drop<'tcx>(
     let ty = place.ty(body, tcx).ty;
     let temp = patch.new_temp(ty, source_info.span);
 
-    let storage_dead_block = patch.new_block(BasicBlockData {
-        statements: vec![Statement { source_info, kind: StatementKind::StorageDead(temp) }],
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::Goto { target } }),
+    let storage_dead_block = patch.new_block(BasicBlockData::new_stmts(
+        vec![Statement::new(source_info, StatementKind::StorageDead(temp))],
+        Some(Terminator { source_info, kind: TerminatorKind::Goto { target } }),
         is_cleanup,
-    });
+    ));
 
     patch.add_statement(loc, StatementKind::StorageLive(temp));
     patch.add_assign(loc, Place::from(temp), Rvalue::Use(Operand::Move(*place)));
diff --git a/compiler/rustc_mir_transform/src/add_retag.rs b/compiler/rustc_mir_transform/src/add_retag.rs
index e5a28d1..3c29d46 100644
--- a/compiler/rustc_mir_transform/src/add_retag.rs
+++ b/compiler/rustc_mir_transform/src/add_retag.rs
@@ -81,9 +81,11 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
             // Emit their retags.
             basic_blocks[START_BLOCK].statements.splice(
                 0..0,
-                places.map(|(place, source_info)| Statement {
-                    source_info,
-                    kind: StatementKind::Retag(RetagKind::FnEntry, Box::new(place)),
+                places.map(|(place, source_info)| {
+                    Statement::new(
+                        source_info,
+                        StatementKind::Retag(RetagKind::FnEntry, Box::new(place)),
+                    )
                 }),
             );
         }
@@ -113,10 +115,10 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
         for (source_info, dest_place, dest_block) in returns {
             basic_blocks[dest_block].statements.insert(
                 0,
-                Statement {
+                Statement::new(
                     source_info,
-                    kind: StatementKind::Retag(RetagKind::Default, Box::new(dest_place)),
-                },
+                    StatementKind::Retag(RetagKind::Default, Box::new(dest_place)),
+                ),
             );
         }
 
@@ -174,10 +176,7 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                 let source_info = block_data.statements[i].source_info;
                 block_data.statements.insert(
                     i + 1,
-                    Statement {
-                        source_info,
-                        kind: StatementKind::Retag(retag_kind, Box::new(place)),
-                    },
+                    Statement::new(source_info, StatementKind::Retag(retag_kind, Box::new(place))),
                 );
             }
         }
diff --git a/compiler/rustc_mir_transform/src/check_alignment.rs b/compiler/rustc_mir_transform/src/check_alignment.rs
index 8f88613..9897875 100644
--- a/compiler/rustc_mir_transform/src/check_alignment.rs
+++ b/compiler/rustc_mir_transform/src/check_alignment.rs
@@ -51,22 +51,18 @@ fn insert_alignment_check<'tcx>(
     let const_raw_ptr = Ty::new_imm_ptr(tcx, tcx.types.unit);
     let rvalue = Rvalue::Cast(CastKind::PtrToPtr, Operand::Copy(pointer), const_raw_ptr);
     let thin_ptr = local_decls.push(LocalDecl::with_source_info(const_raw_ptr, source_info)).into();
-    stmts
-        .push(Statement { source_info, kind: StatementKind::Assign(Box::new((thin_ptr, rvalue))) });
+    stmts.push(Statement::new(source_info, StatementKind::Assign(Box::new((thin_ptr, rvalue)))));
 
     // Transmute the pointer to a usize (equivalent to `ptr.addr()`).
     let rvalue = Rvalue::Cast(CastKind::Transmute, Operand::Copy(thin_ptr), tcx.types.usize);
     let addr = local_decls.push(LocalDecl::with_source_info(tcx.types.usize, source_info)).into();
-    stmts.push(Statement { source_info, kind: StatementKind::Assign(Box::new((addr, rvalue))) });
+    stmts.push(Statement::new(source_info, StatementKind::Assign(Box::new((addr, rvalue)))));
 
     // Get the alignment of the pointee
     let alignment =
         local_decls.push(LocalDecl::with_source_info(tcx.types.usize, source_info)).into();
     let rvalue = Rvalue::NullaryOp(NullOp::AlignOf, pointee_ty);
-    stmts.push(Statement {
-        source_info,
-        kind: StatementKind::Assign(Box::new((alignment, rvalue))),
-    });
+    stmts.push(Statement::new(source_info, StatementKind::Assign(Box::new((alignment, rvalue)))));
 
     // Subtract 1 from the alignment to get the alignment mask
     let alignment_mask =
@@ -76,13 +72,13 @@ fn insert_alignment_check<'tcx>(
         user_ty: None,
         const_: Const::Val(ConstValue::Scalar(Scalar::from_target_usize(1, &tcx)), tcx.types.usize),
     }));
-    stmts.push(Statement {
+    stmts.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             alignment_mask,
             Rvalue::BinaryOp(BinOp::Sub, Box::new((Operand::Copy(alignment), one))),
         ))),
-    });
+    ));
 
     // If this target does not have reliable alignment, further limit the mask by anding it with
     // the mask for the highest reliable alignment.
@@ -99,31 +95,31 @@ fn insert_alignment_check<'tcx>(
                 tcx.types.usize,
             ),
         }));
-        stmts.push(Statement {
+        stmts.push(Statement::new(
             source_info,
-            kind: StatementKind::Assign(Box::new((
+            StatementKind::Assign(Box::new((
                 alignment_mask,
                 Rvalue::BinaryOp(
                     BinOp::BitAnd,
                     Box::new((Operand::Copy(alignment_mask), max_mask)),
                 ),
             ))),
-        });
+        ));
     }
 
     // BitAnd the alignment mask with the pointer
     let alignment_bits =
         local_decls.push(LocalDecl::with_source_info(tcx.types.usize, source_info)).into();
-    stmts.push(Statement {
+    stmts.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             alignment_bits,
             Rvalue::BinaryOp(
                 BinOp::BitAnd,
                 Box::new((Operand::Copy(addr), Operand::Copy(alignment_mask))),
             ),
         ))),
-    });
+    ));
 
     // Check if the alignment bits are all zero
     let is_ok = local_decls.push(LocalDecl::with_source_info(tcx.types.bool, source_info)).into();
@@ -132,13 +128,13 @@ fn insert_alignment_check<'tcx>(
         user_ty: None,
         const_: Const::Val(ConstValue::Scalar(Scalar::from_target_usize(0, &tcx)), tcx.types.usize),
     }));
-    stmts.push(Statement {
+    stmts.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             is_ok,
             Rvalue::BinaryOp(BinOp::Eq, Box::new((Operand::Copy(alignment_bits), zero.clone()))),
         ))),
-    });
+    ));
 
     // Emit a check that asserts on the alignment and otherwise triggers a
     // AssertKind::MisalignedPointerDereference.
diff --git a/compiler/rustc_mir_transform/src/check_enums.rs b/compiler/rustc_mir_transform/src/check_enums.rs
index e06e0c6..240da87 100644
--- a/compiler/rustc_mir_transform/src/check_enums.rs
+++ b/compiler/rustc_mir_transform/src/check_enums.rs
@@ -230,11 +230,11 @@ fn split_block(
     let block_data = &mut basic_blocks[location.block];
 
     // Drain every statement after this one and move the current terminator to a new basic block.
-    let new_block = BasicBlockData {
-        statements: block_data.statements.split_off(location.statement_index),
-        terminator: block_data.terminator.take(),
-        is_cleanup: block_data.is_cleanup,
-    };
+    let new_block = BasicBlockData::new_stmts(
+        block_data.statements.split_off(location.statement_index),
+        block_data.terminator.take(),
+        block_data.is_cleanup,
+    );
 
     basic_blocks.push(new_block)
 }
@@ -270,10 +270,9 @@ fn insert_discr_cast_to_u128<'tcx>(
         let mu_array =
             local_decls.push(LocalDecl::with_source_info(mu_array_ty, source_info)).into();
         let rvalue = Rvalue::Cast(CastKind::Transmute, source_op, mu_array_ty);
-        block_data.statements.push(Statement {
-            source_info,
-            kind: StatementKind::Assign(Box::new((mu_array, rvalue))),
-        });
+        block_data
+            .statements
+            .push(Statement::new(source_info, StatementKind::Assign(Box::new((mu_array, rvalue)))));
 
         // Index into the array of MaybeUninit to get something that is actually
         // as wide as the discriminant.
@@ -294,10 +293,10 @@ fn insert_discr_cast_to_u128<'tcx>(
         let op_as_int =
             local_decls.push(LocalDecl::with_source_info(operand_int_ty, source_info)).into();
         let rvalue = Rvalue::Cast(CastKind::Transmute, source_op, operand_int_ty);
-        block_data.statements.push(Statement {
+        block_data.statements.push(Statement::new(
             source_info,
-            kind: StatementKind::Assign(Box::new((op_as_int, rvalue))),
-        });
+            StatementKind::Assign(Box::new((op_as_int, rvalue))),
+        ));
 
         (CastKind::IntToInt, Operand::Copy(op_as_int))
     };
@@ -306,10 +305,10 @@ fn insert_discr_cast_to_u128<'tcx>(
     let rvalue = Rvalue::Cast(cast_kind, discr_ty_bits, discr.ty);
     let discr_in_discr_ty =
         local_decls.push(LocalDecl::with_source_info(discr.ty, source_info)).into();
-    block_data.statements.push(Statement {
+    block_data.statements.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((discr_in_discr_ty, rvalue))),
-    });
+        StatementKind::Assign(Box::new((discr_in_discr_ty, rvalue))),
+    ));
 
     // Cast the discriminant to a u128 (base for comparisions of enum discriminants).
     let const_u128 = Ty::new_uint(tcx, ty::UintTy::U128);
@@ -317,7 +316,7 @@ fn insert_discr_cast_to_u128<'tcx>(
     let discr = local_decls.push(LocalDecl::with_source_info(const_u128, source_info)).into();
     block_data
         .statements
-        .push(Statement { source_info, kind: StatementKind::Assign(Box::new((discr, rvalue))) });
+        .push(Statement::new(source_info, StatementKind::Assign(Box::new((discr, rvalue)))));
 
     discr
 }
@@ -390,9 +389,9 @@ fn insert_uninhabited_enum_check<'tcx>(
 ) {
     let is_ok: Place<'_> =
         local_decls.push(LocalDecl::with_source_info(tcx.types.bool, source_info)).into();
-    block_data.statements.push(Statement {
+    block_data.statements.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             is_ok,
             Rvalue::Use(Operand::Constant(Box::new(ConstOperand {
                 span: source_info.span,
@@ -400,7 +399,7 @@ fn insert_uninhabited_enum_check<'tcx>(
                 const_: Const::Val(ConstValue::from_bool(false), tcx.types.bool),
             }))),
         ))),
-    });
+    ));
 
     block_data.terminator = Some(Terminator {
         source_info,
@@ -463,19 +462,19 @@ fn insert_niche_check<'tcx>(
 
     let discr_diff: Place<'_> =
         local_decls.push(LocalDecl::with_source_info(tcx.types.u128, source_info)).into();
-    block_data.statements.push(Statement {
+    block_data.statements.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             discr_diff,
             Rvalue::BinaryOp(BinOp::Sub, Box::new((Operand::Copy(discr), start_const))),
         ))),
-    });
+    ));
 
     let is_ok: Place<'_> =
         local_decls.push(LocalDecl::with_source_info(tcx.types.bool, source_info)).into();
-    block_data.statements.push(Statement {
+    block_data.statements.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             is_ok,
             Rvalue::BinaryOp(
                 // This is a `WrappingRange`, so make sure to get the wrapping right.
@@ -483,7 +482,7 @@ fn insert_niche_check<'tcx>(
                 Box::new((Operand::Copy(discr_diff), end_start_diff_const)),
             ),
         ))),
-    });
+    ));
 
     block_data.terminator = Some(Terminator {
         source_info,
diff --git a/compiler/rustc_mir_transform/src/check_null.rs b/compiler/rustc_mir_transform/src/check_null.rs
index ad74e33..e365d36 100644
--- a/compiler/rustc_mir_transform/src/check_null.rs
+++ b/compiler/rustc_mir_transform/src/check_null.rs
@@ -41,13 +41,12 @@ fn insert_null_check<'tcx>(
     let const_raw_ptr = Ty::new_imm_ptr(tcx, tcx.types.unit);
     let rvalue = Rvalue::Cast(CastKind::PtrToPtr, Operand::Copy(pointer), const_raw_ptr);
     let thin_ptr = local_decls.push(LocalDecl::with_source_info(const_raw_ptr, source_info)).into();
-    stmts
-        .push(Statement { source_info, kind: StatementKind::Assign(Box::new((thin_ptr, rvalue))) });
+    stmts.push(Statement::new(source_info, StatementKind::Assign(Box::new((thin_ptr, rvalue)))));
 
     // Transmute the pointer to a usize (equivalent to `ptr.addr()`).
     let rvalue = Rvalue::Cast(CastKind::Transmute, Operand::Copy(thin_ptr), tcx.types.usize);
     let addr = local_decls.push(LocalDecl::with_source_info(tcx.types.usize, source_info)).into();
-    stmts.push(Statement { source_info, kind: StatementKind::Assign(Box::new((addr, rvalue))) });
+    stmts.push(Statement::new(source_info, StatementKind::Assign(Box::new((addr, rvalue)))));
 
     let zero = Operand::Constant(Box::new(ConstOperand {
         span: source_info.span,
@@ -71,24 +70,24 @@ fn insert_null_check<'tcx>(
             let rvalue = Rvalue::NullaryOp(NullOp::SizeOf, pointee_ty);
             let sizeof_pointee =
                 local_decls.push(LocalDecl::with_source_info(tcx.types.usize, source_info)).into();
-            stmts.push(Statement {
+            stmts.push(Statement::new(
                 source_info,
-                kind: StatementKind::Assign(Box::new((sizeof_pointee, rvalue))),
-            });
+                StatementKind::Assign(Box::new((sizeof_pointee, rvalue))),
+            ));
 
             // Check that the pointee is not a ZST.
             let is_pointee_not_zst =
                 local_decls.push(LocalDecl::with_source_info(tcx.types.bool, source_info)).into();
-            stmts.push(Statement {
+            stmts.push(Statement::new(
                 source_info,
-                kind: StatementKind::Assign(Box::new((
+                StatementKind::Assign(Box::new((
                     is_pointee_not_zst,
                     Rvalue::BinaryOp(
                         BinOp::Ne,
                         Box::new((Operand::Copy(sizeof_pointee), zero.clone())),
                     ),
                 ))),
-            });
+            ));
 
             // Pointer needs to be checked only if pointee is not a ZST.
             Operand::Copy(is_pointee_not_zst)
@@ -97,38 +96,38 @@ fn insert_null_check<'tcx>(
 
     // Check whether the pointer is null.
     let is_null = local_decls.push(LocalDecl::with_source_info(tcx.types.bool, source_info)).into();
-    stmts.push(Statement {
+    stmts.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             is_null,
             Rvalue::BinaryOp(BinOp::Eq, Box::new((Operand::Copy(addr), zero))),
         ))),
-    });
+    ));
 
     // We want to throw an exception if the pointer is null and the pointee is not unconditionally
     // allowed (which for all non-borrow place uses, is when the pointee is ZST).
     let should_throw_exception =
         local_decls.push(LocalDecl::with_source_info(tcx.types.bool, source_info)).into();
-    stmts.push(Statement {
+    stmts.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             should_throw_exception,
             Rvalue::BinaryOp(
                 BinOp::BitAnd,
                 Box::new((Operand::Copy(is_null), pointee_should_be_checked)),
             ),
         ))),
-    });
+    ));
 
     // The final condition whether this pointer usage is ok or not.
     let is_ok = local_decls.push(LocalDecl::with_source_info(tcx.types.bool, source_info)).into();
-    stmts.push(Statement {
+    stmts.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             is_ok,
             Rvalue::UnaryOp(UnOp::Not, Operand::Copy(should_throw_exception)),
         ))),
-    });
+    ));
 
     // Emit a PointerCheck that asserts on the condition and otherwise triggers
     // a AssertKind::NullPointerDereference.
diff --git a/compiler/rustc_mir_transform/src/check_pointers.rs b/compiler/rustc_mir_transform/src/check_pointers.rs
index bf94f1a..4f913c1 100644
--- a/compiler/rustc_mir_transform/src/check_pointers.rs
+++ b/compiler/rustc_mir_transform/src/check_pointers.rs
@@ -235,11 +235,11 @@ fn split_block(
     let block_data = &mut basic_blocks[location.block];
 
     // Drain every statement after this one and move the current terminator to a new basic block.
-    let new_block = BasicBlockData {
-        statements: block_data.statements.split_off(location.statement_index),
-        terminator: block_data.terminator.take(),
-        is_cleanup: block_data.is_cleanup,
-    };
+    let new_block = BasicBlockData::new_stmts(
+        block_data.statements.split_off(location.statement_index),
+        block_data.terminator.take(),
+        block_data.is_cleanup,
+    );
 
     basic_blocks.push(new_block)
 }
diff --git a/compiler/rustc_mir_transform/src/coroutine.rs b/compiler/rustc_mir_transform/src/coroutine.rs
index 06c6b46..761d546 100644
--- a/compiler/rustc_mir_transform/src/coroutine.rs
+++ b/compiler/rustc_mir_transform/src/coroutine.rs
@@ -252,16 +252,16 @@ fn insert_none_ret_block(&self, body: &mut Body<'tcx>) -> BasicBlock {
             }
         };
 
-        let statements = vec![Statement {
-            kind: StatementKind::Assign(Box::new((Place::return_place(), none_value))),
+        let statements = vec![Statement::new(
             source_info,
-        }];
+            StatementKind::Assign(Box::new((Place::return_place(), none_value))),
+        )];
 
-        body.basic_blocks_mut().push(BasicBlockData {
+        body.basic_blocks_mut().push(BasicBlockData::new_stmts(
             statements,
-            terminator: Some(Terminator { source_info, kind: TerminatorKind::Return }),
-            is_cleanup: false,
-        });
+            Some(Terminator { source_info, kind: TerminatorKind::Return }),
+            false,
+        ));
 
         block
     }
@@ -342,10 +342,10 @@ fn make_state(
             }
         };
 
-        statements.push(Statement {
-            kind: StatementKind::Assign(Box::new((Place::return_place(), rvalue))),
+        statements.push(Statement::new(
             source_info,
-        });
+            StatementKind::Assign(Box::new((Place::return_place(), rvalue))),
+        ));
     }
 
     // Create a Place referencing a coroutine struct field
@@ -361,13 +361,13 @@ fn make_field(&self, variant_index: VariantIdx, idx: FieldIdx, ty: Ty<'tcx>) ->
     // Create a statement which changes the discriminant
     fn set_discr(&self, state_disc: VariantIdx, source_info: SourceInfo) -> Statement<'tcx> {
         let self_place = Place::from(SELF_ARG);
-        Statement {
+        Statement::new(
             source_info,
-            kind: StatementKind::SetDiscriminant {
+            StatementKind::SetDiscriminant {
                 place: Box::new(self_place),
                 variant_index: state_disc,
             },
-        }
+        )
     }
 
     // Create a statement which reads the discriminant into a temporary
@@ -377,10 +377,10 @@ fn get_discr(&self, body: &mut Body<'tcx>) -> (Statement<'tcx>, Place<'tcx>) {
         let temp = Place::from(local_decls_len);
 
         let self_place = Place::from(SELF_ARG);
-        let assign = Statement {
-            source_info: SourceInfo::outermost(body.span),
-            kind: StatementKind::Assign(Box::new((temp, Rvalue::Discriminant(self_place)))),
-        };
+        let assign = Statement::new(
+            SourceInfo::outermost(body.span),
+            StatementKind::Assign(Box::new((temp, Rvalue::Discriminant(self_place)))),
+        );
         (assign, temp)
     }
 }
@@ -450,7 +450,7 @@ fn visit_basic_block_data(&mut self, block: BasicBlock, data: &mut BasicBlockDat
                         && !self.always_live_locals.contains(l);
                     if needs_storage_dead {
                         data.statements
-                            .push(Statement { source_info, kind: StatementKind::StorageDead(l) });
+                            .push(Statement::new(source_info, StatementKind::StorageDead(l)));
                     }
                 }
 
@@ -596,10 +596,8 @@ fn eliminate_get_context_call<'tcx>(bb_data: &mut BasicBlockData<'tcx>) -> Local
     let local = arg.node.place().unwrap().local;
 
     let arg = Rvalue::Use(arg.node);
-    let assign = Statement {
-        source_info: terminator.source_info,
-        kind: StatementKind::Assign(Box::new((destination, arg))),
-    };
+    let assign =
+        Statement::new(terminator.source_info, StatementKind::Assign(Box::new((destination, arg))));
     bb_data.statements.push(assign);
     bb_data.terminator = Some(Terminator {
         source_info: terminator.source_info,
@@ -1075,11 +1073,11 @@ fn insert_switch<'tcx>(
     let source_info = SourceInfo::outermost(body.span);
     body.basic_blocks_mut().raw.insert(
         0,
-        BasicBlockData {
-            statements: vec![assign],
-            terminator: Some(Terminator { source_info, kind: switch }),
-            is_cleanup: false,
-        },
+        BasicBlockData::new_stmts(
+            vec![assign],
+            Some(Terminator { source_info, kind: switch }),
+            false,
+        ),
     );
 
     for b in body.basic_blocks_mut().iter_mut() {
@@ -1089,11 +1087,7 @@ fn insert_switch<'tcx>(
 
 fn insert_term_block<'tcx>(body: &mut Body<'tcx>, kind: TerminatorKind<'tcx>) -> BasicBlock {
     let source_info = SourceInfo::outermost(body.span);
-    body.basic_blocks_mut().push(BasicBlockData {
-        statements: Vec::new(),
-        terminator: Some(Terminator { source_info, kind }),
-        is_cleanup: false,
-    })
+    body.basic_blocks_mut().push(BasicBlockData::new(Some(Terminator { source_info, kind }), false))
 }
 
 fn return_poll_ready_assign<'tcx>(tcx: TyCtxt<'tcx>, source_info: SourceInfo) -> Statement<'tcx> {
@@ -1109,19 +1103,16 @@ fn return_poll_ready_assign<'tcx>(tcx: TyCtxt<'tcx>, source_info: SourceInfo) ->
         Box::new(AggregateKind::Adt(poll_def_id, VariantIdx::from_usize(0), args, None, None)),
         IndexVec::from_raw(vec![val]),
     );
-    Statement {
-        kind: StatementKind::Assign(Box::new((Place::return_place(), ready_val))),
-        source_info,
-    }
+    Statement::new(source_info, StatementKind::Assign(Box::new((Place::return_place(), ready_val))))
 }
 
 fn insert_poll_ready_block<'tcx>(tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) -> BasicBlock {
     let source_info = SourceInfo::outermost(body.span);
-    body.basic_blocks_mut().push(BasicBlockData {
-        statements: [return_poll_ready_assign(tcx, source_info)].to_vec(),
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::Return }),
-        is_cleanup: false,
-    })
+    body.basic_blocks_mut().push(BasicBlockData::new_stmts(
+        [return_poll_ready_assign(tcx, source_info)].to_vec(),
+        Some(Terminator { source_info, kind: TerminatorKind::Return }),
+        false,
+    ))
 }
 
 fn insert_panic_block<'tcx>(
@@ -1205,13 +1196,11 @@ fn generate_poison_block_and_redirect_unwinds_there<'tcx>(
     body: &mut Body<'tcx>,
 ) {
     let source_info = SourceInfo::outermost(body.span);
-    let poison_block = body.basic_blocks_mut().push(BasicBlockData {
-        statements: vec![
-            transform.set_discr(VariantIdx::new(CoroutineArgs::POISONED), source_info),
-        ],
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::UnwindResume }),
-        is_cleanup: true,
-    });
+    let poison_block = body.basic_blocks_mut().push(BasicBlockData::new_stmts(
+        vec![transform.set_discr(VariantIdx::new(CoroutineArgs::POISONED), source_info)],
+        Some(Terminator { source_info, kind: TerminatorKind::UnwindResume }),
+        true,
+    ));
 
     for (idx, block) in body.basic_blocks_mut().iter_enumerated_mut() {
         let source_info = block.terminator().source_info;
@@ -1345,32 +1334,28 @@ fn create_cases<'tcx>(
                         && !transform.remap.contains(l)
                         && !transform.always_live_locals.contains(l);
                     if needs_storage_live {
-                        statements
-                            .push(Statement { source_info, kind: StatementKind::StorageLive(l) });
+                        statements.push(Statement::new(source_info, StatementKind::StorageLive(l)));
                     }
                 }
 
                 if operation == Operation::Resume {
                     // Move the resume argument to the destination place of the `Yield` terminator
                     let resume_arg = CTX_ARG;
-                    statements.push(Statement {
+                    statements.push(Statement::new(
                         source_info,
-                        kind: StatementKind::Assign(Box::new((
+                        StatementKind::Assign(Box::new((
                             point.resume_arg,
                             Rvalue::Use(Operand::Move(resume_arg.into())),
                         ))),
-                    });
+                    ));
                 }
 
                 // Then jump to the real target
-                let block = body.basic_blocks_mut().push(BasicBlockData {
+                let block = body.basic_blocks_mut().push(BasicBlockData::new_stmts(
                     statements,
-                    terminator: Some(Terminator {
-                        source_info,
-                        kind: TerminatorKind::Goto { target },
-                    }),
-                    is_cleanup: false,
-                });
+                    Some(Terminator { source_info, kind: TerminatorKind::Goto { target } }),
+                    false,
+                ));
 
                 (point.state, block)
             })
@@ -1540,13 +1525,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
         let stmts = &mut body.basic_blocks_mut()[START_BLOCK].statements;
         stmts.insert(
             0,
-            Statement {
+            Statement::new(
                 source_info,
-                kind: StatementKind::Assign(Box::new((
+                StatementKind::Assign(Box::new((
                     old_resume_local.into(),
                     Rvalue::Use(Operand::Move(resume_local.into())),
                 ))),
-            },
+            ),
         );
 
         let always_live_locals = always_storage_live_locals(body);
diff --git a/compiler/rustc_mir_transform/src/coroutine/drop.rs b/compiler/rustc_mir_transform/src/coroutine/drop.rs
index dc68629..406575c 100644
--- a/compiler/rustc_mir_transform/src/coroutine/drop.rs
+++ b/compiler/rustc_mir_transform/src/coroutine/drop.rs
@@ -87,12 +87,11 @@ fn build_pin_fut<'tcx>(
         const_: Const::zero_sized(pin_fut_new_unchecked_fn),
     }));
 
-    let storage_live =
-        Statement { source_info, kind: StatementKind::StorageLive(fut_pin_place.local) };
+    let storage_live = Statement::new(source_info, StatementKind::StorageLive(fut_pin_place.local));
 
-    let fut_ref_assign = Statement {
+    let fut_ref_assign = Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             fut_ref_place,
             Rvalue::Ref(
                 tcx.lifetimes.re_erased,
@@ -100,12 +99,12 @@ fn build_pin_fut<'tcx>(
                 fut_place,
             ),
         ))),
-    };
+    );
 
     // call Pin<FutTy>::new_unchecked(&mut fut)
-    let pin_fut_bb = body.basic_blocks_mut().push(BasicBlockData {
-        statements: [storage_live, fut_ref_assign].to_vec(),
-        terminator: Some(Terminator {
+    let pin_fut_bb = body.basic_blocks_mut().push(BasicBlockData::new_stmts(
+        [storage_live, fut_ref_assign].to_vec(),
+        Some(Terminator {
             source_info,
             kind: TerminatorKind::Call {
                 func: pin_fut_new_unchecked_fn,
@@ -117,8 +116,8 @@ fn build_pin_fut<'tcx>(
                 fn_span: span,
             },
         }),
-        is_cleanup: false,
-    });
+        false,
+    ));
     (pin_fut_bb, fut_pin_place)
 }
 
@@ -156,19 +155,15 @@ fn build_poll_switch<'tcx>(
     let source_info = SourceInfo::outermost(body.span);
     let poll_discr_place =
         Place::from(body.local_decls.push(LocalDecl::new(poll_discr_ty, source_info.span)));
-    let discr_assign = Statement {
+    let discr_assign = Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
-            poll_discr_place,
-            Rvalue::Discriminant(*poll_unit_place),
-        ))),
-    };
-    let storage_dead =
-        Statement { source_info, kind: StatementKind::StorageDead(fut_pin_place.local) };
+        StatementKind::Assign(Box::new((poll_discr_place, Rvalue::Discriminant(*poll_unit_place)))),
+    );
+    let storage_dead = Statement::new(source_info, StatementKind::StorageDead(fut_pin_place.local));
     let unreachable_block = insert_term_block(body, TerminatorKind::Unreachable);
-    body.basic_blocks_mut().push(BasicBlockData {
-        statements: [storage_dead, discr_assign].to_vec(),
-        terminator: Some(Terminator {
+    body.basic_blocks_mut().push(BasicBlockData::new_stmts(
+        [storage_dead, discr_assign].to_vec(),
+        Some(Terminator {
             source_info,
             kind: TerminatorKind::SwitchInt {
                 discr: Operand::Move(poll_discr_place),
@@ -179,8 +174,8 @@ fn build_poll_switch<'tcx>(
                 ),
             },
         }),
-        is_cleanup: false,
-    })
+        false,
+    ))
 }
 
 // Gather blocks, reachable through 'drop' targets of Yield and Drop terminators (chained)
@@ -330,10 +325,10 @@ pub(super) fn expand_async_drops<'tcx>(
         let context_ref_place =
             Place::from(body.local_decls.push(LocalDecl::new(context_mut_ref, source_info.span)));
         let arg = Rvalue::Use(Operand::Move(Place::from(CTX_ARG)));
-        body[bb].statements.push(Statement {
+        body[bb].statements.push(Statement::new(
             source_info,
-            kind: StatementKind::Assign(Box::new((context_ref_place, arg))),
-        });
+            StatementKind::Assign(Box::new((context_ref_place, arg))),
+        ));
         let yield_block = insert_term_block(body, TerminatorKind::Unreachable); // `kind` replaced later to yield
         let (pin_bb, fut_pin_place) =
             build_pin_fut(tcx, body, fut_place.clone(), UnwindAction::Continue);
@@ -551,11 +546,8 @@ pub(super) fn insert_clean_drop<'tcx>(
     };
 
     // Create a block to destroy an unresumed coroutines. This can only destroy upvars.
-    body.basic_blocks_mut().push(BasicBlockData {
-        statements: Vec::new(),
-        terminator: Some(Terminator { source_info, kind: term }),
-        is_cleanup: false,
-    })
+    body.basic_blocks_mut()
+        .push(BasicBlockData::new(Some(Terminator { source_info, kind: term }), false))
 }
 
 pub(super) fn create_coroutine_drop_shim<'tcx>(
@@ -734,11 +726,7 @@ pub(super) fn create_coroutine_drop_shim_proxy_async<'tcx>(
     body.local_decls[RETURN_PLACE] = LocalDecl::with_source_info(poll_enum, source_info);
 
     // call coroutine_drop()
-    let call_bb = body.basic_blocks_mut().push(BasicBlockData {
-        statements: Vec::new(),
-        terminator: None,
-        is_cleanup: false,
-    });
+    let call_bb = body.basic_blocks_mut().push(BasicBlockData::new(None, false));
 
     // return Poll::Ready()
     let ret_bb = insert_poll_ready_block(tcx, &mut body);
diff --git a/compiler/rustc_mir_transform/src/coverage/mod.rs b/compiler/rustc_mir_transform/src/coverage/mod.rs
index 702c62e..f253d16 100644
--- a/compiler/rustc_mir_transform/src/coverage/mod.rs
+++ b/compiler/rustc_mir_transform/src/coverage/mod.rs
@@ -259,7 +259,7 @@ fn inject_statement(mir_body: &mut mir::Body<'_>, counter_kind: CoverageKind, bb
     debug!("  injecting statement {counter_kind:?} for {bb:?}");
     let data = &mut mir_body[bb];
     let source_info = data.terminator().source_info;
-    let statement = Statement { source_info, kind: StatementKind::Coverage(counter_kind) };
+    let statement = Statement::new(source_info, StatementKind::Coverage(counter_kind));
     data.statements.insert(0, statement);
 }
 
diff --git a/compiler/rustc_mir_transform/src/coverage/tests.rs b/compiler/rustc_mir_transform/src/coverage/tests.rs
index 3c0053c..b0fc5e9 100644
--- a/compiler/rustc_mir_transform/src/coverage/tests.rs
+++ b/compiler/rustc_mir_transform/src/coverage/tests.rs
@@ -68,14 +68,13 @@ fn push(&mut self, kind: TerminatorKind<'tcx>) -> BasicBlock {
             BytePos(1)
         };
         let next_hi = next_lo + BytePos(1);
-        self.blocks.push(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator {
+        self.blocks.push(BasicBlockData::new(
+            Some(Terminator {
                 source_info: SourceInfo::outermost(Span::with_root_ctxt(next_lo, next_hi)),
                 kind,
             }),
-            is_cleanup: false,
-        })
+            false,
+        ))
     }
 
     fn link(&mut self, from_block: BasicBlock, to_block: BasicBlock) {
diff --git a/compiler/rustc_mir_transform/src/ctfe_limit.rs b/compiler/rustc_mir_transform/src/ctfe_limit.rs
index d0b313e..fb17cca 100644
--- a/compiler/rustc_mir_transform/src/ctfe_limit.rs
+++ b/compiler/rustc_mir_transform/src/ctfe_limit.rs
@@ -55,8 +55,8 @@ fn has_back_edge(
 }
 
 fn insert_counter(basic_block_data: &mut BasicBlockData<'_>) {
-    basic_block_data.statements.push(Statement {
-        source_info: basic_block_data.terminator().source_info,
-        kind: StatementKind::ConstEvalCounter,
-    });
+    basic_block_data.statements.push(Statement::new(
+        basic_block_data.terminator().source_info,
+        StatementKind::ConstEvalCounter,
+    ));
 }
diff --git a/compiler/rustc_mir_transform/src/elaborate_drop.rs b/compiler/rustc_mir_transform/src/elaborate_drop.rs
index c9bc52c..de96b1f 100644
--- a/compiler/rustc_mir_transform/src/elaborate_drop.rs
+++ b/compiler/rustc_mir_transform/src/elaborate_drop.rs
@@ -222,15 +222,14 @@ fn build_async_drop(
         let span = self.source_info.span;
 
         let pin_obj_bb = bb.unwrap_or_else(|| {
-            self.elaborator.patch().new_block(BasicBlockData {
-                statements: vec![],
-                terminator: Some(Terminator {
+            self.elaborator.patch().new_block(BasicBlockData::new(
+                Some(Terminator {
                     // Temporary terminator, will be replaced by patch
                     source_info: self.source_info,
                     kind: TerminatorKind::Return,
                 }),
-                is_cleanup: false,
-            })
+                false,
+            ))
         });
 
         let (fut_ty, drop_fn_def_id, trait_args) = if call_destructor_only {
@@ -366,10 +365,8 @@ fn build_async_drop(
             call_statements.push(self.assign(obj_ptr_place, addr));
             obj_ptr_place
         };
-        call_statements.push(Statement {
-            source_info: self.source_info,
-            kind: StatementKind::StorageLive(fut.local),
-        });
+        call_statements
+            .push(Statement::new(self.source_info, StatementKind::StorageLive(fut.local)));
 
         let call_drop_bb = self.new_block_with_statements(
             unwind,
@@ -732,17 +729,17 @@ fn open_drop_for_box_contents(
 
         let do_drop_bb = self.drop_subpath(interior, interior_path, succ, unwind, dropline);
 
-        let setup_bbd = BasicBlockData {
-            statements: vec![self.assign(
+        let setup_bbd = BasicBlockData::new_stmts(
+            vec![self.assign(
                 Place::from(ptr_local),
                 Rvalue::Cast(CastKind::Transmute, Operand::Copy(nonnull_place), ptr_ty),
             )],
-            terminator: Some(Terminator {
+            Some(Terminator {
                 kind: TerminatorKind::Goto { target: do_drop_bb },
                 source_info: self.source_info,
             }),
-            is_cleanup: unwind.is_cleanup(),
-        };
+            unwind.is_cleanup(),
+        );
         self.elaborator.patch().new_block(setup_bbd)
     }
 
@@ -753,14 +750,13 @@ fn open_drop_for_adt(
         args: GenericArgsRef<'tcx>,
     ) -> BasicBlock {
         if adt.variants().is_empty() {
-            return self.elaborator.patch().new_block(BasicBlockData {
-                statements: vec![],
-                terminator: Some(Terminator {
+            return self.elaborator.patch().new_block(BasicBlockData::new(
+                Some(Terminator {
                     source_info: self.source_info,
                     kind: TerminatorKind::Unreachable,
                 }),
-                is_cleanup: self.unwind.is_cleanup(),
-            });
+                self.unwind.is_cleanup(),
+            ));
         }
 
         let skip_contents = adt.is_union() || adt.is_manually_drop();
@@ -927,9 +923,9 @@ fn adt_switch_block(
         let discr_ty = adt.repr().discr_type().to_ty(self.tcx());
         let discr = Place::from(self.new_temp(discr_ty));
         let discr_rv = Rvalue::Discriminant(self.place);
-        let switch_block = BasicBlockData {
-            statements: vec![self.assign(discr, discr_rv)],
-            terminator: Some(Terminator {
+        let switch_block = BasicBlockData::new_stmts(
+            vec![self.assign(discr, discr_rv)],
+            Some(Terminator {
                 source_info: self.source_info,
                 kind: TerminatorKind::SwitchInt {
                     discr: Operand::Move(discr),
@@ -939,8 +935,8 @@ fn adt_switch_block(
                     ),
                 },
             }),
-            is_cleanup: unwind.is_cleanup(),
-        };
+            unwind.is_cleanup(),
+        );
         let switch_block = self.elaborator.patch().new_block(switch_block);
         self.drop_flag_test_block(switch_block, succ, unwind)
     }
@@ -956,8 +952,8 @@ fn destructor_call_block_sync(&mut self, (succ, unwind): (BasicBlock, Unwind)) -
         let ref_place = self.new_temp(ref_ty);
         let unit_temp = Place::from(self.new_temp(tcx.types.unit));
 
-        let result = BasicBlockData {
-            statements: vec![self.assign(
+        let result = BasicBlockData::new_stmts(
+            vec![self.assign(
                 Place::from(ref_place),
                 Rvalue::Ref(
                     tcx.lifetimes.re_erased,
@@ -965,7 +961,7 @@ fn destructor_call_block_sync(&mut self, (succ, unwind): (BasicBlock, Unwind)) -
                     self.place,
                 ),
             )],
-            terminator: Some(Terminator {
+            Some(Terminator {
                 kind: TerminatorKind::Call {
                     func: Operand::function_handle(
                         tcx,
@@ -983,8 +979,8 @@ fn destructor_call_block_sync(&mut self, (succ, unwind): (BasicBlock, Unwind)) -
                 },
                 source_info: self.source_info,
             }),
-            is_cleanup: unwind.is_cleanup(),
-        };
+            unwind.is_cleanup(),
+        );
 
         let destructor_block = self.elaborator.patch().new_block(result);
 
@@ -1047,8 +1043,8 @@ fn drop_loop(
         let can_go = Place::from(self.new_temp(tcx.types.bool));
         let one = self.constant_usize(1);
 
-        let drop_block = BasicBlockData {
-            statements: vec![
+        let drop_block = BasicBlockData::new_stmts(
+            vec![
                 self.assign(
                     ptr,
                     Rvalue::RawPtr(RawPtrKind::Mut, tcx.mk_place_index(self.place, cur)),
@@ -1058,26 +1054,26 @@ fn drop_loop(
                     Rvalue::BinaryOp(BinOp::Add, Box::new((move_(cur.into()), one))),
                 ),
             ],
-            is_cleanup: unwind.is_cleanup(),
-            terminator: Some(Terminator {
+            Some(Terminator {
                 source_info: self.source_info,
                 // this gets overwritten by drop elaboration.
                 kind: TerminatorKind::Unreachable,
             }),
-        };
+            unwind.is_cleanup(),
+        );
         let drop_block = self.elaborator.patch().new_block(drop_block);
 
-        let loop_block = BasicBlockData {
-            statements: vec![self.assign(
+        let loop_block = BasicBlockData::new_stmts(
+            vec![self.assign(
                 can_go,
                 Rvalue::BinaryOp(BinOp::Eq, Box::new((copy(Place::from(cur)), copy(len.into())))),
             )],
-            is_cleanup: unwind.is_cleanup(),
-            terminator: Some(Terminator {
+            Some(Terminator {
                 source_info: self.source_info,
                 kind: TerminatorKind::if_(move_(can_go), succ, drop_block),
             }),
-        };
+            unwind.is_cleanup(),
+        );
         let loop_block = self.elaborator.patch().new_block(loop_block);
 
         let place = tcx.mk_place_deref(ptr);
@@ -1187,8 +1183,8 @@ enum ProjectionKind<Path> {
         let slice_ptr_ty = Ty::new_mut_ptr(tcx, slice_ty);
         let slice_ptr = self.new_temp(slice_ptr_ty);
 
-        let mut delegate_block = BasicBlockData {
-            statements: vec![
+        let mut delegate_block = BasicBlockData::new_stmts(
+            vec![
                 self.assign(Place::from(array_ptr), Rvalue::RawPtr(RawPtrKind::Mut, self.place)),
                 self.assign(
                     Place::from(slice_ptr),
@@ -1202,9 +1198,9 @@ enum ProjectionKind<Path> {
                     ),
                 ),
             ],
-            is_cleanup: self.unwind.is_cleanup(),
-            terminator: None,
-        };
+            None,
+            self.unwind.is_cleanup(),
+        );
 
         let array_place = mem::replace(
             &mut self.place,
@@ -1246,8 +1242,8 @@ fn drop_loop_trio_for_slice(&mut self, ety: Ty<'tcx>) -> BasicBlock {
         };
 
         let zero = self.constant_usize(0);
-        let block = BasicBlockData {
-            statements: vec![
+        let block = BasicBlockData::new_stmts(
+            vec![
                 self.assign(
                     len.into(),
                     Rvalue::UnaryOp(
@@ -1257,12 +1253,12 @@ fn drop_loop_trio_for_slice(&mut self, ety: Ty<'tcx>) -> BasicBlock {
                 ),
                 self.assign(cur.into(), Rvalue::Use(zero)),
             ],
-            is_cleanup: unwind.is_cleanup(),
-            terminator: Some(Terminator {
+            Some(Terminator {
                 source_info: self.source_info,
                 kind: TerminatorKind::Goto { target: loop_block },
             }),
-        };
+            unwind.is_cleanup(),
+        );
 
         let drop_block = self.elaborator.patch().new_block(block);
         // FIXME(#34708): handle partially-dropped array/slice elements.
@@ -1308,14 +1304,13 @@ fn open_drop(&mut self) -> BasicBlock {
                     self.source_info.span,
                     "open drop for unsafe binder shouldn't be encountered",
                 );
-                self.elaborator.patch().new_block(BasicBlockData {
-                    statements: vec![],
-                    terminator: Some(Terminator {
+                self.elaborator.patch().new_block(BasicBlockData::new(
+                    Some(Terminator {
                         source_info: self.source_info,
                         kind: TerminatorKind::Unreachable,
                     }),
-                    is_cleanup: self.unwind.is_cleanup(),
-                })
+                    self.unwind.is_cleanup(),
+                ))
             }
 
             _ => span_bug!(self.source_info.span, "open drop from non-ADT `{:?}`", ty),
@@ -1434,11 +1429,10 @@ fn drop_flag_test_block(
     }
 
     fn new_block(&mut self, unwind: Unwind, k: TerminatorKind<'tcx>) -> BasicBlock {
-        self.elaborator.patch().new_block(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator { source_info: self.source_info, kind: k }),
-            is_cleanup: unwind.is_cleanup(),
-        })
+        self.elaborator.patch().new_block(BasicBlockData::new(
+            Some(Terminator { source_info: self.source_info, kind: k }),
+            unwind.is_cleanup(),
+        ))
     }
 
     fn new_block_with_statements(
@@ -1447,11 +1441,11 @@ fn new_block_with_statements(
         statements: Vec<Statement<'tcx>>,
         k: TerminatorKind<'tcx>,
     ) -> BasicBlock {
-        self.elaborator.patch().new_block(BasicBlockData {
+        self.elaborator.patch().new_block(BasicBlockData::new_stmts(
             statements,
-            terminator: Some(Terminator { source_info: self.source_info, kind: k }),
-            is_cleanup: unwind.is_cleanup(),
-        })
+            Some(Terminator { source_info: self.source_info, kind: k }),
+            unwind.is_cleanup(),
+        ))
     }
 
     fn new_temp(&mut self, ty: Ty<'tcx>) -> Local {
@@ -1467,9 +1461,6 @@ fn constant_usize(&self, val: u16) -> Operand<'tcx> {
     }
 
     fn assign(&self, lhs: Place<'tcx>, rhs: Rvalue<'tcx>) -> Statement<'tcx> {
-        Statement {
-            source_info: self.source_info,
-            kind: StatementKind::Assign(Box::new((lhs, rhs))),
-        }
+        Statement::new(self.source_info, StatementKind::Assign(Box::new((lhs, rhs))))
     }
 }
diff --git a/compiler/rustc_mir_transform/src/gvn.rs b/compiler/rustc_mir_transform/src/gvn.rs
index b17b7f4..335354c 100644
--- a/compiler/rustc_mir_transform/src/gvn.rs
+++ b/compiler/rustc_mir_transform/src/gvn.rs
@@ -1636,7 +1636,7 @@ fn op_to_prop_const<'tcx>(
         }
 
         let pointer = mplace.ptr().into_pointer_or_addr().ok()?;
-        let (prov, offset) = pointer.into_parts();
+        let (prov, offset) = pointer.prov_and_relative_offset();
         let alloc_id = prov.alloc_id();
         intern_const_alloc_for_constprop(ecx, alloc_id).discard_err()?;
 
diff --git a/compiler/rustc_mir_transform/src/inline.rs b/compiler/rustc_mir_transform/src/inline.rs
index c27087f..7852bb7 100644
--- a/compiler/rustc_mir_transform/src/inline.rs
+++ b/compiler/rustc_mir_transform/src/inline.rs
@@ -900,10 +900,10 @@ fn dest_needs_borrow(place: Place<'_>) -> bool {
         );
         let dest_ty = dest.ty(caller_body, tcx);
         let temp = Place::from(new_call_temp(caller_body, callsite, dest_ty, return_block));
-        caller_body[callsite.block].statements.push(Statement {
-            source_info: callsite.source_info,
-            kind: StatementKind::Assign(Box::new((temp, dest))),
-        });
+        caller_body[callsite.block].statements.push(Statement::new(
+            callsite.source_info,
+            StatementKind::Assign(Box::new((temp, dest))),
+        ));
         tcx.mk_place_deref(temp)
     } else {
         destination
@@ -947,10 +947,9 @@ fn dest_needs_borrow(place: Place<'_>) -> bool {
     for local in callee_body.vars_and_temps_iter() {
         if integrator.always_live_locals.contains(local) {
             let new_local = integrator.map_local(local);
-            caller_body[callsite.block].statements.push(Statement {
-                source_info: callsite.source_info,
-                kind: StatementKind::StorageLive(new_local),
-            });
+            caller_body[callsite.block]
+                .statements
+                .push(Statement::new(callsite.source_info, StatementKind::StorageLive(new_local)));
         }
     }
     if let Some(block) = return_block {
@@ -958,22 +957,22 @@ fn dest_needs_borrow(place: Place<'_>) -> bool {
         // the slice once.
         let mut n = 0;
         if remap_destination {
-            caller_body[block].statements.push(Statement {
-                source_info: callsite.source_info,
-                kind: StatementKind::Assign(Box::new((
+            caller_body[block].statements.push(Statement::new(
+                callsite.source_info,
+                StatementKind::Assign(Box::new((
                     dest,
                     Rvalue::Use(Operand::Move(destination_local.into())),
                 ))),
-            });
+            ));
             n += 1;
         }
         for local in callee_body.vars_and_temps_iter().rev() {
             if integrator.always_live_locals.contains(local) {
                 let new_local = integrator.map_local(local);
-                caller_body[block].statements.push(Statement {
-                    source_info: callsite.source_info,
-                    kind: StatementKind::StorageDead(new_local),
-                });
+                caller_body[block].statements.push(Statement::new(
+                    callsite.source_info,
+                    StatementKind::StorageDead(new_local),
+                ));
                 n += 1;
             }
         }
@@ -1126,10 +1125,10 @@ fn create_temp_if_necessary<'tcx, I: Inliner<'tcx>>(
     trace!("creating temp for argument {:?}", arg);
     let arg_ty = arg.ty(caller_body, inliner.tcx());
     let local = new_call_temp(caller_body, callsite, arg_ty, return_block);
-    caller_body[callsite.block].statements.push(Statement {
-        source_info: callsite.source_info,
-        kind: StatementKind::Assign(Box::new((Place::from(local), Rvalue::Use(arg)))),
-    });
+    caller_body[callsite.block].statements.push(Statement::new(
+        callsite.source_info,
+        StatementKind::Assign(Box::new((Place::from(local), Rvalue::Use(arg)))),
+    ));
     local
 }
 
@@ -1142,19 +1141,14 @@ fn new_call_temp<'tcx>(
 ) -> Local {
     let local = caller_body.local_decls.push(LocalDecl::new(ty, callsite.source_info.span));
 
-    caller_body[callsite.block].statements.push(Statement {
-        source_info: callsite.source_info,
-        kind: StatementKind::StorageLive(local),
-    });
+    caller_body[callsite.block]
+        .statements
+        .push(Statement::new(callsite.source_info, StatementKind::StorageLive(local)));
 
     if let Some(block) = return_block {
-        caller_body[block].statements.insert(
-            0,
-            Statement {
-                source_info: callsite.source_info,
-                kind: StatementKind::StorageDead(local),
-            },
-        );
+        caller_body[block]
+            .statements
+            .insert(0, Statement::new(callsite.source_info, StatementKind::StorageDead(local)));
     }
 
     local
diff --git a/compiler/rustc_mir_transform/src/instsimplify.rs b/compiler/rustc_mir_transform/src/instsimplify.rs
index 5f0c55d..dbcaed2 100644
--- a/compiler/rustc_mir_transform/src/instsimplify.rs
+++ b/compiler/rustc_mir_transform/src/instsimplify.rs
@@ -240,15 +240,15 @@ fn simplify_primitive_clone(
 
         let Some(arg_place) = arg.node.place() else { return };
 
-        statements.push(Statement {
-            source_info: terminator.source_info,
-            kind: StatementKind::Assign(Box::new((
+        statements.push(Statement::new(
+            terminator.source_info,
+            StatementKind::Assign(Box::new((
                 *destination,
                 Rvalue::Use(Operand::Copy(
                     arg_place.project_deeper(&[ProjectionElem::Deref], self.tcx),
                 )),
             ))),
-        });
+        ));
         terminator.kind = TerminatorKind::Goto { target: *destination_block };
     }
 
diff --git a/compiler/rustc_mir_transform/src/lib.rs b/compiler/rustc_mir_transform/src/lib.rs
index c441529..08f2527 100644
--- a/compiler/rustc_mir_transform/src/lib.rs
+++ b/compiler/rustc_mir_transform/src/lib.rs
@@ -259,13 +259,13 @@ fn remap_mir_for_const_eval_select<'tcx>(
                             // (const generic stuff) so we just create a temporary and deconstruct
                             // that.
                             let local = body.local_decls.push(LocalDecl::new(ty, fn_span));
-                            bb.statements.push(Statement {
-                                source_info: SourceInfo::outermost(fn_span),
-                                kind: StatementKind::Assign(Box::new((
+                            bb.statements.push(Statement::new(
+                                SourceInfo::outermost(fn_span),
+                                StatementKind::Assign(Box::new((
                                     local.into(),
                                     Rvalue::Use(tupled_args.node.clone()),
                                 ))),
-                            });
+                            ));
                             (Operand::Move, local.into())
                         }
                         Operand::Move(place) => (Operand::Move, place),
diff --git a/compiler/rustc_mir_transform/src/lower_intrinsics.rs b/compiler/rustc_mir_transform/src/lower_intrinsics.rs
index fa29ab9..8dadce0 100644
--- a/compiler/rustc_mir_transform/src/lower_intrinsics.rs
+++ b/compiler/rustc_mir_transform/src/lower_intrinsics.rs
@@ -25,31 +25,31 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                     }
                     sym::ub_checks => {
                         let target = target.unwrap();
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::NullaryOp(NullOp::UbChecks, tcx.types.bool),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::contract_checks => {
                         let target = target.unwrap();
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::NullaryOp(NullOp::ContractChecks, tcx.types.bool),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::forget => {
                         let target = target.unwrap();
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::Use(Operand::Constant(Box::new(ConstOperand {
                                     span: terminator.source_info.span,
@@ -57,7 +57,7 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                                     const_: Const::zero_sized(tcx.types.unit),
                                 }))),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::copy_nonoverlapping => {
@@ -65,9 +65,9 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                         let Ok([src, dst, count]) = take_array(args) else {
                             bug!("Wrong arguments for copy_non_overlapping intrinsic");
                         };
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Intrinsic(Box::new(
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Intrinsic(Box::new(
                                 NonDivergingIntrinsic::CopyNonOverlapping(
                                     rustc_middle::mir::CopyNonOverlapping {
                                         src: src.node,
@@ -76,7 +76,7 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                                     },
                                 ),
                             )),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::assume => {
@@ -84,12 +84,12 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                         let Ok([arg]) = take_array(args) else {
                             bug!("Wrong arguments for assume intrinsic");
                         };
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Intrinsic(Box::new(
-                                NonDivergingIntrinsic::Assume(arg.node),
-                            )),
-                        });
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Intrinsic(Box::new(NonDivergingIntrinsic::Assume(
+                                arg.node,
+                            ))),
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::wrapping_add
@@ -121,13 +121,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                             sym::unchecked_shr => BinOp::ShrUnchecked,
                             _ => bug!("unexpected intrinsic"),
                         };
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::BinaryOp(bin_op, Box::new((lhs.node, rhs.node))),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::add_with_overflow | sym::sub_with_overflow | sym::mul_with_overflow => {
@@ -141,13 +141,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                             sym::mul_with_overflow => BinOp::MulWithOverflow,
                             _ => bug!("unexpected intrinsic"),
                         };
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::BinaryOp(bin_op, Box::new((lhs.node, rhs.node))),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::size_of | sym::align_of => {
@@ -158,13 +158,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                             sym::align_of => NullOp::AlignOf,
                             _ => bug!("unexpected intrinsic"),
                         };
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::NullaryOp(null_op, tp_ty),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::read_via_copy => {
@@ -183,13 +183,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                         };
                         // Add new statement at the end of the block that does the read, and patch
                         // up the terminator.
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::Use(Operand::Copy(derefed_place)),
                             ))),
-                        });
+                        ));
                         terminator.kind = match *target {
                             None => {
                                 // No target means this read something uninhabited,
@@ -217,13 +217,10 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                                 "Only passing a local is supported"
                             );
                         };
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
-                                derefed_place,
-                                Rvalue::Use(val.node),
-                            ))),
-                        });
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((derefed_place, Rvalue::Use(val.node)))),
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::discriminant_value => {
@@ -236,13 +233,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                         };
                         let arg = arg.node.place().unwrap();
                         let arg = tcx.mk_place_deref(arg);
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::Discriminant(arg),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::offset => {
@@ -253,13 +250,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                                 "Wrong number of arguments for offset intrinsic",
                             );
                         };
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::BinaryOp(BinOp::Offset, Box::new((ptr.node, delta.node))),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::slice_get_unchecked => {
@@ -302,10 +299,10 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                             _ => bug!("Unknown return type {ret_ty:?}"),
                         };
 
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((*destination, rvalue))),
-                        });
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((*destination, rvalue))),
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::transmute | sym::transmute_unchecked => {
@@ -320,13 +317,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                         // Always emit the cast, even if we transmute to an uninhabited type,
                         // because that lets CTFE and codegen generate better error messages
                         // when such a transmute actually ends up reachable.
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::Cast(CastKind::Transmute, arg.node, dst_ty),
                             ))),
-                        });
+                        ));
                         if let Some(target) = *target {
                             terminator.kind = TerminatorKind::Goto { target };
                         } else {
@@ -351,13 +348,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                             );
                         };
                         let fields = [data.node, meta.node];
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::Aggregate(Box::new(kind), fields.into()),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     sym::ptr_metadata => {
@@ -368,13 +365,13 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                             );
                         };
                         let target = target.unwrap();
-                        block.statements.push(Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::Assign(Box::new((
+                        block.statements.push(Statement::new(
+                            terminator.source_info,
+                            StatementKind::Assign(Box::new((
                                 *destination,
                                 Rvalue::UnaryOp(UnOp::PtrMetadata, ptr.node),
                             ))),
-                        });
+                        ));
                         terminator.kind = TerminatorKind::Goto { target };
                     }
                     _ => {}
diff --git a/compiler/rustc_mir_transform/src/lower_slice_len.rs b/compiler/rustc_mir_transform/src/lower_slice_len.rs
index aca80e3..79a9017 100644
--- a/compiler/rustc_mir_transform/src/lower_slice_len.rs
+++ b/compiler/rustc_mir_transform/src/lower_slice_len.rs
@@ -56,8 +56,7 @@ fn lower_slice_len_call<'tcx>(block: &mut BasicBlockData<'tcx>, slice_len_fn_ite
         // make new RValue for Len
         let r_value = Rvalue::UnaryOp(UnOp::PtrMetadata, arg.node.clone());
         let len_statement_kind = StatementKind::Assign(Box::new((*destination, r_value)));
-        let add_statement =
-            Statement { kind: len_statement_kind, source_info: terminator.source_info };
+        let add_statement = Statement::new(terminator.source_info, len_statement_kind);
 
         // modify terminator into simple Goto
         let new_terminator_kind = TerminatorKind::Goto { target: *bb };
diff --git a/compiler/rustc_mir_transform/src/mentioned_items.rs b/compiler/rustc_mir_transform/src/mentioned_items.rs
index 9fd8d81..f011d39 100644
--- a/compiler/rustc_mir_transform/src/mentioned_items.rs
+++ b/compiler/rustc_mir_transform/src/mentioned_items.rs
@@ -74,8 +74,7 @@ fn visit_rvalue(&mut self, rvalue: &mir::Rvalue<'tcx>, location: Location) {
         match *rvalue {
             // We need to detect unsizing casts that required vtables.
             mir::Rvalue::Cast(
-                mir::CastKind::PointerCoercion(PointerCoercion::Unsize, _)
-                | mir::CastKind::PointerCoercion(PointerCoercion::DynStar, _),
+                mir::CastKind::PointerCoercion(PointerCoercion::Unsize, _),
                 ref operand,
                 target_ty,
             ) => {
diff --git a/compiler/rustc_mir_transform/src/patch.rs b/compiler/rustc_mir_transform/src/patch.rs
index a872eae..c781d1a 100644
--- a/compiler/rustc_mir_transform/src/patch.rs
+++ b/compiler/rustc_mir_transform/src/patch.rs
@@ -78,14 +78,13 @@ pub(crate) fn resume_block(&mut self) -> BasicBlock {
             return bb;
         }
 
-        let bb = self.new_block(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator {
+        let bb = self.new_block(BasicBlockData::new(
+            Some(Terminator {
                 source_info: SourceInfo::outermost(self.body_span),
                 kind: TerminatorKind::UnwindResume,
             }),
-            is_cleanup: true,
-        });
+            true,
+        ));
         self.resume_block = Some(bb);
         bb
     }
@@ -95,14 +94,13 @@ pub(crate) fn unreachable_cleanup_block(&mut self) -> BasicBlock {
             return bb;
         }
 
-        let bb = self.new_block(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator {
+        let bb = self.new_block(BasicBlockData::new(
+            Some(Terminator {
                 source_info: SourceInfo::outermost(self.body_span),
                 kind: TerminatorKind::Unreachable,
             }),
-            is_cleanup: true,
-        });
+            true,
+        ));
         self.unreachable_cleanup_block = Some(bb);
         bb
     }
@@ -112,14 +110,13 @@ pub(crate) fn unreachable_no_cleanup_block(&mut self) -> BasicBlock {
             return bb;
         }
 
-        let bb = self.new_block(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator {
+        let bb = self.new_block(BasicBlockData::new(
+            Some(Terminator {
                 source_info: SourceInfo::outermost(self.body_span),
                 kind: TerminatorKind::Unreachable,
             }),
-            is_cleanup: false,
-        });
+            false,
+        ));
         self.unreachable_no_cleanup_block = Some(bb);
         bb
     }
@@ -131,14 +128,13 @@ pub(crate) fn terminate_block(&mut self, reason: UnwindTerminateReason) -> Basic
             return cached_bb;
         }
 
-        let bb = self.new_block(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator {
+        let bb = self.new_block(BasicBlockData::new(
+            Some(Terminator {
                 source_info: SourceInfo::outermost(self.body_span),
                 kind: TerminatorKind::UnwindTerminate(reason),
             }),
-            is_cleanup: true,
-        });
+            true,
+        ));
         self.terminate_block = Some((bb, reason));
         bb
     }
@@ -280,7 +276,7 @@ pub(crate) fn apply(self, body: &mut Body<'tcx>) {
             let source_info = Self::source_info_for_index(&body[loc.block], loc);
             body[loc.block]
                 .statements
-                .insert(loc.statement_index, Statement { source_info, kind: stmt });
+                .insert(loc.statement_index, Statement::new(source_info, stmt));
             delta += 1;
         }
     }
diff --git a/compiler/rustc_mir_transform/src/promote_consts.rs b/compiler/rustc_mir_transform/src/promote_consts.rs
index 47d4383..4e8f30e 100644
--- a/compiler/rustc_mir_transform/src/promote_consts.rs
+++ b/compiler/rustc_mir_transform/src/promote_consts.rs
@@ -731,23 +731,22 @@ struct Promoter<'a, 'tcx> {
 impl<'a, 'tcx> Promoter<'a, 'tcx> {
     fn new_block(&mut self) -> BasicBlock {
         let span = self.promoted.span;
-        self.promoted.basic_blocks_mut().push(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator {
+        self.promoted.basic_blocks_mut().push(BasicBlockData::new(
+            Some(Terminator {
                 source_info: SourceInfo::outermost(span),
                 kind: TerminatorKind::Return,
             }),
-            is_cleanup: false,
-        })
+            false,
+        ))
     }
 
     fn assign(&mut self, dest: Local, rvalue: Rvalue<'tcx>, span: Span) {
         let last = self.promoted.basic_blocks.last_index().unwrap();
         let data = &mut self.promoted[last];
-        data.statements.push(Statement {
-            source_info: SourceInfo::outermost(span),
-            kind: StatementKind::Assign(Box::new((Place::from(dest), rvalue))),
-        });
+        data.statements.push(Statement::new(
+            SourceInfo::outermost(span),
+            StatementKind::Assign(Box::new((Place::from(dest), rvalue))),
+        ));
     }
 
     fn is_temp_kind(&self, local: Local) -> bool {
@@ -914,13 +913,13 @@ fn promote_candidate(
             assert_eq!(self.temps.push(TempState::Unpromotable), promoted_ref);
 
             let promoted_operand = promoted_operand(ref_ty, span);
-            let promoted_ref_statement = Statement {
-                source_info: statement.source_info,
-                kind: StatementKind::Assign(Box::new((
+            let promoted_ref_statement = Statement::new(
+                statement.source_info,
+                StatementKind::Assign(Box::new((
                     Place::from(promoted_ref),
                     Rvalue::Use(Operand::Constant(Box::new(promoted_operand))),
                 ))),
-            };
+            );
             self.extra_statements.push((loc, promoted_ref_statement));
 
             (
diff --git a/compiler/rustc_mir_transform/src/shim.rs b/compiler/rustc_mir_transform/src/shim.rs
index 6d45bbc..4083038 100644
--- a/compiler/rustc_mir_transform/src/shim.rs
+++ b/compiler/rustc_mir_transform/src/shim.rs
@@ -323,9 +323,7 @@ fn dropee_emit_retag<'tcx>(
             StatementKind::Retag(RetagKind::FnEntry, Box::new(dropee_ptr)),
         ];
         for s in new_statements {
-            body.basic_blocks_mut()[START_BLOCK]
-                .statements
-                .push(Statement { source_info, kind: s });
+            body.basic_blocks_mut()[START_BLOCK].statements.push(Statement::new(source_info, s));
         }
     }
     dropee_ptr
@@ -350,11 +348,7 @@ fn build_drop_shim<'tcx>(tcx: TyCtxt<'tcx>, def_id: DefId, ty: Option<Ty<'tcx>>)
     let return_block = BasicBlock::new(1);
     let mut blocks = IndexVec::with_capacity(2);
     let block = |blocks: &mut IndexVec<_, _>, kind| {
-        blocks.push(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator { source_info, kind }),
-            is_cleanup: false,
-        })
+        blocks.push(BasicBlockData::new(Some(Terminator { source_info, kind }), false))
     };
     block(&mut blocks, TerminatorKind::Goto { target: return_block });
     block(&mut blocks, TerminatorKind::Return);
@@ -515,17 +509,17 @@ fn build_thread_local_shim<'tcx>(
     let span = tcx.def_span(def_id);
     let source_info = SourceInfo::outermost(span);
 
-    let blocks = IndexVec::from_raw(vec![BasicBlockData {
-        statements: vec![Statement {
+    let blocks = IndexVec::from_raw(vec![BasicBlockData::new_stmts(
+        vec![Statement::new(
             source_info,
-            kind: StatementKind::Assign(Box::new((
+            StatementKind::Assign(Box::new((
                 Place::return_place(),
                 Rvalue::ThreadLocalRef(def_id),
             ))),
-        }],
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::Return }),
-        is_cleanup: false,
-    }]);
+        )],
+        Some(Terminator { source_info, kind: TerminatorKind::Return }),
+        false,
+    )]);
 
     new_body(
         MirSource::from_instance(instance),
@@ -609,11 +603,11 @@ fn block(
         is_cleanup: bool,
     ) -> BasicBlock {
         let source_info = self.source_info();
-        self.blocks.push(BasicBlockData {
+        self.blocks.push(BasicBlockData::new_stmts(
             statements,
-            terminator: Some(Terminator { source_info, kind }),
+            Some(Terminator { source_info, kind }),
             is_cleanup,
-        })
+        ))
     }
 
     /// Gives the index of an upcoming BasicBlock, with an offset.
@@ -625,7 +619,7 @@ fn block_index_offset(&self, offset: usize) -> BasicBlock {
     }
 
     fn make_statement(&self, kind: StatementKind<'tcx>) -> Statement<'tcx> {
-        Statement { source_info: self.source_info(), kind }
+        Statement::new(self.source_info(), kind)
     }
 
     fn copy_shim(&mut self) {
@@ -901,13 +895,13 @@ fn build_call_shim<'tcx>(
                 .immutable(),
             );
             let borrow_kind = BorrowKind::Mut { kind: MutBorrowKind::Default };
-            statements.push(Statement {
+            statements.push(Statement::new(
                 source_info,
-                kind: StatementKind::Assign(Box::new((
+                StatementKind::Assign(Box::new((
                     Place::from(ref_rcvr),
                     Rvalue::Ref(tcx.lifetimes.re_erased, borrow_kind, rcvr_place()),
                 ))),
-            });
+            ));
             Operand::Move(Place::from(ref_rcvr))
         }
     });
@@ -956,11 +950,11 @@ fn build_call_shim<'tcx>(
     let n_blocks = if let Some(Adjustment::RefMut) = rcvr_adjustment { 5 } else { 2 };
     let mut blocks = IndexVec::with_capacity(n_blocks);
     let block = |blocks: &mut IndexVec<_, _>, statements, kind, is_cleanup| {
-        blocks.push(BasicBlockData {
+        blocks.push(BasicBlockData::new_stmts(
             statements,
-            terminator: Some(Terminator { source_info, kind }),
+            Some(Terminator { source_info, kind }),
             is_cleanup,
-        })
+        ))
     };
 
     // BB #0
@@ -1071,8 +1065,9 @@ pub(super) fn build_adt_ctor(tcx: TyCtxt<'_>, ctor_id: DefId) -> Body<'_> {
 
     let kind = AggregateKind::Adt(adt_def.did(), variant_index, args, None, None);
     let variant = adt_def.variant(variant_index);
-    let statement = Statement {
-        kind: StatementKind::Assign(Box::new((
+    let statement = Statement::new(
+        source_info,
+        StatementKind::Assign(Box::new((
             Place::return_place(),
             Rvalue::Aggregate(
                 Box::new(kind),
@@ -1081,14 +1076,13 @@ pub(super) fn build_adt_ctor(tcx: TyCtxt<'_>, ctor_id: DefId) -> Body<'_> {
                     .collect(),
             ),
         ))),
-        source_info,
-    };
+    );
 
-    let start_block = BasicBlockData {
-        statements: vec![statement],
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::Return }),
-        is_cleanup: false,
-    };
+    let start_block = BasicBlockData::new_stmts(
+        vec![statement],
+        Some(Terminator { source_info, kind: TerminatorKind::Return }),
+        false,
+    );
 
     let source = MirSource::item(ctor_id);
     let mut body = new_body(
@@ -1130,16 +1124,16 @@ fn build_fn_ptr_addr_shim<'tcx>(tcx: TyCtxt<'tcx>, def_id: DefId, self_ty: Ty<'t
         Operand::Move(Place::from(Local::new(1))),
         Ty::new_imm_ptr(tcx, tcx.types.unit),
     );
-    let stmt = Statement {
+    let stmt = Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((Place::return_place(), rvalue))),
-    };
+        StatementKind::Assign(Box::new((Place::return_place(), rvalue))),
+    );
     let statements = vec![stmt];
-    let start_block = BasicBlockData {
+    let start_block = BasicBlockData::new_stmts(
         statements,
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::Return }),
-        is_cleanup: false,
-    };
+        Some(Terminator { source_info, kind: TerminatorKind::Return }),
+        false,
+    );
     let source = MirSource::from_instance(ty::InstanceKind::FnPtrAddrShim(def_id, self_ty));
     new_body(source, IndexVec::from_elem_n(start_block, 1), locals, sig.inputs().len(), span)
 }
@@ -1230,16 +1224,16 @@ fn build_construct_coroutine_by_move_shim<'tcx>(
         Box::new(AggregateKind::Coroutine(coroutine_def_id, coroutine_args)),
         IndexVec::from_raw(fields),
     );
-    let stmt = Statement {
+    let stmt = Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((Place::return_place(), rvalue))),
-    };
+        StatementKind::Assign(Box::new((Place::return_place(), rvalue))),
+    );
     let statements = vec![stmt];
-    let start_block = BasicBlockData {
+    let start_block = BasicBlockData::new_stmts(
         statements,
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::Return }),
-        is_cleanup: false,
-    };
+        Some(Terminator { source_info, kind: TerminatorKind::Return }),
+        false,
+    );
 
     let source = MirSource::from_instance(ty::InstanceKind::ConstructCoroutineInClosureShim {
         coroutine_closure_def_id,
diff --git a/compiler/rustc_mir_transform/src/shim/async_destructor_ctor.rs b/compiler/rustc_mir_transform/src/shim/async_destructor_ctor.rs
index fd7b736..18d0947 100644
--- a/compiler/rustc_mir_transform/src/shim/async_destructor_ctor.rs
+++ b/compiler/rustc_mir_transform/src/shim/async_destructor_ctor.rs
@@ -88,11 +88,7 @@ pub(super) fn build_async_drop_shim<'tcx>(
     let return_block = BasicBlock::new(1);
     let mut blocks = IndexVec::with_capacity(2);
     let block = |blocks: &mut IndexVec<_, _>, kind| {
-        blocks.push(BasicBlockData {
-            statements: vec![],
-            terminator: Some(Terminator { source_info, kind }),
-            is_cleanup: false,
-        })
+        blocks.push(BasicBlockData::new(Some(Terminator { source_info, kind }), false))
     };
     block(
         &mut blocks,
@@ -133,7 +129,7 @@ pub(super) fn build_async_drop_shim<'tcx>(
         dropee_ptr,
         Rvalue::Use(Operand::Move(coroutine_layout_dropee)),
     )));
-    body.basic_blocks_mut()[START_BLOCK].statements.push(Statement { source_info, kind: st_kind });
+    body.basic_blocks_mut()[START_BLOCK].statements.push(Statement::new(source_info, st_kind));
     dropee_ptr = dropee_emit_retag(tcx, &mut body, dropee_ptr, span);
 
     let dropline = body.basic_blocks.last_index();
@@ -240,13 +236,13 @@ fn build_adrop_for_coroutine_shim<'tcx>(
             .project_deeper(&[PlaceElem::Field(FieldIdx::ZERO, proxy_ref)], tcx);
         body.basic_blocks_mut()[START_BLOCK].statements.insert(
             idx,
-            Statement {
+            Statement::new(
                 source_info,
-                kind: StatementKind::Assign(Box::new((
+                StatementKind::Assign(Box::new((
                     Place::from(proxy_ref_local),
                     Rvalue::CopyForDeref(proxy_ref_place),
                 ))),
-            },
+            ),
         );
         idx += 1;
         let mut cor_ptr_local = proxy_ref_local;
@@ -261,13 +257,13 @@ fn build_adrop_for_coroutine_shim<'tcx>(
                 // _cor_ptr = _proxy.0.0 (... .0)
                 body.basic_blocks_mut()[START_BLOCK].statements.insert(
                     idx,
-                    Statement {
+                    Statement::new(
                         source_info,
-                        kind: StatementKind::Assign(Box::new((
+                        StatementKind::Assign(Box::new((
                             Place::from(cor_ptr_local),
                             Rvalue::CopyForDeref(impl_ptr_place),
                         ))),
-                    },
+                    ),
                 );
                 idx += 1;
             }
@@ -281,10 +277,10 @@ fn build_adrop_for_coroutine_shim<'tcx>(
         );
         body.basic_blocks_mut()[START_BLOCK].statements.insert(
             idx,
-            Statement {
+            Statement::new(
                 source_info,
-                kind: StatementKind::Assign(Box::new((Place::from(cor_ref_local), reborrow))),
-            },
+                StatementKind::Assign(Box::new((Place::from(cor_ref_local), reborrow))),
+            ),
         );
     }
     body
@@ -334,13 +330,13 @@ fn build_adrop_for_adrop_shim<'tcx>(
 
     let mut statements = Vec::new();
 
-    statements.push(Statement {
+    statements.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((
+        StatementKind::Assign(Box::new((
             Place::from(proxy_ref_local),
             Rvalue::CopyForDeref(proxy_ref_place),
         ))),
-    });
+    ));
 
     let mut cor_ptr_local = proxy_ref_local;
     proxy_ty.find_async_drop_impl_coroutine(tcx, |ty| {
@@ -350,13 +346,13 @@ fn build_adrop_for_adrop_shim<'tcx>(
                 .project_deeper(&[PlaceElem::Deref, PlaceElem::Field(FieldIdx::ZERO, ty_ptr)], tcx);
             cor_ptr_local = locals.push(LocalDecl::new(ty_ptr, span));
             // _cor_ptr = _proxy.0.0 (... .0)
-            statements.push(Statement {
+            statements.push(Statement::new(
                 source_info,
-                kind: StatementKind::Assign(Box::new((
+                StatementKind::Assign(Box::new((
                     Place::from(cor_ptr_local),
                     Rvalue::CopyForDeref(impl_ptr_place),
                 ))),
-            });
+            ));
         }
     });
 
@@ -367,10 +363,10 @@ fn build_adrop_for_adrop_shim<'tcx>(
         tcx.mk_place_deref(Place::from(cor_ptr_local)),
     );
     let cor_ref_place = Place::from(locals.push(LocalDecl::new(cor_ref, span)));
-    statements.push(Statement {
+    statements.push(Statement::new(
         source_info,
-        kind: StatementKind::Assign(Box::new((cor_ref_place, reborrow))),
-    });
+        StatementKind::Assign(Box::new((cor_ref_place, reborrow))),
+    ));
 
     // cor_pin_ty = `Pin<&mut cor_ref>`
     let cor_pin_ty = Ty::new_adt(tcx, pin_adt_ref, tcx.mk_args(&[cor_ref.into()]));
@@ -378,9 +374,9 @@ fn build_adrop_for_adrop_shim<'tcx>(
 
     let pin_fn = tcx.require_lang_item(LangItem::PinNewUnchecked, span);
     // call Pin<FutTy>::new_unchecked(&mut impl_cor)
-    blocks.push(BasicBlockData {
+    blocks.push(BasicBlockData::new_stmts(
         statements,
-        terminator: Some(Terminator {
+        Some(Terminator {
             source_info,
             kind: TerminatorKind::Call {
                 func: Operand::function_handle(tcx, pin_fn, [cor_ref.into()], span),
@@ -392,15 +388,14 @@ fn build_adrop_for_adrop_shim<'tcx>(
                 fn_span: span,
             },
         }),
-        is_cleanup: false,
-    });
+        false,
+    ));
     // When dropping async drop coroutine, we continue its execution:
     // we call impl::poll (impl_layout, ctx)
     let poll_fn = tcx.require_lang_item(LangItem::FuturePoll, span);
     let resume_ctx = Place::from(Local::new(2));
-    blocks.push(BasicBlockData {
-        statements: vec![],
-        terminator: Some(Terminator {
+    blocks.push(BasicBlockData::new(
+        Some(Terminator {
             source_info,
             kind: TerminatorKind::Call {
                 func: Operand::function_handle(tcx, poll_fn, [impl_ty.into()], span),
@@ -416,13 +411,12 @@ fn build_adrop_for_adrop_shim<'tcx>(
                 fn_span: span,
             },
         }),
-        is_cleanup: false,
-    });
-    blocks.push(BasicBlockData {
-        statements: vec![],
-        terminator: Some(Terminator { source_info, kind: TerminatorKind::Return }),
-        is_cleanup: false,
-    });
+        false,
+    ));
+    blocks.push(BasicBlockData::new(
+        Some(Terminator { source_info, kind: TerminatorKind::Return }),
+        false,
+    ));
 
     let source = MirSource::from_instance(instance);
     let mut body = new_body(source, blocks, locals, sig.inputs().len(), span);
diff --git a/compiler/rustc_mir_transform/src/simplify_comparison_integral.rs b/compiler/rustc_mir_transform/src/simplify_comparison_integral.rs
index bd008230..c60eb56 100644
--- a/compiler/rustc_mir_transform/src/simplify_comparison_integral.rs
+++ b/compiler/rustc_mir_transform/src/simplify_comparison_integral.rs
@@ -115,10 +115,10 @@ fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
                 for bb_idx in new_targets.all_targets() {
                     storage_deads_to_insert.push((
                         *bb_idx,
-                        Statement {
-                            source_info: terminator.source_info,
-                            kind: StatementKind::StorageDead(opt.to_switch_on.local),
-                        },
+                        Statement::new(
+                            terminator.source_info,
+                            StatementKind::StorageDead(opt.to_switch_on.local),
+                        ),
                     ));
                 }
             }
diff --git a/compiler/rustc_mir_transform/src/validate.rs b/compiler/rustc_mir_transform/src/validate.rs
index 7dcdd79..cbb9bbf 100644
--- a/compiler/rustc_mir_transform/src/validate.rs
+++ b/compiler/rustc_mir_transform/src/validate.rs
@@ -1260,9 +1260,6 @@ macro_rules! check_kinds {
                             self.fail(location, format!("Unsize coercion, but `{op_ty}` isn't coercible to `{target_type}`"));
                         }
                     }
-                    CastKind::PointerCoercion(PointerCoercion::DynStar, _) => {
-                        // FIXME(dyn-star): make sure nothing needs to be done here.
-                    }
                     CastKind::IntToInt | CastKind::IntToFloat => {
                         let input_valid = op_ty.is_integral() || op_ty.is_char() || op_ty.is_bool();
                         let target_valid = target_type.is_numeric() || target_type.is_char();
diff --git a/compiler/rustc_monomorphize/src/collector.rs b/compiler/rustc_monomorphize/src/collector.rs
index 798f4da..91e371d 100644
--- a/compiler/rustc_monomorphize/src/collector.rs
+++ b/compiler/rustc_monomorphize/src/collector.rs
@@ -694,8 +694,7 @@ fn visit_rvalue(&mut self, rvalue: &mir::Rvalue<'tcx>, location: Location) {
             // have to instantiate all methods of the trait being cast to, so we
             // can build the appropriate vtable.
             mir::Rvalue::Cast(
-                mir::CastKind::PointerCoercion(PointerCoercion::Unsize, _)
-                | mir::CastKind::PointerCoercion(PointerCoercion::DynStar, _),
+                mir::CastKind::PointerCoercion(PointerCoercion::Unsize, _),
                 ref operand,
                 target_ty,
             ) => {
@@ -710,9 +709,7 @@ fn visit_rvalue(&mut self, rvalue: &mir::Rvalue<'tcx>, location: Location) {
                 // This could also be a different Unsize instruction, like
                 // from a fixed sized array to a slice. But we are only
                 // interested in things that produce a vtable.
-                if (target_ty.is_trait() && !source_ty.is_trait())
-                    || (target_ty.is_dyn_star() && !source_ty.is_dyn_star())
-                {
+                if target_ty.is_trait() && !source_ty.is_trait() {
                     create_mono_items_for_vtable_methods(
                         self.tcx,
                         target_ty,
@@ -1109,14 +1106,6 @@ fn find_tails_for_unsizing<'tcx>(
             find_tails_for_unsizing(tcx, source_field, target_field)
         }
 
-        // `T` as `dyn* Trait` unsizes *directly*.
-        //
-        // FIXME(dyn_star): This case is a bit awkward, b/c we're not really computing
-        // a tail here. We probably should handle this separately in the *caller* of
-        // this function, rather than returning something that is semantically different
-        // than what we return above.
-        (_, &ty::Dynamic(_, _, ty::DynStar)) => (source_ty, target_ty),
-
         _ => bug!(
             "find_vtable_types_for_unsizing: invalid coercion {:?} -> {:?}",
             source_ty,
@@ -1344,9 +1333,7 @@ fn visit_mentioned_item<'tcx>(
             // This could also be a different Unsize instruction, like
             // from a fixed sized array to a slice. But we are only
             // interested in things that produce a vtable.
-            if (target_ty.is_trait() && !source_ty.is_trait())
-                || (target_ty.is_dyn_star() && !source_ty.is_dyn_star())
-            {
+            if target_ty.is_trait() && !source_ty.is_trait() {
                 create_mono_items_for_vtable_methods(tcx, target_ty, source_ty, span, output);
             }
         }
diff --git a/compiler/rustc_next_trait_solver/src/lib.rs b/compiler/rustc_next_trait_solver/src/lib.rs
index e3f42c1..d3965e1 100644
--- a/compiler/rustc_next_trait_solver/src/lib.rs
+++ b/compiler/rustc_next_trait_solver/src/lib.rs
@@ -5,9 +5,9 @@
 //! So if you got to this crate from the old solver, it's totally normal.
 
 // tidy-alphabetical-start
+#![allow(rustc::direct_use_of_rustc_type_ir)]
 #![allow(rustc::usage_of_type_ir_inherent)]
 #![allow(rustc::usage_of_type_ir_traits)]
-#![cfg_attr(not(bootstrap), allow(rustc::direct_use_of_rustc_type_ir))]
 // tidy-alphabetical-end
 
 pub mod canonicalizer;
diff --git a/compiler/rustc_next_trait_solver/src/solve/assembly/mod.rs b/compiler/rustc_next_trait_solver/src/solve/assembly/mod.rs
index a300558..c281ef2 100644
--- a/compiler/rustc_next_trait_solver/src/solve/assembly/mod.rs
+++ b/compiler/rustc_next_trait_solver/src/solve/assembly/mod.rs
@@ -383,10 +383,10 @@ pub(super) fn assemble_and_evaluate_candidates<G: GoalKind<D>>(
 
         let mut candidates = vec![];
 
-        if let TypingMode::Coherence = self.typing_mode() {
-            if let Ok(candidate) = self.consider_coherence_unknowable_candidate(goal) {
-                return vec![candidate];
-            }
+        if let TypingMode::Coherence = self.typing_mode()
+            && let Ok(candidate) = self.consider_coherence_unknowable_candidate(goal)
+        {
+            return vec![candidate];
         }
 
         self.assemble_alias_bound_candidates(goal, &mut candidates);
diff --git a/compiler/rustc_next_trait_solver/src/solve/assembly/structural_traits.rs b/compiler/rustc_next_trait_solver/src/solve/assembly/structural_traits.rs
index 5b6f978..c0bebdf 100644
--- a/compiler/rustc_next_trait_solver/src/solve/assembly/structural_traits.rs
+++ b/compiler/rustc_next_trait_solver/src/solve/assembly/structural_traits.rs
@@ -135,7 +135,6 @@ pub(in crate::solve) fn instantiate_constituent_tys_for_sizedness_trait<D, I>(
         | ty::Closure(..)
         | ty::CoroutineClosure(..)
         | ty::Never
-        | ty::Dynamic(_, _, ty::DynStar)
         | ty::Error(_) => Ok(ty::Binder::dummy(vec![])),
 
         // impl {Meta,}Sized for str, [T], dyn Trait
@@ -997,12 +996,12 @@ fn cx(&self) -> I {
     }
 
     fn try_fold_ty(&mut self, ty: I::Ty) -> Result<I::Ty, Ambiguous> {
-        if let ty::Alias(ty::Projection, alias_ty) = ty.kind() {
-            if let Some(term) = self.try_eagerly_replace_alias(alias_ty.into())? {
-                return Ok(term.expect_ty());
-            }
+        if let ty::Alias(ty::Projection, alias_ty) = ty.kind()
+            && let Some(term) = self.try_eagerly_replace_alias(alias_ty.into())?
+        {
+            Ok(term.expect_ty())
+        } else {
+            ty.try_super_fold_with(self)
         }
-
-        ty.try_super_fold_with(self)
     }
 }
diff --git a/compiler/rustc_next_trait_solver/src/solve/effect_goals.rs b/compiler/rustc_next_trait_solver/src/solve/effect_goals.rs
index 0547eb7..42264f5 100644
--- a/compiler/rustc_next_trait_solver/src/solve/effect_goals.rs
+++ b/compiler/rustc_next_trait_solver/src/solve/effect_goals.rs
@@ -42,20 +42,18 @@ fn fast_reject_assumption(
         goal: Goal<I, Self>,
         assumption: I::Clause,
     ) -> Result<(), NoSolution> {
-        if let Some(host_clause) = assumption.as_host_effect_clause() {
-            if host_clause.def_id() == goal.predicate.def_id()
-                && host_clause.constness().satisfies(goal.predicate.constness)
-            {
-                if DeepRejectCtxt::relate_rigid_rigid(ecx.cx()).args_may_unify(
-                    goal.predicate.trait_ref.args,
-                    host_clause.skip_binder().trait_ref.args,
-                ) {
-                    return Ok(());
-                }
-            }
+        if let Some(host_clause) = assumption.as_host_effect_clause()
+            && host_clause.def_id() == goal.predicate.def_id()
+            && host_clause.constness().satisfies(goal.predicate.constness)
+            && DeepRejectCtxt::relate_rigid_rigid(ecx.cx()).args_may_unify(
+                goal.predicate.trait_ref.args,
+                host_clause.skip_binder().trait_ref.args,
+            )
+        {
+            Ok(())
+        } else {
+            Err(NoSolution)
         }
-
-        Err(NoSolution)
     }
 
     fn match_assumption(
diff --git a/compiler/rustc_next_trait_solver/src/solve/eval_ctxt/mod.rs b/compiler/rustc_next_trait_solver/src/solve/eval_ctxt/mod.rs
index dd9ccad..b425876 100644
--- a/compiler/rustc_next_trait_solver/src/solve/eval_ctxt/mod.rs
+++ b/compiler/rustc_next_trait_solver/src/solve/eval_ctxt/mod.rs
@@ -429,22 +429,21 @@ pub(super) fn evaluate_goal_raw(
         // If we have run this goal before, and it was stalled, check that any of the goal's
         // args have changed. Otherwise, we don't need to re-run the goal because it'll remain
         // stalled, since it'll canonicalize the same way and evaluation is pure.
-        if let Some(stalled_on) = stalled_on {
-            if !stalled_on.stalled_vars.iter().any(|value| self.delegate.is_changed_arg(*value))
-                && !self
-                    .delegate
-                    .opaque_types_storage_num_entries()
-                    .needs_reevaluation(stalled_on.num_opaques)
-            {
-                return Ok((
-                    NestedNormalizationGoals::empty(),
-                    GoalEvaluation {
-                        certainty: Certainty::Maybe(stalled_on.stalled_cause),
-                        has_changed: HasChanged::No,
-                        stalled_on: Some(stalled_on),
-                    },
-                ));
-            }
+        if let Some(stalled_on) = stalled_on
+            && !stalled_on.stalled_vars.iter().any(|value| self.delegate.is_changed_arg(*value))
+            && !self
+                .delegate
+                .opaque_types_storage_num_entries()
+                .needs_reevaluation(stalled_on.num_opaques)
+        {
+            return Ok((
+                NestedNormalizationGoals::empty(),
+                GoalEvaluation {
+                    certainty: Certainty::Maybe(stalled_on.stalled_cause),
+                    has_changed: HasChanged::No,
+                    stalled_on: Some(stalled_on),
+                },
+            ));
         }
 
         let (orig_values, canonical_goal) = self.canonicalize_goal(goal);
@@ -833,14 +832,11 @@ fn visit_ty(&mut self, t: I::Ty) -> Self::Result {
 
                 match t.kind() {
                     ty::Infer(ty::TyVar(vid)) => {
-                        if let ty::TermKind::Ty(term) = self.term.kind() {
-                            if let ty::Infer(ty::TyVar(term_vid)) = term.kind() {
-                                if self.delegate.root_ty_var(vid)
-                                    == self.delegate.root_ty_var(term_vid)
-                                {
-                                    return ControlFlow::Break(());
-                                }
-                            }
+                        if let ty::TermKind::Ty(term) = self.term.kind()
+                            && let ty::Infer(ty::TyVar(term_vid)) = term.kind()
+                            && self.delegate.root_ty_var(vid) == self.delegate.root_ty_var(term_vid)
+                        {
+                            return ControlFlow::Break(());
                         }
 
                         self.check_nameable(self.delegate.universe_of_ty(vid).unwrap())?;
@@ -860,15 +856,12 @@ fn visit_ty(&mut self, t: I::Ty) -> Self::Result {
             fn visit_const(&mut self, c: I::Const) -> Self::Result {
                 match c.kind() {
                     ty::ConstKind::Infer(ty::InferConst::Var(vid)) => {
-                        if let ty::TermKind::Const(term) = self.term.kind() {
-                            if let ty::ConstKind::Infer(ty::InferConst::Var(term_vid)) = term.kind()
-                            {
-                                if self.delegate.root_const_var(vid)
-                                    == self.delegate.root_const_var(term_vid)
-                                {
-                                    return ControlFlow::Break(());
-                                }
-                            }
+                        if let ty::TermKind::Const(term) = self.term.kind()
+                            && let ty::ConstKind::Infer(ty::InferConst::Var(term_vid)) = term.kind()
+                            && self.delegate.root_const_var(vid)
+                                == self.delegate.root_const_var(term_vid)
+                        {
+                            return ControlFlow::Break(());
                         }
 
                         self.check_nameable(self.delegate.universe_of_ct(vid).unwrap())
diff --git a/compiler/rustc_next_trait_solver/src/solve/normalizes_to/mod.rs b/compiler/rustc_next_trait_solver/src/solve/normalizes_to/mod.rs
index d51c87f..1e0a90e 100644
--- a/compiler/rustc_next_trait_solver/src/solve/normalizes_to/mod.rs
+++ b/compiler/rustc_next_trait_solver/src/solve/normalizes_to/mod.rs
@@ -112,18 +112,17 @@ fn fast_reject_assumption(
         goal: Goal<I, Self>,
         assumption: I::Clause,
     ) -> Result<(), NoSolution> {
-        if let Some(projection_pred) = assumption.as_projection_clause() {
-            if projection_pred.item_def_id() == goal.predicate.def_id() {
-                if DeepRejectCtxt::relate_rigid_rigid(ecx.cx()).args_may_unify(
-                    goal.predicate.alias.args,
-                    projection_pred.skip_binder().projection_term.args,
-                ) {
-                    return Ok(());
-                }
-            }
+        if let Some(projection_pred) = assumption.as_projection_clause()
+            && projection_pred.item_def_id() == goal.predicate.def_id()
+            && DeepRejectCtxt::relate_rigid_rigid(ecx.cx()).args_may_unify(
+                goal.predicate.alias.args,
+                projection_pred.skip_binder().projection_term.args,
+            )
+        {
+            Ok(())
+        } else {
+            Err(NoSolution)
         }
-
-        Err(NoSolution)
     }
 
     fn match_assumption(
@@ -658,8 +657,7 @@ fn consider_builtin_pointee_candidate(
             | ty::Coroutine(..)
             | ty::CoroutineWitness(..)
             | ty::Never
-            | ty::Foreign(..)
-            | ty::Dynamic(_, _, ty::DynStar) => Ty::new_unit(cx),
+            | ty::Foreign(..) => Ty::new_unit(cx),
 
             ty::Error(e) => Ty::new_error(cx, e),
 
diff --git a/compiler/rustc_next_trait_solver/src/solve/trait_goals.rs b/compiler/rustc_next_trait_solver/src/solve/trait_goals.rs
index 8aaa8e9..6c9fb63 100644
--- a/compiler/rustc_next_trait_solver/src/solve/trait_goals.rs
+++ b/compiler/rustc_next_trait_solver/src/solve/trait_goals.rs
@@ -127,33 +127,32 @@ fn fast_reject_assumption(
         goal: Goal<I, Self>,
         assumption: I::Clause,
     ) -> Result<(), NoSolution> {
-        if let Some(trait_clause) = assumption.as_trait_clause() {
-            if trait_clause.polarity() != goal.predicate.polarity {
-                return Err(NoSolution);
-            }
-
-            if trait_clause.def_id() == goal.predicate.def_id() {
-                if DeepRejectCtxt::relate_rigid_rigid(ecx.cx()).args_may_unify(
-                    goal.predicate.trait_ref.args,
-                    trait_clause.skip_binder().trait_ref.args,
-                ) {
-                    return Ok(());
-                }
-            }
-
+        fn trait_def_id_matches<I: Interner>(
+            cx: I,
+            clause_def_id: I::DefId,
+            goal_def_id: I::DefId,
+        ) -> bool {
+            clause_def_id == goal_def_id
             // PERF(sized-hierarchy): Sizedness supertraits aren't elaborated to improve perf, so
-            // check for a `Sized` subtrait when looking for `MetaSized`. `PointeeSized` bounds
-            // are syntactic sugar for a lack of bounds so don't need this.
-            if ecx.cx().is_lang_item(goal.predicate.def_id(), TraitSolverLangItem::MetaSized)
-                && ecx.cx().is_lang_item(trait_clause.def_id(), TraitSolverLangItem::Sized)
-            {
-                let meta_sized_clause =
-                    trait_predicate_with_def_id(ecx.cx(), trait_clause, goal.predicate.def_id());
-                return Self::fast_reject_assumption(ecx, goal, meta_sized_clause);
-            }
+            // check for a `MetaSized` supertrait being matched against a `Sized` assumption.
+            //
+            // `PointeeSized` bounds are syntactic sugar for a lack of bounds so don't need this.
+                || (cx.is_lang_item(clause_def_id, TraitSolverLangItem::Sized)
+                    && cx.is_lang_item(goal_def_id, TraitSolverLangItem::MetaSized))
         }
 
-        Err(NoSolution)
+        if let Some(trait_clause) = assumption.as_trait_clause()
+            && trait_clause.polarity() == goal.predicate.polarity
+            && trait_def_id_matches(ecx.cx(), trait_clause.def_id(), goal.predicate.def_id())
+            && DeepRejectCtxt::relate_rigid_rigid(ecx.cx()).args_may_unify(
+                goal.predicate.trait_ref.args,
+                trait_clause.skip_binder().trait_ref.args,
+            )
+        {
+            return Ok(());
+        } else {
+            Err(NoSolution)
+        }
     }
 
     fn match_assumption(
diff --git a/compiler/rustc_parse/src/parser/ty.rs b/compiler/rustc_parse/src/parser/ty.rs
index d874a07..8221c70 100644
--- a/compiler/rustc_parse/src/parser/ty.rs
+++ b/compiler/rustc_parse/src/parser/ty.rs
@@ -796,16 +796,10 @@ fn is_explicit_dyn_type(&mut self) -> bool {
     ///
     /// Note that this does *not* parse bare trait objects.
     fn parse_dyn_ty(&mut self, impl_dyn_multi: &mut bool) -> PResult<'a, TyKind> {
-        let lo = self.token.span;
         self.bump(); // `dyn`
 
-        // parse dyn* types
-        let syntax = if self.eat(exp!(Star)) {
-            self.psess.gated_spans.gate(sym::dyn_star, lo.to(self.prev_token.span));
-            TraitObjectSyntax::DynStar
-        } else {
-            TraitObjectSyntax::Dyn
-        };
+        // We used to parse `*` for `dyn*` here.
+        let syntax = TraitObjectSyntax::Dyn;
 
         // Always parse bounds greedily for better error recovery.
         let bounds = self.parse_generic_bounds()?;
diff --git a/compiler/rustc_parse/src/validate_attr.rs b/compiler/rustc_parse/src/validate_attr.rs
index 8b1d864..6c2c571d 100644
--- a/compiler/rustc_parse/src/validate_attr.rs
+++ b/compiler/rustc_parse/src/validate_attr.rs
@@ -303,6 +303,11 @@ fn emit_malformed_attribute(
             | sym::must_use
             | sym::track_caller
             | sym::link_name
+            | sym::export_name
+            | sym::rustc_macro_transparency
+            | sym::link_section
+            | sym::rustc_layout_scalar_valid_range_start
+            | sym::rustc_layout_scalar_valid_range_end
     ) {
         return;
     }
diff --git a/compiler/rustc_passes/messages.ftl b/compiler/rustc_passes/messages.ftl
index b1c7b0f..9a60c15 100644
--- a/compiler/rustc_passes/messages.ftl
+++ b/compiler/rustc_passes/messages.ftl
@@ -618,9 +618,6 @@
     attribute cannot be applied to a `async`, `gen` or `async gen` function
     .label = `async`, `gen` or `async gen` function
 
-passes_rustc_layout_scalar_valid_range_arg =
-    expected exactly one integer literal argument
-
 passes_rustc_layout_scalar_valid_range_not_struct =
     attribute should be applied to a struct
     .label = not a struct
diff --git a/compiler/rustc_passes/src/check_attr.rs b/compiler/rustc_passes/src/check_attr.rs
index ae486a5..1b965b9 100644
--- a/compiler/rustc_passes/src/check_attr.rs
+++ b/compiler/rustc_passes/src/check_attr.rs
@@ -9,7 +9,7 @@
 use std::collections::hash_map::Entry;
 
 use rustc_abi::{Align, ExternAbi, Size};
-use rustc_ast::{AttrStyle, LitKind, MetaItemInner, MetaItemKind, MetaItemLit, ast};
+use rustc_ast::{AttrStyle, LitKind, MetaItemInner, MetaItemKind, ast};
 use rustc_attr_data_structures::{AttributeKind, InlineAttr, ReprAttr, find_attr};
 use rustc_data_structures::fx::FxHashMap;
 use rustc_errors::{Applicability, DiagCtxtHandle, IntoDiagArg, MultiSpan, StashKey};
@@ -164,7 +164,9 @@ fn check_attributes(
                 }
                 Attribute::Parsed(AttributeKind::Repr(_)) => { /* handled below this loop and elsewhere */
                 }
-
+                Attribute::Parsed(AttributeKind::RustcObjectLifetimeDefault) => {
+                    self.check_object_lifetime_default(hir_id);
+                }
                 &Attribute::Parsed(AttributeKind::PubTransparent(attr_span)) => {
                     self.check_rustc_pub_transparent(attr_span, span, attrs)
                 }
@@ -177,6 +179,9 @@ fn check_attributes(
                 Attribute::Parsed(AttributeKind::Align { align, span: repr_span }) => {
                     self.check_align(span, target, *align, *repr_span)
                 }
+                Attribute::Parsed(AttributeKind::LinkSection { span: attr_span, .. }) => {
+                    self.check_link_section(hir_id, *attr_span, span, target)
+                }
                 Attribute::Parsed(AttributeKind::Naked(attr_span)) => {
                     self.check_naked(hir_id, *attr_span, span, target)
                 }
@@ -184,6 +189,10 @@ fn check_attributes(
                     self.check_track_caller(hir_id, *attr_span, attrs, span, target)
                 }
                 Attribute::Parsed(
+                    AttributeKind::RustcLayoutScalarValidRangeStart(_num, attr_span)
+                    | AttributeKind::RustcLayoutScalarValidRangeEnd(_num, attr_span),
+                ) => self.check_rustc_layout_scalar_valid_range(*attr_span, span, target),
+                Attribute::Parsed(
                     AttributeKind::BodyStability { .. }
                     | AttributeKind::ConstStabilityIndirect
                     | AttributeKind::MacroTransparency(_),
@@ -234,10 +243,6 @@ fn check_attributes(
                             &mut doc_aliases,
                         ),
                         [sym::no_link, ..] => self.check_no_link(hir_id, attr, span, target),
-                        [sym::rustc_layout_scalar_valid_range_start, ..]
-                        | [sym::rustc_layout_scalar_valid_range_end, ..] => {
-                            self.check_rustc_layout_scalar_valid_range(attr, span, target)
-                        }
                         [sym::debugger_visualizer, ..] => self.check_debugger_visualizer(attr, target),
                         [sym::rustc_std_internal_symbol, ..] => {
                             self.check_rustc_std_internal_symbol(attr, span, target)
@@ -286,7 +291,6 @@ fn check_attributes(
                         [sym::ffi_const, ..] => self.check_ffi_const(attr.span(), target),
                         [sym::link_ordinal, ..] => self.check_link_ordinal(attr, span, target),
                         [sym::link, ..] => self.check_link(hir_id, attr, span, target),
-                        [sym::link_section, ..] => self.check_link_section(hir_id, attr, span, target),
                         [sym::macro_use, ..] | [sym::macro_escape, ..] => {
                             self.check_macro_use(hir_id, attr, target)
                         }
@@ -301,7 +305,6 @@ fn check_attributes(
                         [sym::no_implicit_prelude, ..] => {
                             self.check_generic_attr(hir_id, attr, target, Target::Mod)
                         }
-                        [sym::rustc_object_lifetime_default, ..] => self.check_object_lifetime_default(hir_id),
                         [sym::proc_macro, ..] => {
                             self.check_proc_macro(hir_id, target, ProcMacroKind::FunctionLike)
                         }
@@ -1676,24 +1679,11 @@ fn check_export_name(&self, hir_id: HirId, attr_span: Span, span: Span, target:
         }
     }
 
-    fn check_rustc_layout_scalar_valid_range(&self, attr: &Attribute, span: Span, target: Target) {
+    fn check_rustc_layout_scalar_valid_range(&self, attr_span: Span, span: Span, target: Target) {
         if target != Target::Struct {
-            self.dcx().emit_err(errors::RustcLayoutScalarValidRangeNotStruct {
-                attr_span: attr.span(),
-                span,
-            });
+            self.dcx().emit_err(errors::RustcLayoutScalarValidRangeNotStruct { attr_span, span });
             return;
         }
-
-        let Some(list) = attr.meta_item_list() else {
-            return;
-        };
-
-        if !matches!(&list[..], &[MetaItemInner::Lit(MetaItemLit { kind: LitKind::Int(..), .. })]) {
-            self.tcx
-                .dcx()
-                .emit_err(errors::RustcLayoutScalarValidRangeArg { attr_span: attr.span() });
-        }
     }
 
     /// Checks if `#[rustc_legacy_const_generics]` is applied to a function and has a valid argument.
@@ -1831,7 +1821,7 @@ fn check_must_be_applied_to_trait(&self, attr_span: Span, defn_span: Span, targe
     }
 
     /// Checks if `#[link_section]` is applied to a function or static.
-    fn check_link_section(&self, hir_id: HirId, attr: &Attribute, span: Span, target: Target) {
+    fn check_link_section(&self, hir_id: HirId, attr_span: Span, span: Span, target: Target) {
         match target {
             Target::Static | Target::Fn | Target::Method(..) => {}
             // FIXME(#80564): We permit struct fields, match arms and macro defs to have an
@@ -1839,7 +1829,7 @@ fn check_link_section(&self, hir_id: HirId, attr: &Attribute, span: Span, target
             // erroneously allowed it and some crates used it accidentally, to be compatible
             // with crates depending on them, we can't throw an error here.
             Target::Field | Target::Arm | Target::MacroDef => {
-                self.inline_attr_str_error_with_macro_def(hir_id, attr.span(), "link_section");
+                self.inline_attr_str_error_with_macro_def(hir_id, attr_span, "link_section");
             }
             _ => {
                 // FIXME: #[link_section] was previously allowed on non-functions/statics and some
@@ -1847,7 +1837,7 @@ fn check_link_section(&self, hir_id: HirId, attr: &Attribute, span: Span, target
                 self.tcx.emit_node_span_lint(
                     UNUSED_ATTRIBUTES,
                     hir_id,
-                    attr.span(),
+                    attr_span,
                     errors::LinkSection { span },
                 );
             }
@@ -2842,7 +2832,7 @@ fn check_invalid_crate_level_attr(tcx: TyCtxt<'_>, attrs: &[Attribute]) {
             .find(|item| !item.span.is_dummy()) // Skip prelude `use`s
             .map(|item| errors::ItemFollowingInnerAttr {
                 span: if let Some(ident) = item.kind.ident() { ident.span } else { item.span },
-                kind: item.kind.descr(),
+                kind: tcx.def_descr(item.owner_id.to_def_id()),
             });
         let err = tcx.dcx().create_err(errors::InvalidAttrAtCrateLevel {
             span,
diff --git a/compiler/rustc_passes/src/errors.rs b/compiler/rustc_passes/src/errors.rs
index eaff1cc..d498827 100644
--- a/compiler/rustc_passes/src/errors.rs
+++ b/compiler/rustc_passes/src/errors.rs
@@ -536,13 +536,6 @@ pub(crate) struct RustcLayoutScalarValidRangeNotStruct {
 }
 
 #[derive(Diagnostic)]
-#[diag(passes_rustc_layout_scalar_valid_range_arg)]
-pub(crate) struct RustcLayoutScalarValidRangeArg {
-    #[primary_span]
-    pub attr_span: Span,
-}
-
-#[derive(Diagnostic)]
 #[diag(passes_rustc_legacy_const_generics_only)]
 pub(crate) struct RustcLegacyConstGenericsOnly {
     #[primary_span]
diff --git a/compiler/rustc_query_impl/src/profiling_support.rs b/compiler/rustc_query_impl/src/profiling_support.rs
index 7d80e54..7be75ea 100644
--- a/compiler/rustc_query_impl/src/profiling_support.rs
+++ b/compiler/rustc_query_impl/src/profiling_support.rs
@@ -259,4 +259,5 @@ pub fn alloc_self_profile_query_strings(tcx: TyCtxt<'_>) {
     for alloc in super::ALLOC_SELF_PROFILE_QUERY_STRINGS.iter() {
         alloc(tcx, &mut string_cache)
     }
+    tcx.sess.prof.store_query_cache_hits();
 }
diff --git a/compiler/rustc_sanitizers/src/cfi/typeid/itanium_cxx_abi/encode.rs b/compiler/rustc_sanitizers/src/cfi/typeid/itanium_cxx_abi/encode.rs
index 9d1d341..f4a14b3 100644
--- a/compiler/rustc_sanitizers/src/cfi/typeid/itanium_cxx_abi/encode.rs
+++ b/compiler/rustc_sanitizers/src/cfi/typeid/itanium_cxx_abi/encode.rs
@@ -631,7 +631,6 @@ pub(crate) fn encode_ty<'tcx>(
             // vendor extended type.
             let mut s = String::from(match kind {
                 ty::Dyn => "u3dynI",
-                ty::DynStar => "u7dynstarI",
             });
             s.push_str(&encode_predicates(tcx, predicates, dict, options));
             s.push_str(&encode_region(*region, dict));
diff --git a/compiler/rustc_serialize/src/lib.rs b/compiler/rustc_serialize/src/lib.rs
index 656ecfc..806d880 100644
--- a/compiler/rustc_serialize/src/lib.rs
+++ b/compiler/rustc_serialize/src/lib.rs
@@ -3,7 +3,6 @@
 // tidy-alphabetical-start
 #![allow(internal_features)]
 #![allow(rustc::internal)]
-#![cfg_attr(not(bootstrap), feature(sized_hierarchy))]
 #![cfg_attr(test, feature(test))]
 #![doc(
     html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/",
@@ -15,6 +14,7 @@
 #![feature(min_specialization)]
 #![feature(never_type)]
 #![feature(rustdoc_internals)]
+#![feature(sized_hierarchy)]
 // tidy-alphabetical-end
 
 // Allows macros to refer to this crate as `::rustc_serialize`.
@@ -28,19 +28,3 @@
 pub mod int_overflow;
 pub mod leb128;
 pub mod opaque;
-
-// This has nothing to do with `rustc_serialize` but it is convenient to define it in one place
-// for the rest of the compiler so that `cfg(bootstrap)` doesn't need to be littered throughout
-// the compiler wherever `PointeeSized` would be used. `rustc_serialize` happens to be the deepest
-// crate in the crate graph which uses `PointeeSized`.
-//
-// When bootstrap bumps, remove both the `cfg(not(bootstrap))` and `cfg(bootstrap)` lines below
-// and just import `std::marker::PointeeSized` whereever this item was used.
-
-#[cfg(not(bootstrap))]
-pub use std::marker::PointeeSized;
-
-#[cfg(bootstrap)]
-pub trait PointeeSized {}
-#[cfg(bootstrap)]
-impl<T: ?Sized> PointeeSized for T {}
diff --git a/compiler/rustc_serialize/src/serialize.rs b/compiler/rustc_serialize/src/serialize.rs
index 8940d10..6ea7060 100644
--- a/compiler/rustc_serialize/src/serialize.rs
+++ b/compiler/rustc_serialize/src/serialize.rs
@@ -4,7 +4,7 @@
 use std::cell::{Cell, RefCell};
 use std::collections::{BTreeMap, BTreeSet, HashMap, HashSet, VecDeque};
 use std::hash::{BuildHasher, Hash};
-use std::marker::PhantomData;
+use std::marker::{PhantomData, PointeeSized};
 use std::num::NonZero;
 use std::path;
 use std::rc::Rc;
@@ -21,6 +21,11 @@
 /// [utf8]: https://en.wikipedia.org/w/index.php?title=UTF-8&oldid=1058865525#Codepage_layout
 const STR_SENTINEL: u8 = 0xC1;
 
+/// For byte strings there are no bytes that canot occur. Just use this value
+/// as a best-effort sentinel. There is no validation skipped so the potential
+/// for badness is lower than in the `STR_SENTINEL` case.
+const BYTE_STR_SENTINEL: u8 = 0xC2;
+
 /// A note about error handling.
 ///
 /// Encoders may be fallible, but in practice failure is rare and there are so
@@ -72,6 +77,13 @@ fn emit_str(&mut self, v: &str) {
         self.emit_u8(STR_SENTINEL);
     }
 
+    #[inline]
+    fn emit_byte_str(&mut self, v: &[u8]) {
+        self.emit_usize(v.len());
+        self.emit_raw_bytes(v);
+        self.emit_u8(BYTE_STR_SENTINEL);
+    }
+
     fn emit_raw_bytes(&mut self, s: &[u8]);
 }
 
@@ -122,9 +134,19 @@ fn read_str(&mut self) -> &str {
         let len = self.read_usize();
         let bytes = self.read_raw_bytes(len + 1);
         assert!(bytes[len] == STR_SENTINEL);
+        // SAFETY: the presence of `STR_SENTINEL` gives us high (but not
+        // perfect) confidence that the bytes we just read truly are UTF-8.
         unsafe { std::str::from_utf8_unchecked(&bytes[..len]) }
     }
 
+    #[inline]
+    fn read_byte_str(&mut self) -> &[u8] {
+        let len = self.read_usize();
+        let bytes = self.read_raw_bytes(len + 1);
+        assert!(bytes[len] == BYTE_STR_SENTINEL);
+        &bytes[..len]
+    }
+
     fn read_raw_bytes(&mut self, len: usize) -> &[u8];
 
     fn peek_byte(&self) -> u8;
@@ -142,7 +164,7 @@ fn read_str(&mut self) -> &str {
 ///   `rustc_metadata::rmeta::Lazy`.
 /// * `TyEncodable` should be used for types that are only serialized in crate
 ///   metadata or the incremental cache. This is most types in `rustc_middle`.
-pub trait Encodable<S: Encoder>: crate::PointeeSized {
+pub trait Encodable<S: Encoder>: PointeeSized {
     fn encode(&self, s: &mut S);
 }
 
@@ -198,7 +220,7 @@ fn decode(d: &mut D) -> $ty {
     char emit_char read_char
 }
 
-impl<S: Encoder, T: ?Sized + crate::PointeeSized> Encodable<S> for &T
+impl<S: Encoder, T: ?Sized + PointeeSized> Encodable<S> for &T
 where
     T: Encodable<S>,
 {
@@ -239,7 +261,7 @@ fn encode(&self, s: &mut S) {
 
 impl<S: Encoder> Encodable<S> for String {
     fn encode(&self, s: &mut S) {
-        s.emit_str(&self[..]);
+        s.emit_str(&self);
     }
 }
 
diff --git a/compiler/rustc_smir/src/lib.rs b/compiler/rustc_smir/src/lib.rs
index 63623cf..067adda 100644
--- a/compiler/rustc_smir/src/lib.rs
+++ b/compiler/rustc_smir/src/lib.rs
@@ -9,13 +9,13 @@
 // tidy-alphabetical-start
 #![allow(internal_features)]
 #![allow(rustc::usage_of_ty_tykind)]
-#![cfg_attr(not(bootstrap), feature(sized_hierarchy))]
 #![doc(
     html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/",
     test(attr(allow(unused_variables), deny(warnings)))
 )]
 #![doc(rust_logo)]
 #![feature(rustdoc_internals)]
+#![feature(sized_hierarchy)]
 // tidy-alphabetical-end
 
 pub mod rustc_internal;
diff --git a/compiler/rustc_smir/src/rustc_internal/internal.rs b/compiler/rustc_smir/src/rustc_internal/internal.rs
index 24351ee..f878b6e 100644
--- a/compiler/rustc_smir/src/rustc_internal/internal.rs
+++ b/compiler/rustc_smir/src/rustc_internal/internal.rs
@@ -369,7 +369,6 @@ impl RustcInternal for DynKind {
     fn internal<'tcx>(&self, _tables: &mut Tables<'_>, _tcx: TyCtxt<'tcx>) -> Self::T<'tcx> {
         match self {
             DynKind::Dyn => rustc_ty::DynKind::Dyn,
-            DynKind::DynStar => rustc_ty::DynKind::DynStar,
         }
     }
 }
diff --git a/compiler/rustc_smir/src/rustc_smir/convert/mir.rs b/compiler/rustc_smir/src/rustc_smir/convert/mir.rs
index 85e71ed..daea4ac 100644
--- a/compiler/rustc_smir/src/rustc_smir/convert/mir.rs
+++ b/compiler/rustc_smir/src/rustc_smir/convert/mir.rs
@@ -301,11 +301,9 @@ impl<'tcx> Stable<'tcx> for mir::CastKind {
     type T = stable_mir::mir::CastKind;
     fn stable(&self, tables: &mut Tables<'_>) -> Self::T {
         use rustc_middle::mir::CastKind::*;
-        use rustc_middle::ty::adjustment::PointerCoercion;
         match self {
             PointerExposeProvenance => stable_mir::mir::CastKind::PointerExposeAddress,
             PointerWithExposedProvenance => stable_mir::mir::CastKind::PointerWithExposedProvenance,
-            PointerCoercion(PointerCoercion::DynStar, _) => stable_mir::mir::CastKind::DynStar,
             PointerCoercion(c, _) => stable_mir::mir::CastKind::PointerCoercion(c.stable(tables)),
             IntToInt => stable_mir::mir::CastKind::IntToInt,
             FloatToInt => stable_mir::mir::CastKind::FloatToInt,
diff --git a/compiler/rustc_smir/src/rustc_smir/convert/ty.rs b/compiler/rustc_smir/src/rustc_smir/convert/ty.rs
index 7abec48..ff0b8e8 100644
--- a/compiler/rustc_smir/src/rustc_smir/convert/ty.rs
+++ b/compiler/rustc_smir/src/rustc_smir/convert/ty.rs
@@ -43,7 +43,6 @@ impl<'tcx> Stable<'tcx> for ty::DynKind {
     fn stable(&self, _: &mut Tables<'_>) -> Self::T {
         match self {
             ty::Dyn => stable_mir::ty::DynKind::Dyn,
-            ty::DynStar => stable_mir::ty::DynKind::DynStar,
         }
     }
 }
@@ -120,7 +119,6 @@ fn stable(&self, tables: &mut Tables<'_>) -> Self::T {
             }
             PointerCoercion::ArrayToPointer => stable_mir::mir::PointerCoercion::ArrayToPointer,
             PointerCoercion::Unsize => stable_mir::mir::PointerCoercion::Unsize,
-            PointerCoercion::DynStar => unreachable!("represented as `CastKind::DynStar` in smir"),
         }
     }
 }
diff --git a/compiler/rustc_smir/src/rustc_smir/mod.rs b/compiler/rustc_smir/src/rustc_smir/mod.rs
index 64fe181..26de9b0 100644
--- a/compiler/rustc_smir/src/rustc_smir/mod.rs
+++ b/compiler/rustc_smir/src/rustc_smir/mod.rs
@@ -7,9 +7,9 @@
 //!
 //! For now, we are developing everything inside `rustc`, thus, we keep this module private.
 
+use std::marker::PointeeSized;
 use std::ops::RangeInclusive;
 
-use rustc_data_structures::PointeeSized;
 use rustc_hir::def::DefKind;
 use rustc_middle::mir;
 use rustc_middle::mir::interpret::AllocId;
diff --git a/compiler/rustc_smir/src/stable_mir/mir/body.rs b/compiler/rustc_smir/src/stable_mir/mir/body.rs
index e4b7659..90d4a06 100644
--- a/compiler/rustc_smir/src/stable_mir/mir/body.rs
+++ b/compiler/rustc_smir/src/stable_mir/mir/body.rs
@@ -1025,8 +1025,6 @@ pub enum CastKind {
     PointerExposeAddress,
     PointerWithExposedProvenance,
     PointerCoercion(PointerCoercion),
-    // FIXME(smir-rename): change this to PointerCoercion(DynStar)
-    DynStar,
     IntToInt,
     FloatToInt,
     FloatToFloat,
diff --git a/compiler/rustc_smir/src/stable_mir/ty.rs b/compiler/rustc_smir/src/stable_mir/ty.rs
index 7f6237e..4ea2bb0 100644
--- a/compiler/rustc_smir/src/stable_mir/ty.rs
+++ b/compiler/rustc_smir/src/stable_mir/ty.rs
@@ -1205,7 +1205,6 @@ pub enum BoundRegionKind {
 #[derive(Clone, Debug, Eq, PartialEq, Serialize)]
 pub enum DynKind {
     Dyn,
-    DynStar,
 }
 
 #[derive(Clone, Debug, Eq, PartialEq, Serialize)]
diff --git a/compiler/rustc_span/src/analyze_source_file.rs b/compiler/rustc_span/src/analyze_source_file.rs
index 55d899c..c32593a 100644
--- a/compiler/rustc_span/src/analyze_source_file.rs
+++ b/compiler/rustc_span/src/analyze_source_file.rs
@@ -29,18 +29,7 @@ pub(crate) fn analyze_source_file(src: &str) -> (Vec<RelativeBytePos>, Vec<Multi
     (lines, multi_byte_chars)
 }
 
-// cfg(bootstrap)
-macro_rules! cfg_select_dispatch {
-    ($($tokens:tt)*) => {
-        #[cfg(bootstrap)]
-        cfg_match! { $($tokens)* }
-
-        #[cfg(not(bootstrap))]
-        cfg_select! { $($tokens)* }
-    };
-}
-
-cfg_select_dispatch! {
+cfg_select! {
     any(target_arch = "x86", target_arch = "x86_64") => {
         fn analyze_source_file_dispatch(
             src: &str,
diff --git a/compiler/rustc_span/src/lib.rs b/compiler/rustc_span/src/lib.rs
index c8a29a2..c18ff28 100644
--- a/compiler/rustc_span/src/lib.rs
+++ b/compiler/rustc_span/src/lib.rs
@@ -17,11 +17,10 @@
 
 // tidy-alphabetical-start
 #![allow(internal_features)]
-#![cfg_attr(bootstrap, feature(cfg_match))]
-#![cfg_attr(not(bootstrap), feature(cfg_select))]
 #![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
 #![doc(rust_logo)]
 #![feature(array_windows)]
+#![feature(cfg_select)]
 #![feature(core_io_borrowed_buf)]
 #![feature(if_let_guard)]
 #![feature(map_try_insert)]
@@ -66,7 +65,9 @@
 pub use span_encoding::{DUMMY_SP, Span};
 
 pub mod symbol;
-pub use symbol::{Ident, MacroRulesNormalizedIdent, STDLIB_STABLE_CRATES, Symbol, kw, sym};
+pub use symbol::{
+    ByteSymbol, Ident, MacroRulesNormalizedIdent, STDLIB_STABLE_CRATES, Symbol, kw, sym,
+};
 
 mod analyze_source_file;
 pub mod fatal_error;
@@ -1184,11 +1185,12 @@ pub struct AttrId {}
 /// It is similar to rustc_type_ir's TyEncoder.
 pub trait SpanEncoder: Encoder {
     fn encode_span(&mut self, span: Span);
-    fn encode_symbol(&mut self, symbol: Symbol);
+    fn encode_symbol(&mut self, sym: Symbol);
+    fn encode_byte_symbol(&mut self, byte_sym: ByteSymbol);
     fn encode_expn_id(&mut self, expn_id: ExpnId);
     fn encode_syntax_context(&mut self, syntax_context: SyntaxContext);
-    /// As a local identifier, a `CrateNum` is only meaningful within its context, e.g. within a tcx.
-    /// Therefore, make sure to include the context when encode a `CrateNum`.
+    /// As a local identifier, a `CrateNum` is only meaningful within its context, e.g. within a
+    /// tcx. Therefore, make sure to include the context when encode a `CrateNum`.
     fn encode_crate_num(&mut self, crate_num: CrateNum);
     fn encode_def_index(&mut self, def_index: DefIndex);
     fn encode_def_id(&mut self, def_id: DefId);
@@ -1201,8 +1203,12 @@ fn encode_span(&mut self, span: Span) {
         span.hi.encode(self);
     }
 
-    fn encode_symbol(&mut self, symbol: Symbol) {
-        self.emit_str(symbol.as_str());
+    fn encode_symbol(&mut self, sym: Symbol) {
+        self.emit_str(sym.as_str());
+    }
+
+    fn encode_byte_symbol(&mut self, byte_sym: ByteSymbol) {
+        self.emit_byte_str(byte_sym.as_byte_str());
     }
 
     fn encode_expn_id(&mut self, _expn_id: ExpnId) {
@@ -1239,6 +1245,12 @@ fn encode(&self, s: &mut E) {
     }
 }
 
+impl<E: SpanEncoder> Encodable<E> for ByteSymbol {
+    fn encode(&self, s: &mut E) {
+        s.encode_byte_symbol(*self);
+    }
+}
+
 impl<E: SpanEncoder> Encodable<E> for ExpnId {
     fn encode(&self, s: &mut E) {
         s.encode_expn_id(*self)
@@ -1280,6 +1292,7 @@ fn encode(&self, _s: &mut E) {
 pub trait SpanDecoder: Decoder {
     fn decode_span(&mut self) -> Span;
     fn decode_symbol(&mut self) -> Symbol;
+    fn decode_byte_symbol(&mut self) -> ByteSymbol;
     fn decode_expn_id(&mut self) -> ExpnId;
     fn decode_syntax_context(&mut self) -> SyntaxContext;
     fn decode_crate_num(&mut self) -> CrateNum;
@@ -1300,6 +1313,10 @@ fn decode_symbol(&mut self) -> Symbol {
         Symbol::intern(self.read_str())
     }
 
+    fn decode_byte_symbol(&mut self) -> ByteSymbol {
+        ByteSymbol::intern(self.read_byte_str())
+    }
+
     fn decode_expn_id(&mut self) -> ExpnId {
         panic!("cannot decode `ExpnId` with `MemDecoder`");
     }
@@ -1337,6 +1354,12 @@ fn decode(s: &mut D) -> Symbol {
     }
 }
 
+impl<D: SpanDecoder> Decodable<D> for ByteSymbol {
+    fn decode(s: &mut D) -> ByteSymbol {
+        s.decode_byte_symbol()
+    }
+}
+
 impl<D: SpanDecoder> Decodable<D> for ExpnId {
     fn decode(s: &mut D) -> ExpnId {
         s.decode_expn_id()
diff --git a/compiler/rustc_span/src/symbol.rs b/compiler/rustc_span/src/symbol.rs
index 4b8762d..34869a3 100644
--- a/compiler/rustc_span/src/symbol.rs
+++ b/compiler/rustc_span/src/symbol.rs
@@ -2583,7 +2583,7 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
     }
 }
 
-/// An interned string.
+/// An interned UTF-8 string.
 ///
 /// Internally, a `Symbol` is implemented as an index, and all operations
 /// (including hashing, equality, and ordering) operate on that index. The use
@@ -2595,20 +2595,23 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
 #[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
 pub struct Symbol(SymbolIndex);
 
+// Used within both `Symbol` and `ByteSymbol`.
 rustc_index::newtype_index! {
     #[orderable]
     struct SymbolIndex {}
 }
 
 impl Symbol {
+    /// Avoid this except for things like deserialization of previously
+    /// serialized symbols, and testing. Use `intern` instead.
     pub const fn new(n: u32) -> Self {
         Symbol(SymbolIndex::from_u32(n))
     }
 
     /// Maps a string to its interned representation.
     #[rustc_diagnostic_item = "SymbolIntern"]
-    pub fn intern(string: &str) -> Self {
-        with_session_globals(|session_globals| session_globals.symbol_interner.intern(string))
+    pub fn intern(str: &str) -> Self {
+        with_session_globals(|session_globals| session_globals.symbol_interner.intern_str(str))
     }
 
     /// Access the underlying string. This is a slowish operation because it
@@ -2621,7 +2624,7 @@ pub fn intern(string: &str) -> Self {
     /// it works out ok.
     pub fn as_str(&self) -> &str {
         with_session_globals(|session_globals| unsafe {
-            std::mem::transmute::<&str, &str>(session_globals.symbol_interner.get(*self))
+            std::mem::transmute::<&str, &str>(session_globals.symbol_interner.get_str(*self))
         })
     }
 
@@ -2678,56 +2681,130 @@ fn stable_cmp(&self, other: &Self) -> std::cmp::Ordering {
     }
 }
 
+/// Like `Symbol`, but for byte strings. `ByteSymbol` is used less widely, so
+/// it has fewer operations defined than `Symbol`.
+#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
+pub struct ByteSymbol(SymbolIndex);
+
+impl ByteSymbol {
+    /// Avoid this except for things like deserialization of previously
+    /// serialized symbols, and testing. Use `intern` instead.
+    pub const fn new(n: u32) -> Self {
+        ByteSymbol(SymbolIndex::from_u32(n))
+    }
+
+    /// Maps a string to its interned representation.
+    pub fn intern(byte_str: &[u8]) -> Self {
+        with_session_globals(|session_globals| {
+            session_globals.symbol_interner.intern_byte_str(byte_str)
+        })
+    }
+
+    /// Like `Symbol::as_str`.
+    pub fn as_byte_str(&self) -> &[u8] {
+        with_session_globals(|session_globals| unsafe {
+            std::mem::transmute::<&[u8], &[u8]>(session_globals.symbol_interner.get_byte_str(*self))
+        })
+    }
+
+    pub fn as_u32(self) -> u32 {
+        self.0.as_u32()
+    }
+}
+
+impl fmt::Debug for ByteSymbol {
+    fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
+        fmt::Debug::fmt(self.as_byte_str(), f)
+    }
+}
+
+impl<CTX> HashStable<CTX> for ByteSymbol {
+    #[inline]
+    fn hash_stable(&self, hcx: &mut CTX, hasher: &mut StableHasher) {
+        self.as_byte_str().hash_stable(hcx, hasher);
+    }
+}
+
+// Interner used for both `Symbol`s and `ByteSymbol`s. If a string and a byte
+// string with identical contents (e.g. "foo" and b"foo") are both interned,
+// only one copy will be stored and the resulting `Symbol` and `ByteSymbol`
+// will have the same index.
 pub(crate) struct Interner(Lock<InternerInner>);
 
-// The `&'static str`s in this type actually point into the arena.
+// The `&'static [u8]`s in this type actually point into the arena.
 //
 // This type is private to prevent accidentally constructing more than one
 // `Interner` on the same thread, which makes it easy to mix up `Symbol`s
 // between `Interner`s.
 struct InternerInner {
     arena: DroplessArena,
-    strings: FxIndexSet<&'static str>,
+    byte_strs: FxIndexSet<&'static [u8]>,
 }
 
 impl Interner {
+    // These arguments are `&str`, but because of the sharing, we are
+    // effectively pre-interning all these strings for both `Symbol` and
+    // `ByteSymbol`.
     fn prefill(init: &[&'static str], extra: &[&'static str]) -> Self {
-        let strings = FxIndexSet::from_iter(init.iter().copied().chain(extra.iter().copied()));
-        assert_eq!(
-            strings.len(),
-            init.len() + extra.len(),
-            "there are duplicate symbols in the rustc symbol list and the extra symbols added by the driver",
+        let byte_strs = FxIndexSet::from_iter(
+            init.iter().copied().chain(extra.iter().copied()).map(|str| str.as_bytes()),
         );
-        Interner(Lock::new(InternerInner { arena: Default::default(), strings }))
+        assert_eq!(
+            byte_strs.len(),
+            init.len() + extra.len(),
+            "duplicate symbols in the rustc symbol list and the extra symbols added by the driver",
+        );
+        Interner(Lock::new(InternerInner { arena: Default::default(), byte_strs }))
+    }
+
+    fn intern_str(&self, str: &str) -> Symbol {
+        Symbol::new(self.intern_inner(str.as_bytes()))
+    }
+
+    fn intern_byte_str(&self, byte_str: &[u8]) -> ByteSymbol {
+        ByteSymbol::new(self.intern_inner(byte_str))
     }
 
     #[inline]
-    fn intern(&self, string: &str) -> Symbol {
+    fn intern_inner(&self, byte_str: &[u8]) -> u32 {
         let mut inner = self.0.lock();
-        if let Some(idx) = inner.strings.get_index_of(string) {
-            return Symbol::new(idx as u32);
+        if let Some(idx) = inner.byte_strs.get_index_of(byte_str) {
+            return idx as u32;
         }
 
-        let string: &str = inner.arena.alloc_str(string);
+        let byte_str: &[u8] = inner.arena.alloc_slice(byte_str);
 
         // SAFETY: we can extend the arena allocation to `'static` because we
         // only access these while the arena is still alive.
-        let string: &'static str = unsafe { &*(string as *const str) };
+        let byte_str: &'static [u8] = unsafe { &*(byte_str as *const [u8]) };
 
         // This second hash table lookup can be avoided by using `RawEntryMut`,
         // but this code path isn't hot enough for it to be worth it. See
         // #91445 for details.
-        let (idx, is_new) = inner.strings.insert_full(string);
+        let (idx, is_new) = inner.byte_strs.insert_full(byte_str);
         debug_assert!(is_new); // due to the get_index_of check above
 
-        Symbol::new(idx as u32)
+        idx as u32
     }
 
     /// Get the symbol as a string.
     ///
     /// [`Symbol::as_str()`] should be used in preference to this function.
-    fn get(&self, symbol: Symbol) -> &str {
-        self.0.lock().strings.get_index(symbol.0.as_usize()).unwrap()
+    fn get_str(&self, symbol: Symbol) -> &str {
+        let byte_str = self.get_inner(symbol.0.as_usize());
+        // SAFETY: known to be a UTF8 string because it's a `Symbol`.
+        unsafe { str::from_utf8_unchecked(byte_str) }
+    }
+
+    /// Get the symbol as a string.
+    ///
+    /// [`ByteSymbol::as_byte_str()`] should be used in preference to this function.
+    fn get_byte_str(&self, symbol: ByteSymbol) -> &[u8] {
+        self.get_inner(symbol.0.as_usize())
+    }
+
+    fn get_inner(&self, index: usize) -> &[u8] {
+        self.0.lock().byte_strs.get_index(index).unwrap()
     }
 }
 
@@ -2822,9 +2899,11 @@ pub fn can_be_raw(self) -> bool {
         self != sym::empty && self != kw::Underscore && !self.is_path_segment_keyword()
     }
 
-    /// Was this symbol predefined in the compiler's `symbols!` macro
-    pub fn is_predefined(self) -> bool {
-        self.as_u32() < PREDEFINED_SYMBOLS_COUNT
+    /// Was this symbol index predefined in the compiler's `symbols!` macro?
+    /// Note: this applies to both `Symbol`s and `ByteSymbol`s, which is why it
+    /// takes a `u32` argument instead of a `&self` argument. Use with care.
+    pub fn is_predefined(index: u32) -> bool {
+        index < PREDEFINED_SYMBOLS_COUNT
     }
 }
 
diff --git a/compiler/rustc_span/src/symbol/tests.rs b/compiler/rustc_span/src/symbol/tests.rs
index 660d0d7..bf0660a 100644
--- a/compiler/rustc_span/src/symbol/tests.rs
+++ b/compiler/rustc_span/src/symbol/tests.rs
@@ -5,14 +5,14 @@
 fn interner_tests() {
     let i = Interner::prefill(&[], &[]);
     // first one is zero:
-    assert_eq!(i.intern("dog"), Symbol::new(0));
-    // re-use gets the same entry:
-    assert_eq!(i.intern("dog"), Symbol::new(0));
+    assert_eq!(i.intern_str("dog"), Symbol::new(0));
+    // re-use gets the same entry, even with a `ByteSymbol`
+    assert_eq!(i.intern_byte_str(b"dog"), ByteSymbol::new(0));
     // different string gets a different #:
-    assert_eq!(i.intern("cat"), Symbol::new(1));
-    assert_eq!(i.intern("cat"), Symbol::new(1));
+    assert_eq!(i.intern_byte_str(b"cat"), ByteSymbol::new(1));
+    assert_eq!(i.intern_str("cat"), Symbol::new(1));
     // dog is still at zero
-    assert_eq!(i.intern("dog"), Symbol::new(0));
+    assert_eq!(i.intern_str("dog"), Symbol::new(0));
 }
 
 #[test]
diff --git a/compiler/rustc_symbol_mangling/src/v0.rs b/compiler/rustc_symbol_mangling/src/v0.rs
index 1db8ad7..fe0f8e6 100644
--- a/compiler/rustc_symbol_mangling/src/v0.rs
+++ b/compiler/rustc_symbol_mangling/src/v0.rs
@@ -576,8 +576,6 @@ fn print_type(&mut self, ty: Ty<'tcx>) -> Result<(), PrintError> {
             ty::Dynamic(predicates, r, kind) => {
                 self.push(match kind {
                     ty::Dyn => "D",
-                    // FIXME(dyn-star): need to update v0 mangling docs
-                    ty::DynStar => "D*",
                 });
                 self.print_dyn_existential(predicates)?;
                 r.print(self)?;
diff --git a/compiler/rustc_trait_selection/src/error_reporting/infer/note_and_explain.rs b/compiler/rustc_trait_selection/src/error_reporting/infer/note_and_explain.rs
index 0a4a914..aea42df 100644
--- a/compiler/rustc_trait_selection/src/error_reporting/infer/note_and_explain.rs
+++ b/compiler/rustc_trait_selection/src/error_reporting/infer/note_and_explain.rs
@@ -353,26 +353,6 @@ fn foo(&self, x: T) -> T { x }
                             ));
                         }
                     }
-                    (ty::Dynamic(t, _, ty::DynKind::DynStar), _)
-                        if let Some(def_id) = t.principal_def_id() =>
-                    {
-                        let mut has_matching_impl = false;
-                        tcx.for_each_relevant_impl(def_id, values.found, |did| {
-                            if DeepRejectCtxt::relate_rigid_infer(tcx)
-                                .types_may_unify(values.found, tcx.type_of(did).skip_binder())
-                            {
-                                has_matching_impl = true;
-                            }
-                        });
-                        if has_matching_impl {
-                            let trait_name = tcx.item_name(def_id);
-                            diag.help(format!(
-                                "`{}` implements `{trait_name}`, `#[feature(dyn_star)]` is likely \
-                                 not enabled; that feature it is currently incomplete",
-                                values.found,
-                            ));
-                        }
-                    }
                     (_, ty::Alias(ty::Opaque, opaque_ty))
                     | (ty::Alias(ty::Opaque, opaque_ty), _) => {
                         if opaque_ty.def_id.is_local()
diff --git a/compiler/rustc_trait_selection/src/error_reporting/traits/fulfillment_errors.rs b/compiler/rustc_trait_selection/src/error_reporting/traits/fulfillment_errors.rs
index 02edf48..c72eff1 100644
--- a/compiler/rustc_trait_selection/src/error_reporting/traits/fulfillment_errors.rs
+++ b/compiler/rustc_trait_selection/src/error_reporting/traits/fulfillment_errors.rs
@@ -1186,7 +1186,12 @@ fn report_const_param_not_wf(
         ty: Ty<'tcx>,
         obligation: &PredicateObligation<'tcx>,
     ) -> Diag<'a> {
-        let span = obligation.cause.span;
+        let param = obligation.cause.body_id;
+        let hir::GenericParamKind::Const { ty: &hir::Ty { span, .. }, .. } =
+            self.tcx.hir_node_by_def_id(param).expect_generic_param().kind
+        else {
+            bug!()
+        };
 
         let mut diag = match ty.kind() {
             ty::Float(_) => {
diff --git a/compiler/rustc_trait_selection/src/traits/select/mod.rs b/compiler/rustc_trait_selection/src/traits/select/mod.rs
index 316b4df..af3641c 100644
--- a/compiler/rustc_trait_selection/src/traits/select/mod.rs
+++ b/compiler/rustc_trait_selection/src/traits/select/mod.rs
@@ -2129,7 +2129,6 @@ fn sizedness_conditions(
             | ty::Closure(..)
             | ty::CoroutineClosure(..)
             | ty::Never
-            | ty::Dynamic(_, _, ty::DynStar)
             | ty::Error(_) => {
                 // safe for everything
                 Where(ty::Binder::dummy(Vec::new()))
diff --git a/compiler/rustc_ty_utils/src/consts.rs b/compiler/rustc_ty_utils/src/consts.rs
index 60f8bd9d..eb751da 100644
--- a/compiler/rustc_ty_utils/src/consts.rs
+++ b/compiler/rustc_ty_utils/src/consts.rs
@@ -120,7 +120,7 @@ fn recurse_build<'tcx>(
         }
         &ExprKind::Literal { lit, neg } => {
             let sp = node.span;
-            tcx.at(sp).lit_to_const(LitToConstInput { lit: &lit.node, ty: node.ty, neg })
+            tcx.at(sp).lit_to_const(LitToConstInput { lit: lit.node, ty: node.ty, neg })
         }
         &ExprKind::NonHirLiteral { lit, user_ty: _ } => {
             let val = ty::ValTree::from_scalar_int(tcx, lit);
diff --git a/compiler/rustc_ty_utils/src/layout.rs b/compiler/rustc_ty_utils/src/layout.rs
index d522282..a225b71 100644
--- a/compiler/rustc_ty_utils/src/layout.rs
+++ b/compiler/rustc_ty_utils/src/layout.rs
@@ -449,14 +449,6 @@ fn layout_of_uncached<'tcx>(
             tcx.mk_layout(LayoutData::scalar_pair(cx, data_ptr, metadata))
         }
 
-        ty::Dynamic(_, _, ty::DynStar) => {
-            let mut data = scalar_unit(Pointer(AddressSpace::DATA));
-            data.valid_range_mut().start = 0;
-            let mut vtable = scalar_unit(Pointer(AddressSpace::DATA));
-            vtable.valid_range_mut().start = 1;
-            tcx.mk_layout(LayoutData::scalar_pair(cx, data, vtable))
-        }
-
         // Arrays and slices.
         ty::Array(element, count) => {
             let count = extract_const_value(cx, ty, count)?
diff --git a/compiler/rustc_ty_utils/src/ty.rs b/compiler/rustc_ty_utils/src/ty.rs
index 553f5e0..f8d7934 100644
--- a/compiler/rustc_ty_utils/src/ty.rs
+++ b/compiler/rustc_ty_utils/src/ty.rs
@@ -38,8 +38,7 @@ fn sizedness_constraint_for_ty<'tcx>(
         | ty::CoroutineClosure(..)
         | ty::Coroutine(..)
         | ty::CoroutineWitness(..)
-        | ty::Never
-        | ty::Dynamic(_, _, ty::DynStar) => None,
+        | ty::Never => None,
 
         ty::Str | ty::Slice(..) | ty::Dynamic(_, _, ty::Dyn) => match sizedness {
             // Never `Sized`
@@ -383,8 +382,7 @@ fn impl_self_is_guaranteed_unsized<'tcx>(tcx: TyCtxt<'tcx>, impl_def_id: DefId)
         | ty::Bound(_, _)
         | ty::Placeholder(_)
         | ty::Infer(_)
-        | ty::Error(_)
-        | ty::Dynamic(_, _, ty::DynStar) => false,
+        | ty::Error(_) => false,
     }
 }
 
diff --git a/compiler/rustc_type_ir/src/elaborate.rs b/compiler/rustc_type_ir/src/elaborate.rs
index 177bad9..7ffcf7b 100644
--- a/compiler/rustc_type_ir/src/elaborate.rs
+++ b/compiler/rustc_type_ir/src/elaborate.rs
@@ -320,10 +320,10 @@ pub fn supertrait_def_ids<I: Interner>(
         let trait_def_id = stack.pop()?;
 
         for (predicate, _) in cx.explicit_super_predicates_of(trait_def_id).iter_identity() {
-            if let ty::ClauseKind::Trait(data) = predicate.kind().skip_binder() {
-                if set.insert(data.def_id()) {
-                    stack.push(data.def_id());
-                }
+            if let ty::ClauseKind::Trait(data) = predicate.kind().skip_binder()
+                && set.insert(data.def_id())
+            {
+                stack.push(data.def_id());
             }
         }
 
diff --git a/compiler/rustc_type_ir/src/infer_ctxt.rs b/compiler/rustc_type_ir/src/infer_ctxt.rs
index 2bc12d0..8ba9e71 100644
--- a/compiler/rustc_type_ir/src/infer_ctxt.rs
+++ b/compiler/rustc_type_ir/src/infer_ctxt.rs
@@ -117,12 +117,20 @@ pub fn analysis_in_body(cx: I, body_def_id: I::LocalDefId) -> TypingMode<I> {
     }
 
     pub fn borrowck(cx: I, body_def_id: I::LocalDefId) -> TypingMode<I> {
-        TypingMode::Borrowck { defining_opaque_types: cx.opaque_types_defined_by(body_def_id) }
+        let defining_opaque_types = cx.opaque_types_defined_by(body_def_id);
+        if defining_opaque_types.is_empty() {
+            TypingMode::non_body_analysis()
+        } else {
+            TypingMode::Borrowck { defining_opaque_types }
+        }
     }
 
     pub fn post_borrowck_analysis(cx: I, body_def_id: I::LocalDefId) -> TypingMode<I> {
-        TypingMode::PostBorrowckAnalysis {
-            defined_opaque_types: cx.opaque_types_defined_by(body_def_id),
+        let defined_opaque_types = cx.opaque_types_defined_by(body_def_id);
+        if defined_opaque_types.is_empty() {
+            TypingMode::non_body_analysis()
+        } else {
+            TypingMode::PostBorrowckAnalysis { defined_opaque_types }
         }
     }
 }
diff --git a/compiler/rustc_type_ir/src/inherent.rs b/compiler/rustc_type_ir/src/inherent.rs
index 272fca5..2754d40 100644
--- a/compiler/rustc_type_ir/src/inherent.rs
+++ b/compiler/rustc_type_ir/src/inherent.rs
@@ -183,8 +183,7 @@ fn is_guaranteed_unsized_raw(self) -> bool {
             | ty::Bound(_, _)
             | ty::Placeholder(_)
             | ty::Infer(_)
-            | ty::Error(_)
-            | ty::Dynamic(_, _, ty::DynStar) => false,
+            | ty::Error(_) => false,
         }
     }
 }
diff --git a/compiler/rustc_type_ir/src/lib.rs b/compiler/rustc_type_ir/src/lib.rs
index 3863a6d..a483c18 100644
--- a/compiler/rustc_type_ir/src/lib.rs
+++ b/compiler/rustc_type_ir/src/lib.rs
@@ -1,5 +1,6 @@
 #![cfg_attr(feature = "nightly", rustc_diagnostic_item = "type_ir")]
 // tidy-alphabetical-start
+#![allow(rustc::direct_use_of_rustc_type_ir)]
 #![allow(rustc::usage_of_ty_tykind)]
 #![allow(rustc::usage_of_type_ir_inherent)]
 #![allow(rustc::usage_of_type_ir_traits)]
@@ -8,7 +9,6 @@
     feature(associated_type_defaults, never_type, rustc_attrs, negative_impls)
 )]
 #![cfg_attr(feature = "nightly", allow(internal_features))]
-#![cfg_attr(not(bootstrap), allow(rustc::direct_use_of_rustc_type_ir))]
 // tidy-alphabetical-end
 
 extern crate self as rustc_type_ir;
diff --git a/compiler/rustc_type_ir/src/relate/solver_relating.rs b/compiler/rustc_type_ir/src/relate/solver_relating.rs
index e42639c..79f6bc5 100644
--- a/compiler/rustc_type_ir/src/relate/solver_relating.rs
+++ b/compiler/rustc_type_ir/src/relate/solver_relating.rs
@@ -284,12 +284,12 @@ fn binders<T>(
         }
 
         // If they have no bound vars, relate normally.
-        if let Some(a_inner) = a.no_bound_vars() {
-            if let Some(b_inner) = b.no_bound_vars() {
-                self.relate(a_inner, b_inner)?;
-                return Ok(a);
-            }
-        };
+        if let Some(a_inner) = a.no_bound_vars()
+            && let Some(b_inner) = b.no_bound_vars()
+        {
+            self.relate(a_inner, b_inner)?;
+            return Ok(a);
+        }
 
         match self.ambient_variance {
             // Checks whether `for<..> sub <: for<..> sup` holds.
diff --git a/compiler/rustc_type_ir/src/search_graph/global_cache.rs b/compiler/rustc_type_ir/src/search_graph/global_cache.rs
index 1b99cc8..eb56c1a 100644
--- a/compiler/rustc_type_ir/src/search_graph/global_cache.rs
+++ b/compiler/rustc_type_ir/src/search_graph/global_cache.rs
@@ -80,31 +80,29 @@ pub(super) fn get<'a>(
         mut candidate_is_applicable: impl FnMut(&NestedGoals<X>) -> bool,
     ) -> Option<CacheData<'a, X>> {
         let entry = self.map.get(&input)?;
-        if let Some(Success { required_depth, ref nested_goals, ref result }) = entry.success {
-            if available_depth.cache_entry_is_applicable(required_depth)
-                && candidate_is_applicable(nested_goals)
-            {
-                return Some(CacheData {
-                    result: cx.get_tracked(&result),
-                    required_depth,
-                    encountered_overflow: false,
-                    nested_goals,
-                });
-            }
+        if let Some(Success { required_depth, ref nested_goals, ref result }) = entry.success
+            && available_depth.cache_entry_is_applicable(required_depth)
+            && candidate_is_applicable(nested_goals)
+        {
+            return Some(CacheData {
+                result: cx.get_tracked(&result),
+                required_depth,
+                encountered_overflow: false,
+                nested_goals,
+            });
         }
 
         let additional_depth = available_depth.0;
         if let Some(WithOverflow { nested_goals, result }) =
             entry.with_overflow.get(&additional_depth)
+            && candidate_is_applicable(nested_goals)
         {
-            if candidate_is_applicable(nested_goals) {
-                return Some(CacheData {
-                    result: cx.get_tracked(result),
-                    required_depth: additional_depth,
-                    encountered_overflow: true,
-                    nested_goals,
-                });
-            }
+            return Some(CacheData {
+                result: cx.get_tracked(result),
+                required_depth: additional_depth,
+                encountered_overflow: true,
+                nested_goals,
+            });
         }
 
         None
diff --git a/compiler/rustc_type_ir/src/ty_kind.rs b/compiler/rustc_type_ir/src/ty_kind.rs
index 9669772..db6fbef 100644
--- a/compiler/rustc_type_ir/src/ty_kind.rs
+++ b/compiler/rustc_type_ir/src/ty_kind.rs
@@ -20,6 +20,9 @@
 mod closure;
 
 /// Specifies how a trait object is represented.
+///
+/// This used to have a variant `DynStar`, but that variant has been removed,
+/// and it's likely this whole enum will be removed soon.
 #[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Debug)]
 #[cfg_attr(
     feature = "nightly",
@@ -28,13 +31,6 @@
 pub enum DynKind {
     /// An unsized `dyn Trait` object
     Dyn,
-    /// A sized `dyn* Trait` object
-    ///
-    /// These objects are represented as a `(data, vtable)` pair where `data` is a value of some
-    /// ptr-sized and ptr-aligned dynamically determined type `T` and `vtable` is a pointer to the
-    /// vtable of `impl T for Trait`. This allows a `dyn*` object to be treated agnostically with
-    /// respect to whether it points to a `Box<T>`, `Rc<T>`, etc.
-    DynStar,
 }
 
 #[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Debug)]
@@ -371,7 +367,6 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
             UnsafeBinder(binder) => write!(f, "{:?}", binder),
             Dynamic(p, r, repr) => match repr {
                 DynKind::Dyn => write!(f, "dyn {p:?} + {r:?}"),
-                DynKind::DynStar => write!(f, "dyn* {p:?} + {r:?}"),
             },
             Closure(d, s) => f.debug_tuple("Closure").field(d).field(&s).finish(),
             CoroutineClosure(d, s) => f.debug_tuple("CoroutineClosure").field(d).field(&s).finish(),
diff --git a/library/core/Cargo.toml b/library/core/Cargo.toml
index 5d65b55..f88661e 100644
--- a/library/core/Cargo.toml
+++ b/library/core/Cargo.toml
@@ -29,8 +29,6 @@
 [lints.rust.unexpected_cfgs]
 level = "warn"
 check-cfg = [
-    # #[cfg(bootstrap)] loongarch32
-    'cfg(target_arch, values("loongarch32"))',
     'cfg(no_fp_fmt_parse)',
     # core use #[path] imports to portable-simd `core_simd` crate
     # and to stdarch `core_arch` crate which messes-up with Cargo list
diff --git a/library/core/src/any.rs b/library/core/src/any.rs
index 7aa3f3c..01dce11 100644
--- a/library/core/src/any.rs
+++ b/library/core/src/any.rs
@@ -742,7 +742,7 @@ impl TypeId {
     #[stable(feature = "rust1", since = "1.0.0")]
     #[rustc_const_unstable(feature = "const_type_id", issue = "77125")]
     pub const fn of<T: ?Sized + 'static>() -> TypeId {
-        let t: u128 = intrinsics::type_id::<T>();
+        let t: u128 = const { intrinsics::type_id::<T>() };
         let t1 = (t >> 64) as u64;
         let t2 = t as u64;
 
@@ -824,7 +824,7 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> Result<(), fmt::Error> {
 #[stable(feature = "type_name", since = "1.38.0")]
 #[rustc_const_unstable(feature = "const_type_name", issue = "63084")]
 pub const fn type_name<T: ?Sized>() -> &'static str {
-    intrinsics::type_name::<T>()
+    const { intrinsics::type_name::<T>() }
 }
 
 /// Returns the type name of the pointed-to value as a string slice.
diff --git a/library/core/src/array/iter.rs b/library/core/src/array/iter.rs
index a59b2f0..fdae5c0 100644
--- a/library/core/src/array/iter.rs
+++ b/library/core/src/array/iter.rs
@@ -224,7 +224,7 @@ pub fn as_mut_slice(&mut self) -> &mut [T] {
     }
 }
 
-#[stable(feature = "array_value_iter_default", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "array_value_iter_default", since = "1.89.0")]
 impl<T, const N: usize> Default for IntoIter<T, N> {
     fn default() -> Self {
         IntoIter::empty()
diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs
index 221ca91..5a46c04 100644
--- a/library/core/src/array/mod.rs
+++ b/library/core/src/array/mod.rs
@@ -588,7 +588,7 @@ pub const fn as_slice(&self) -> &[T] {
     /// Returns a mutable slice containing the entire array. Equivalent to
     /// `&mut s[..]`.
     #[stable(feature = "array_as_slice", since = "1.57.0")]
-    #[rustc_const_stable(feature = "const_array_as_mut_slice", since = "CURRENT_RUSTC_VERSION")]
+    #[rustc_const_stable(feature = "const_array_as_mut_slice", since = "1.89.0")]
     pub const fn as_mut_slice(&mut self) -> &mut [T] {
         self
     }
diff --git a/library/core/src/cell/lazy.rs b/library/core/src/cell/lazy.rs
index 0b2a2ce..1758e84 100644
--- a/library/core/src/cell/lazy.rs
+++ b/library/core/src/cell/lazy.rs
@@ -284,7 +284,7 @@ fn deref(&self) -> &T {
     }
 }
 
-#[stable(feature = "lazy_deref_mut", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "lazy_deref_mut", since = "1.89.0")]
 impl<T, F: FnOnce() -> T> DerefMut for LazyCell<T, F> {
     #[inline]
     fn deref_mut(&mut self) -> &mut T {
diff --git a/library/core/src/future/future.rs b/library/core/src/future/future.rs
index cfbd88b..fab13bb 100644
--- a/library/core/src/future/future.rs
+++ b/library/core/src/future/future.rs
@@ -4,7 +4,8 @@
 use crate::pin::Pin;
 use crate::task::{Context, Poll};
 
-/// A future represents an asynchronous computation obtained by use of [`async`].
+/// A future represents an asynchronous computation, commonly obtained by use of
+/// [`async`].
 ///
 /// A future is a value that might not have finished computing yet. This kind of
 /// "asynchronous value" makes it possible for a thread to continue doing useful
@@ -68,13 +69,21 @@ pub trait Future {
     ///
     /// # Runtime characteristics
     ///
-    /// Futures alone are *inert*; they must be *actively* `poll`ed to make
-    /// progress, meaning that each time the current task is woken up, it should
-    /// actively re-`poll` pending futures that it still has an interest in.
+    /// Futures alone are *inert*; they must be *actively* `poll`ed for the
+    /// underlying computation to make progress, meaning that each time the
+    /// current task is woken up, it should actively re-`poll` pending futures
+    /// that it still has an interest in.
     ///
-    /// The `poll` function is not called repeatedly in a tight loop -- instead,
-    /// it should only be called when the future indicates that it is ready to
-    /// make progress (by calling `wake()`). If you're familiar with the
+    /// Having said that, some Futures may represent a value that is being
+    /// computed in a different task. In this case, the future's underlying
+    /// computation is simply acting as a conduit for a value being computed
+    /// by that other task, which will proceed independently of the Future.
+    /// Futures of this kind are typically obtained when spawning a new task into an
+    /// async runtime.
+    ///
+    /// The `poll` function should not be called repeatedly in a tight loop --
+    /// instead, it should only be called when the future indicates that it is
+    /// ready to make progress (by calling `wake()`). If you're familiar with the
     /// `poll(2)` or `select(2)` syscalls on Unix it's worth noting that futures
     /// typically do *not* suffer the same problems of "all wakeups must poll
     /// all events"; they are more like `epoll(4)`.
diff --git a/library/core/src/intrinsics/mod.rs b/library/core/src/intrinsics/mod.rs
index b5c3e91..4250de9 100644
--- a/library/core/src/intrinsics/mod.rs
+++ b/library/core/src/intrinsics/mod.rs
@@ -839,10 +839,10 @@ pub fn select_unpredictable<T>(b: bool, true_val: T, false_val: T) -> T {
 /// If the actual type neither requires drop glue nor implements
 /// `Copy`, then the return value of this function is unspecified.
 ///
-/// Note that, unlike most intrinsics, this is safe to call;
-/// it does not require an `unsafe` block.
-/// Therefore, implementations must not require the user to uphold
-/// any safety invariants.
+/// Note that, unlike most intrinsics, this can only be called at compile-time
+/// as backends do not have an implementation for it. The only caller (its
+/// stable counterpart) wraps this intrinsic call in a `const` block so that
+/// backends only see an evaluated constant.
 ///
 /// The stabilized version of this intrinsic is [`mem::needs_drop`](crate::mem::needs_drop).
 #[rustc_intrinsic_const_stable_indirect]
@@ -2655,10 +2655,10 @@ pub const fn contract_check_ensures<C: Fn(&Ret) -> bool + Copy, Ret>(cond: C, re
 /// Returns the number of variants of the type `T` cast to a `usize`;
 /// if `T` has no variants, returns `0`. Uninhabited variants will be counted.
 ///
-/// Note that, unlike most intrinsics, this is safe to call;
-/// it does not require an `unsafe` block.
-/// Therefore, implementations must not require the user to uphold
-/// any safety invariants.
+/// Note that, unlike most intrinsics, this can only be called at compile-time
+/// as backends do not have an implementation for it. The only caller (its
+/// stable counterpart) wraps this intrinsic call in a `const` block so that
+/// backends only see an evaluated constant.
 ///
 /// The to-be-stabilized version of this intrinsic is [`crate::mem::variant_count`].
 #[rustc_nounwind]
@@ -2694,10 +2694,10 @@ pub const fn contract_check_ensures<C: Fn(&Ret) -> bool + Copy, Ret>(cond: C, re
 
 /// Gets a static string slice containing the name of a type.
 ///
-/// Note that, unlike most intrinsics, this is safe to call;
-/// it does not require an `unsafe` block.
-/// Therefore, implementations must not require the user to uphold
-/// any safety invariants.
+/// Note that, unlike most intrinsics, this can only be called at compile-time
+/// as backends do not have an implementation for it. The only caller (its
+/// stable counterpart) wraps this intrinsic call in a `const` block so that
+/// backends only see an evaluated constant.
 ///
 /// The stabilized version of this intrinsic is [`core::any::type_name`].
 #[rustc_nounwind]
@@ -2709,10 +2709,10 @@ pub const fn contract_check_ensures<C: Fn(&Ret) -> bool + Copy, Ret>(cond: C, re
 /// function will return the same value for a type regardless of whichever
 /// crate it is invoked in.
 ///
-/// Note that, unlike most intrinsics, this is safe to call;
-/// it does not require an `unsafe` block.
-/// Therefore, implementations must not require the user to uphold
-/// any safety invariants.
+/// Note that, unlike most intrinsics, this can only be called at compile-time
+/// as backends do not have an implementation for it. The only caller (its
+/// stable counterpart) wraps this intrinsic call in a `const` block so that
+/// backends only see an evaluated constant.
 ///
 /// The stabilized version of this intrinsic is [`core::any::TypeId::of`].
 #[rustc_nounwind]
diff --git a/library/core/src/mem/mod.rs b/library/core/src/mem/mod.rs
index b93f854..c00585d 100644
--- a/library/core/src/mem/mod.rs
+++ b/library/core/src/mem/mod.rs
@@ -616,7 +616,7 @@ pub const fn align_of_val<T: ?Sized>(val: &T) -> usize {
 #[rustc_const_stable(feature = "const_mem_needs_drop", since = "1.36.0")]
 #[rustc_diagnostic_item = "needs_drop"]
 pub const fn needs_drop<T: ?Sized>() -> bool {
-    intrinsics::needs_drop::<T>()
+    const { intrinsics::needs_drop::<T>() }
 }
 
 /// Returns the value of type `T` represented by the all-zero byte-pattern.
@@ -1215,7 +1215,7 @@ pub const fn discriminant<T>(v: &T) -> Discriminant<T> {
 #[rustc_const_unstable(feature = "variant_count", issue = "73662")]
 #[rustc_diagnostic_item = "mem_variant_count"]
 pub const fn variant_count<T>() -> usize {
-    intrinsics::variant_count::<T>()
+    const { intrinsics::variant_count::<T>() }
 }
 
 /// Provides associated constants for various useful properties of types,
diff --git a/library/core/src/num/f64.rs b/library/core/src/num/f64.rs
index 2f10e6d..93bfdbd 100644
--- a/library/core/src/num/f64.rs
+++ b/library/core/src/num/f64.rs
@@ -943,7 +943,7 @@ pub const fn min(self, other: f64) -> f64 {
     /// This returns NaN when *either* argument is NaN, as opposed to
     /// [`f64::max`] which only returns NaN when *both* arguments are NaN.
     ///
-    /// ```ignore-arm-unknown-linux-gnueabihf (see https://github.com/rust-lang/rust/issues/141087)
+    /// ```ignore-arm-unknown-linux-gnueabihf,ignore-i586 (see https://github.com/rust-lang/rust/issues/141087)
     /// #![feature(float_minimum_maximum)]
     /// let x = 1.0_f64;
     /// let y = 2.0_f64;
@@ -970,7 +970,7 @@ pub const fn maximum(self, other: f64) -> f64 {
     /// This returns NaN when *either* argument is NaN, as opposed to
     /// [`f64::min`] which only returns NaN when *both* arguments are NaN.
     ///
-    /// ```ignore-arm-unknown-linux-gnueabihf (see https://github.com/rust-lang/rust/issues/141087)
+    /// ```ignore-arm-unknown-linux-gnueabihf,ignore-i586 (see https://github.com/rust-lang/rust/issues/141087)
     /// #![feature(float_minimum_maximum)]
     /// let x = 1.0_f64;
     /// let y = 2.0_f64;
diff --git a/library/core/src/primitive_docs.rs b/library/core/src/primitive_docs.rs
index 0ac887f..f55bdfe 100644
--- a/library/core/src/primitive_docs.rs
+++ b/library/core/src/primitive_docs.rs
@@ -316,6 +316,11 @@ mod prim_bool {}
 #[unstable(feature = "never_type", issue = "35121")]
 mod prim_never {}
 
+// Required to make auto trait impls render.
+// See src/librustdoc/passes/collect_trait_impls.rs:collect_trait_impls
+#[doc(hidden)]
+impl ! {}
+
 #[rustc_doc_primitive = "char"]
 #[allow(rustdoc::invalid_rust_codeblocks)]
 /// A character type.
@@ -1078,11 +1083,13 @@ mod prim_str {}
 /// * [`Debug`]
 /// * [`Default`]
 /// * [`Hash`]
+/// * [`Random`]
 /// * [`From<[T; N]>`][from]
 ///
 /// [from]: convert::From
 /// [`Debug`]: fmt::Debug
 /// [`Hash`]: hash::Hash
+/// [`Random`]: random::Random
 ///
 /// The following traits are implemented for tuples of any length. These traits have
 /// implementations that are automatically generated by the compiler, so are not limited by
diff --git a/library/core/src/ptr/non_null.rs b/library/core/src/ptr/non_null.rs
index 282ad32..ea650b8 100644
--- a/library/core/src/ptr/non_null.rs
+++ b/library/core/src/ptr/non_null.rs
@@ -94,8 +94,8 @@ impl<T: Sized> NonNull<T> {
     /// For more details, see the equivalent method on a raw pointer, [`ptr::without_provenance_mut`].
     ///
     /// This is a [Strict Provenance][crate::ptr#strict-provenance] API.
-    #[stable(feature = "nonnull_provenance", since = "CURRENT_RUSTC_VERSION")]
-    #[rustc_const_stable(feature = "nonnull_provenance", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "nonnull_provenance", since = "1.89.0")]
+    #[rustc_const_stable(feature = "nonnull_provenance", since = "1.89.0")]
     #[must_use]
     #[inline]
     pub const fn without_provenance(addr: NonZero<usize>) -> Self {
@@ -138,7 +138,7 @@ pub const fn dangling() -> Self {
     /// For more details, see the equivalent method on a raw pointer, [`ptr::with_exposed_provenance_mut`].
     ///
     /// This is an [Exposed Provenance][crate::ptr#exposed-provenance] API.
-    #[stable(feature = "nonnull_provenance", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "nonnull_provenance", since = "1.89.0")]
     #[inline]
     pub fn with_exposed_provenance(addr: NonZero<usize>) -> Self {
         // SAFETY: we know `addr` is non-zero.
@@ -269,8 +269,8 @@ pub const fn new(ptr: *mut T) -> Option<Self> {
     }
 
     /// Converts a reference to a `NonNull` pointer.
-    #[stable(feature = "non_null_from_ref", since = "CURRENT_RUSTC_VERSION")]
-    #[rustc_const_stable(feature = "non_null_from_ref", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "non_null_from_ref", since = "1.89.0")]
+    #[rustc_const_stable(feature = "non_null_from_ref", since = "1.89.0")]
     #[inline]
     pub const fn from_ref(r: &T) -> Self {
         // SAFETY: A reference cannot be null.
@@ -278,8 +278,8 @@ pub const fn from_ref(r: &T) -> Self {
     }
 
     /// Converts a mutable reference to a `NonNull` pointer.
-    #[stable(feature = "non_null_from_ref", since = "CURRENT_RUSTC_VERSION")]
-    #[rustc_const_stable(feature = "non_null_from_ref", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "non_null_from_ref", since = "1.89.0")]
+    #[rustc_const_stable(feature = "non_null_from_ref", since = "1.89.0")]
     #[inline]
     pub const fn from_mut(r: &mut T) -> Self {
         // SAFETY: A mutable reference cannot be null.
@@ -335,7 +335,7 @@ pub fn addr(self) -> NonZero<usize> {
     /// For more details, see the equivalent method on a raw pointer, [`pointer::expose_provenance`].
     ///
     /// This is an [Exposed Provenance][crate::ptr#exposed-provenance] API.
-    #[stable(feature = "nonnull_provenance", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "nonnull_provenance", since = "1.89.0")]
     pub fn expose_provenance(self) -> NonZero<usize> {
         // SAFETY: The pointer is guaranteed by the type to be non-null,
         // meaning that the address will be non-zero.
diff --git a/library/core/src/result.rs b/library/core/src/result.rs
index 3a84ea6..7f3f296 100644
--- a/library/core/src/result.rs
+++ b/library/core/src/result.rs
@@ -1740,9 +1740,9 @@ impl<T, E> Result<Result<T, E>, E> {
     /// assert_eq!(Ok("hello"), x.flatten().flatten());
     /// ```
     #[inline]
-    #[stable(feature = "result_flattening", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "result_flattening", since = "1.89.0")]
     #[rustc_allow_const_fn_unstable(const_precise_live_drops)]
-    #[rustc_const_stable(feature = "result_flattening", since = "CURRENT_RUSTC_VERSION")]
+    #[rustc_const_stable(feature = "result_flattening", since = "1.89.0")]
     pub const fn flatten(self) -> Result<T, E> {
         // FIXME(const-hack): could be written with `and_then`
         match self {
diff --git a/library/core/src/slice/ascii.rs b/library/core/src/slice/ascii.rs
index 181ae82..e17a2e0 100644
--- a/library/core/src/slice/ascii.rs
+++ b/library/core/src/slice/ascii.rs
@@ -52,7 +52,7 @@ pub const fn as_ascii(&self) -> Option<&[ascii::Char]> {
     /// Same as `to_ascii_lowercase(a) == to_ascii_lowercase(b)`,
     /// but without allocating and copying temporaries.
     #[stable(feature = "ascii_methods_on_intrinsics", since = "1.23.0")]
-    #[rustc_const_stable(feature = "const_eq_ignore_ascii_case", since = "CURRENT_RUSTC_VERSION")]
+    #[rustc_const_stable(feature = "const_eq_ignore_ascii_case", since = "1.89.0")]
     #[must_use]
     #[inline]
     pub const fn eq_ignore_ascii_case(&self, other: &[u8]) -> bool {
diff --git a/library/core/src/slice/iter.rs b/library/core/src/slice/iter.rs
index 6def6ae..33132dc 100644
--- a/library/core/src/slice/iter.rs
+++ b/library/core/src/slice/iter.rs
@@ -3376,7 +3376,7 @@ fn next_back(&mut self) -> Option<Self::Item> {
 #[stable(feature = "slice_group_by", since = "1.77.0")]
 impl<'a, T: 'a, P> FusedIterator for ChunkBy<'a, T, P> where P: FnMut(&T, &T) -> bool {}
 
-#[stable(feature = "slice_group_by_clone", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "slice_group_by_clone", since = "1.89.0")]
 impl<'a, T: 'a, P: Clone> Clone for ChunkBy<'a, T, P> {
     fn clone(&self) -> Self {
         Self { slice: self.slice, predicate: self.predicate.clone() }
diff --git a/library/core/src/str/mod.rs b/library/core/src/str/mod.rs
index d250e14..8a6925a 100644
--- a/library/core/src/str/mod.rs
+++ b/library/core/src/str/mod.rs
@@ -2754,7 +2754,7 @@ pub const fn as_ascii(&self) -> Option<&[ascii::Char]> {
     /// assert!(!"Ferrös".eq_ignore_ascii_case("FERRÖS"));
     /// ```
     #[stable(feature = "ascii_methods_on_intrinsics", since = "1.23.0")]
-    #[rustc_const_stable(feature = "const_eq_ignore_ascii_case", since = "CURRENT_RUSTC_VERSION")]
+    #[rustc_const_stable(feature = "const_eq_ignore_ascii_case", since = "1.89.0")]
     #[must_use]
     #[inline]
     pub const fn eq_ignore_ascii_case(&self, other: &str) -> bool {
diff --git a/library/core/src/tuple.rs b/library/core/src/tuple.rs
index 3ff5579..6327c41 100644
--- a/library/core/src/tuple.rs
+++ b/library/core/src/tuple.rs
@@ -3,6 +3,7 @@
 use crate::cmp::Ordering::{self, *};
 use crate::marker::{ConstParamTy_, PointeeSized, StructuralPartialEq, UnsizedConstParamTy};
 use crate::ops::ControlFlow::{self, Break, Continue};
+use crate::random::{Random, RandomSource};
 
 // Recursive macro for implementing n-ary tuple functions and operations
 //
@@ -141,6 +142,16 @@ fn default() -> ($($T,)+) {
 
         maybe_tuple_doc! {
             $($T)+ @
+            #[unstable(feature = "random", issue = "130703")]
+            impl<$($T: Random),+> Random for ($($T,)+) {
+                fn random(source: &mut (impl RandomSource + ?Sized)) -> Self {
+                    ($({ let x: $T = Random::random(source); x},)+)
+                }
+            }
+        }
+
+        maybe_tuple_doc! {
+            $($T)+ @
             #[stable(feature = "array_tuple_conv", since = "1.71.0")]
             impl<T> From<[T; ${count($T)}]> for ($(${ignore($T)} T,)+) {
                 #[inline]
diff --git a/library/rtstartup/rsbegin.rs b/library/rtstartup/rsbegin.rs
index 0e915b9..62d247f 100644
--- a/library/rtstartup/rsbegin.rs
+++ b/library/rtstartup/rsbegin.rs
@@ -21,18 +21,12 @@
 #![allow(internal_features)]
 #![warn(unreachable_pub)]
 
-#[cfg(not(bootstrap))]
 #[lang = "pointee_sized"]
 pub trait PointeeSized {}
 
-#[cfg(not(bootstrap))]
 #[lang = "meta_sized"]
 pub trait MetaSized: PointeeSized {}
 
-#[cfg(bootstrap)]
-#[lang = "sized"]
-pub trait Sized {}
-#[cfg(not(bootstrap))]
 #[lang = "sized"]
 pub trait Sized: MetaSized {}
 
@@ -43,19 +37,8 @@ trait Copy {}
 #[lang = "freeze"]
 auto trait Freeze {}
 
-#[cfg(bootstrap)]
-impl<T: ?Sized> Copy for *mut T {}
-#[cfg(not(bootstrap))]
 impl<T: PointeeSized> Copy for *mut T {}
 
-#[cfg(bootstrap)]
-#[lang = "drop_in_place"]
-#[inline]
-#[allow(unconditional_recursion)]
-pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
-    drop_in_place(to_drop);
-}
-#[cfg(not(bootstrap))]
 #[lang = "drop_in_place"]
 #[inline]
 #[allow(unconditional_recursion)]
diff --git a/library/rtstartup/rsend.rs b/library/rtstartup/rsend.rs
index 75f9212..d763971 100644
--- a/library/rtstartup/rsend.rs
+++ b/library/rtstartup/rsend.rs
@@ -8,18 +8,12 @@
 #![allow(internal_features)]
 #![warn(unreachable_pub)]
 
-#[cfg(not(bootstrap))]
 #[lang = "pointee_sized"]
 pub trait PointeeSized {}
 
-#[cfg(not(bootstrap))]
 #[lang = "meta_sized"]
 pub trait MetaSized: PointeeSized {}
 
-#[cfg(bootstrap)]
-#[lang = "sized"]
-pub trait Sized {}
-#[cfg(not(bootstrap))]
 #[lang = "sized"]
 pub trait Sized: MetaSized {}
 
@@ -31,19 +25,8 @@ trait Copy {}
 #[lang = "freeze"]
 auto trait Freeze {}
 
-#[cfg(bootstrap)]
-impl<T: ?Sized> Copy for *mut T {}
-#[cfg(not(bootstrap))]
 impl<T: PointeeSized> Copy for *mut T {}
 
-#[cfg(bootstrap)]
-#[lang = "drop_in_place"]
-#[inline]
-#[allow(unconditional_recursion)]
-pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
-    drop_in_place(to_drop);
-}
-#[cfg(not(bootstrap))]
 #[lang = "drop_in_place"]
 #[inline]
 #[allow(unconditional_recursion)]
diff --git a/library/std/Cargo.toml b/library/std/Cargo.toml
index 7c2a43e..3a75d31 100644
--- a/library/std/Cargo.toml
+++ b/library/std/Cargo.toml
@@ -157,8 +157,6 @@
 [lints.rust.unexpected_cfgs]
 level = "warn"
 check-cfg = [
-    # #[cfg(bootstrap)] loongarch32
-    'cfg(target_arch, values("loongarch32"))',
     # std use #[path] imports to portable-simd `std_float` crate
     # and to the `backtrace` crate which messes-up with Cargo list
     # of declared features, we therefor expect any feature cfg
diff --git a/library/std/src/ffi/os_str.rs b/library/std/src/ffi/os_str.rs
index 3cc2250..8d7edc7 100644
--- a/library/std/src/ffi/os_str.rs
+++ b/library/std/src/ffi/os_str.rs
@@ -568,7 +568,7 @@ pub fn into_boxed_os_str(self) -> Box<OsStr> {
     /// However, keep in mind that trimming the capacity may result in a reallocation and copy.
     ///
     /// [`into_boxed_os_str`]: Self::into_boxed_os_str
-    #[stable(feature = "os_string_pathbuf_leak", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "os_string_pathbuf_leak", since = "1.89.0")]
     #[inline]
     pub fn leak<'a>(self) -> &'a mut OsStr {
         OsStr::from_inner_mut(self.inner.leak())
diff --git a/library/std/src/fs.rs b/library/std/src/fs.rs
index 865ea62..d9902d4 100644
--- a/library/std/src/fs.rs
+++ b/library/std/src/fs.rs
@@ -121,7 +121,7 @@ pub struct File {
 ///
 /// [`try_lock`]: File::try_lock
 /// [`try_lock_shared`]: File::try_lock_shared
-#[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "file_lock", since = "1.89.0")]
 pub enum TryLockError {
     /// The lock could not be acquired due to an I/O error on the file. The standard library will
     /// not return an [`ErrorKind::WouldBlock`] error inside [`TryLockError::Error`]
@@ -366,10 +366,10 @@ fn inner(path: &Path, contents: &[u8]) -> io::Result<()> {
     inner(path.as_ref(), contents.as_ref())
 }
 
-#[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "file_lock", since = "1.89.0")]
 impl error::Error for TryLockError {}
 
-#[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "file_lock", since = "1.89.0")]
 impl fmt::Debug for TryLockError {
     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
         match self {
@@ -379,7 +379,7 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
     }
 }
 
-#[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "file_lock", since = "1.89.0")]
 impl fmt::Display for TryLockError {
     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
         match self {
@@ -390,7 +390,7 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
     }
 }
 
-#[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "file_lock", since = "1.89.0")]
 impl From<TryLockError> for io::Error {
     fn from(err: TryLockError) -> io::Error {
         match err {
@@ -682,11 +682,11 @@ pub fn sync_data(&self) -> io::Result<()> {
     /// other methods, such as [`read`] and [`write`] are platform specific, and it may or may not
     /// cause non-lockholders to block.
     ///
-    /// If this file handle/descriptor, or a clone of it, already holds an lock the exact behavior
+    /// If this file handle/descriptor, or a clone of it, already holds a lock the exact behavior
     /// is unspecified and platform dependent, including the possibility that it will deadlock.
     /// However, if this method returns, then an exclusive lock is held.
     ///
-    /// If the file not open for writing, it is unspecified whether this function returns an error.
+    /// If the file is not open for writing, it is unspecified whether this function returns an error.
     ///
     /// The lock will be released when this file (along with any other file descriptors/handles
     /// duplicated or inherited from it) is closed, or if the [`unlock`] method is called.
@@ -721,7 +721,7 @@ pub fn sync_data(&self) -> io::Result<()> {
     ///     Ok(())
     /// }
     /// ```
-    #[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "file_lock", since = "1.89.0")]
     pub fn lock(&self) -> io::Result<()> {
         self.inner.lock()
     }
@@ -736,7 +736,7 @@ pub fn lock(&self) -> io::Result<()> {
     /// other methods, such as [`read`] and [`write`] are platform specific, and it may or may not
     /// cause non-lockholders to block.
     ///
-    /// If this file handle/descriptor, or a clone of it, already holds an lock, the exact behavior
+    /// If this file handle/descriptor, or a clone of it, already holds a lock, the exact behavior
     /// is unspecified and platform dependent, including the possibility that it will deadlock.
     /// However, if this method returns, then a shared lock is held.
     ///
@@ -773,7 +773,7 @@ pub fn lock(&self) -> io::Result<()> {
     ///     Ok(())
     /// }
     /// ```
-    #[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "file_lock", since = "1.89.0")]
     pub fn lock_shared(&self) -> io::Result<()> {
         self.inner.lock_shared()
     }
@@ -790,11 +790,11 @@ pub fn lock_shared(&self) -> io::Result<()> {
     /// other methods, such as [`read`] and [`write`] are platform specific, and it may or may not
     /// cause non-lockholders to block.
     ///
-    /// If this file handle/descriptor, or a clone of it, already holds an lock, the exact behavior
+    /// If this file handle/descriptor, or a clone of it, already holds a lock, the exact behavior
     /// is unspecified and platform dependent, including the possibility that it will deadlock.
     /// However, if this method returns `Ok(true)`, then it has acquired an exclusive lock.
     ///
-    /// If the file not open for writing, it is unspecified whether this function returns an error.
+    /// If the file is not open for writing, it is unspecified whether this function returns an error.
     ///
     /// The lock will be released when this file (along with any other file descriptors/handles
     /// duplicated or inherited from it) is closed, or if the [`unlock`] method is called.
@@ -837,7 +837,7 @@ pub fn lock_shared(&self) -> io::Result<()> {
     ///     Ok(())
     /// }
     /// ```
-    #[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "file_lock", since = "1.89.0")]
     pub fn try_lock(&self) -> Result<(), TryLockError> {
         self.inner.try_lock()
     }
@@ -855,7 +855,7 @@ pub fn try_lock(&self) -> Result<(), TryLockError> {
     /// other methods, such as [`read`] and [`write`] are platform specific, and it may or may not
     /// cause non-lockholders to block.
     ///
-    /// If this file handle, or a clone of it, already holds an lock, the exact behavior is
+    /// If this file handle, or a clone of it, already holds a lock, the exact behavior is
     /// unspecified and platform dependent, including the possibility that it will deadlock.
     /// However, if this method returns `Ok(true)`, then it has acquired a shared lock.
     ///
@@ -901,7 +901,7 @@ pub fn try_lock(&self) -> Result<(), TryLockError> {
     ///     Ok(())
     /// }
     /// ```
-    #[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "file_lock", since = "1.89.0")]
     pub fn try_lock_shared(&self) -> Result<(), TryLockError> {
         self.inner.try_lock_shared()
     }
@@ -938,7 +938,7 @@ pub fn try_lock_shared(&self) -> Result<(), TryLockError> {
     ///     Ok(())
     /// }
     /// ```
-    #[stable(feature = "file_lock", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "file_lock", since = "1.89.0")]
     pub fn unlock(&self) -> io::Result<()> {
         self.inner.unlock()
     }
diff --git a/library/std/src/io/mod.rs b/library/std/src/io/mod.rs
index a9a2468..17c32d7 100644
--- a/library/std/src/io/mod.rs
+++ b/library/std/src/io/mod.rs
@@ -3128,7 +3128,7 @@ fn upper_bound(&self) -> Option<usize> {
     }
 }
 
-#[stable(feature = "seek_io_take", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "seek_io_take", since = "1.89.0")]
 impl<T: Seek> Seek for Take<T> {
     fn seek(&mut self, pos: SeekFrom) -> Result<u64> {
         let new_position = match pos {
diff --git a/library/std/src/os/android/net.rs b/library/std/src/os/android/net.rs
index 3a459ed..95c3a74 100644
--- a/library/std/src/os/android/net.rs
+++ b/library/std/src/os/android/net.rs
@@ -6,5 +6,5 @@
 pub use crate::os::net::linux_ext::addr::SocketAddrExt;
 #[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
 pub use crate::os::net::linux_ext::socket::UnixSocketExt;
-#[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "tcp_quickack", since = "1.89.0")]
 pub use crate::os::net::linux_ext::tcp::TcpStreamExt;
diff --git a/library/std/src/os/linux/net.rs b/library/std/src/os/linux/net.rs
index c14aba1..ee56daf 100644
--- a/library/std/src/os/linux/net.rs
+++ b/library/std/src/os/linux/net.rs
@@ -6,5 +6,5 @@
 pub use crate::os::net::linux_ext::addr::SocketAddrExt;
 #[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
 pub use crate::os::net::linux_ext::socket::UnixSocketExt;
-#[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "tcp_quickack", since = "1.89.0")]
 pub use crate::os::net::linux_ext::tcp::TcpStreamExt;
diff --git a/library/std/src/os/net/linux_ext/mod.rs b/library/std/src/os/net/linux_ext/mod.rs
index bb9dfae..3c9afe3 100644
--- a/library/std/src/os/net/linux_ext/mod.rs
+++ b/library/std/src/os/net/linux_ext/mod.rs
@@ -8,7 +8,7 @@
 #[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
 pub(crate) mod socket;
 
-#[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "tcp_quickack", since = "1.89.0")]
 pub(crate) mod tcp;
 
 #[cfg(test)]
diff --git a/library/std/src/os/net/linux_ext/tcp.rs b/library/std/src/os/net/linux_ext/tcp.rs
index 167cfa6..fde53ec 100644
--- a/library/std/src/os/net/linux_ext/tcp.rs
+++ b/library/std/src/os/net/linux_ext/tcp.rs
@@ -9,7 +9,7 @@
 /// Os-specific extensions for [`TcpStream`]
 ///
 /// [`TcpStream`]: net::TcpStream
-#[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "tcp_quickack", since = "1.89.0")]
 pub trait TcpStreamExt: Sealed {
     /// Enable or disable `TCP_QUICKACK`.
     ///
@@ -33,7 +33,7 @@ pub trait TcpStreamExt: Sealed {
     ///         .expect("Couldn't connect to the server...");
     /// stream.set_quickack(true).expect("set_quickack call failed");
     /// ```
-    #[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "tcp_quickack", since = "1.89.0")]
     fn set_quickack(&self, quickack: bool) -> io::Result<()>;
 
     /// Gets the value of the `TCP_QUICKACK` option on this socket.
@@ -54,7 +54,7 @@ pub trait TcpStreamExt: Sealed {
     /// stream.set_quickack(true).expect("set_quickack call failed");
     /// assert_eq!(stream.quickack().unwrap_or(false), true);
     /// ```
-    #[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "tcp_quickack", since = "1.89.0")]
     fn quickack(&self) -> io::Result<bool>;
 
     /// A socket listener will be awakened solely when data arrives.
@@ -103,10 +103,10 @@ pub trait TcpStreamExt: Sealed {
     fn deferaccept(&self) -> io::Result<u32>;
 }
 
-#[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "tcp_quickack", since = "1.89.0")]
 impl Sealed for net::TcpStream {}
 
-#[stable(feature = "tcp_quickack", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "tcp_quickack", since = "1.89.0")]
 impl TcpStreamExt for net::TcpStream {
     fn set_quickack(&self, quickack: bool) -> io::Result<()> {
         self.as_inner().as_inner().set_quickack(quickack)
diff --git a/library/std/src/path.rs b/library/std/src/path.rs
index 07f212b..b734d2b 100644
--- a/library/std/src/path.rs
+++ b/library/std/src/path.rs
@@ -1252,7 +1252,7 @@ pub fn as_path(&self) -> &Path {
     /// However, keep in mind that trimming the capacity may result in a reallocation and copy.
     ///
     /// [`into_boxed_path`]: Self::into_boxed_path
-    #[stable(feature = "os_string_pathbuf_leak", since = "CURRENT_RUSTC_VERSION")]
+    #[stable(feature = "os_string_pathbuf_leak", since = "1.89.0")]
     #[inline]
     pub fn leak<'a>(self) -> &'a mut Path {
         Path::from_inner_mut(self.inner.leak())
diff --git a/library/std/src/sync/lazy_lock.rs b/library/std/src/sync/lazy_lock.rs
index 82e5fe0..eba849d 100644
--- a/library/std/src/sync/lazy_lock.rs
+++ b/library/std/src/sync/lazy_lock.rs
@@ -313,7 +313,7 @@ fn deref(&self) -> &T {
     }
 }
 
-#[stable(feature = "lazy_deref_mut", since = "CURRENT_RUSTC_VERSION")]
+#[stable(feature = "lazy_deref_mut", since = "1.89.0")]
 impl<T, F: FnOnce() -> T> DerefMut for LazyLock<T, F> {
     #[inline]
     fn deref_mut(&mut self) -> &mut T {
diff --git a/library/std/src/sys/fs/windows/remove_dir_all.rs b/library/std/src/sys/fs/windows/remove_dir_all.rs
index 06734f9..c8b1a07 100644
--- a/library/std/src/sys/fs/windows/remove_dir_all.rs
+++ b/library/std/src/sys/fs/windows/remove_dir_all.rs
@@ -33,7 +33,7 @@
 
 use super::{AsRawHandle, DirBuff, File, FromRawHandle};
 use crate::sys::c;
-use crate::sys::pal::api::WinError;
+use crate::sys::pal::api::{UnicodeStrRef, WinError, unicode_str};
 use crate::thread;
 
 // The maximum number of times to spin when waiting for deletes to complete.
@@ -74,7 +74,7 @@ unsafe fn nt_open_file(
 /// `options` will be OR'd with `FILE_OPEN_REPARSE_POINT`.
 fn open_link_no_reparse(
     parent: &File,
-    path: &[u16],
+    path: UnicodeStrRef<'_>,
     access: u32,
     options: u32,
 ) -> Result<Option<File>, WinError> {
@@ -90,9 +90,8 @@ fn open_link_no_reparse(
     static ATTRIBUTES: Atomic<u32> = AtomicU32::new(c::OBJ_DONT_REPARSE);
 
     let result = unsafe {
-        let mut path_str = c::UNICODE_STRING::from_ref(path);
         let mut object = c::OBJECT_ATTRIBUTES {
-            ObjectName: &mut path_str,
+            ObjectName: path.as_ptr(),
             RootDirectory: parent.as_raw_handle(),
             Attributes: ATTRIBUTES.load(Ordering::Relaxed),
             ..c::OBJECT_ATTRIBUTES::with_length()
@@ -129,7 +128,7 @@ fn open_link_no_reparse(
     }
 }
 
-fn open_dir(parent: &File, name: &[u16]) -> Result<Option<File>, WinError> {
+fn open_dir(parent: &File, name: UnicodeStrRef<'_>) -> Result<Option<File>, WinError> {
     // Open the directory for synchronous directory listing.
     open_link_no_reparse(
         parent,
@@ -140,7 +139,7 @@ fn open_dir(parent: &File, name: &[u16]) -> Result<Option<File>, WinError> {
     )
 }
 
-fn delete(parent: &File, name: &[u16]) -> Result<(), WinError> {
+fn delete(parent: &File, name: UnicodeStrRef<'_>) -> Result<(), WinError> {
     // Note that the `delete` function consumes the opened file to ensure it's
     // dropped immediately. See module comments for why this is important.
     match open_link_no_reparse(parent, name, c::DELETE, 0) {
@@ -179,8 +178,9 @@ pub fn remove_dir_all_iterative(dir: File) -> Result<(), WinError> {
     'outer: while let Some(dir) = dirlist.pop() {
         let more_data = dir.fill_dir_buff(&mut buffer, restart)?;
         for (name, is_directory) in buffer.iter() {
+            let name = unicode_str!(&name);
             if is_directory {
-                let Some(subdir) = open_dir(&dir, &name)? else { continue };
+                let Some(subdir) = open_dir(&dir, name)? else { continue };
                 dirlist.push(dir);
                 dirlist.push(subdir);
                 continue 'outer;
@@ -188,7 +188,7 @@ pub fn remove_dir_all_iterative(dir: File) -> Result<(), WinError> {
                 // Attempt to delete, retrying on sharing violation errors as these
                 // can often be very temporary. E.g. if something takes just a
                 // bit longer than expected to release a file handle.
-                retry(|| delete(&dir, &name), WinError::SHARING_VIOLATION)?;
+                retry(|| delete(&dir, name), WinError::SHARING_VIOLATION)?;
             }
         }
         if more_data {
@@ -197,7 +197,8 @@ pub fn remove_dir_all_iterative(dir: File) -> Result<(), WinError> {
         } else {
             // Attempt to delete, retrying on not empty errors because we may
             // need to wait some time for files to be removed from the filesystem.
-            retry(|| delete(&dir, &[]), WinError::DIR_NOT_EMPTY)?;
+            let name = unicode_str!("");
+            retry(|| delete(&dir, name), WinError::DIR_NOT_EMPTY)?;
             restart = true;
         }
     }
diff --git a/library/std/src/sys/pal/windows/api.rs b/library/std/src/sys/pal/windows/api.rs
index 773455c..25a6c2d 100644
--- a/library/std/src/sys/pal/windows/api.rs
+++ b/library/std/src/sys/pal/windows/api.rs
@@ -30,6 +30,7 @@
 //! should go in sys/pal/windows/mod.rs rather than here. See `IoResult` as an example.
 
 use core::ffi::c_void;
+use core::marker::PhantomData;
 
 use super::c;
 
@@ -291,3 +292,75 @@ impl WinError {
     pub const TIMEOUT: Self = Self::new(c::ERROR_TIMEOUT);
     // tidy-alphabetical-end
 }
+
+/// A wrapper around a UNICODE_STRING that is equivalent to `&[u16]`.
+///
+/// It is preferable to use the `unicode_str!` macro as that contains mitigations for  #143078.
+///
+/// If the MaximumLength field of the underlying UNICODE_STRING is greater than
+/// the Length field then you can test if the string is null terminated by inspecting
+/// the u16 directly after the string. You cannot otherwise depend on nul termination.
+#[derive(Copy, Clone)]
+pub struct UnicodeStrRef<'a> {
+    s: c::UNICODE_STRING,
+    lifetime: PhantomData<&'a [u16]>,
+}
+
+static EMPTY_STRING_NULL_TERMINATED: &[u16] = &[0];
+
+impl UnicodeStrRef<'_> {
+    const fn new(slice: &[u16], is_null_terminated: bool) -> Self {
+        let (len, max_len, ptr) = if slice.is_empty() {
+            (0, 2, EMPTY_STRING_NULL_TERMINATED.as_ptr().cast_mut())
+        } else {
+            let len = slice.len() - (is_null_terminated as usize);
+            (len * 2, size_of_val(slice), slice.as_ptr().cast_mut())
+        };
+        Self {
+            s: c::UNICODE_STRING { Length: len as _, MaximumLength: max_len as _, Buffer: ptr },
+            lifetime: PhantomData,
+        }
+    }
+
+    pub const fn from_slice_with_nul(slice: &[u16]) -> Self {
+        if !slice.is_empty() {
+            debug_assert!(slice[slice.len() - 1] == 0);
+        }
+        Self::new(slice, true)
+    }
+
+    pub const fn from_slice(slice: &[u16]) -> Self {
+        Self::new(slice, false)
+    }
+
+    /// Returns a pointer to the underlying UNICODE_STRING
+    pub const fn as_ptr(&self) -> *const c::UNICODE_STRING {
+        &self.s
+    }
+}
+
+/// Create a UnicodeStringRef from a literal str or a u16 array.
+///
+/// To mitigate #143078, when using a literal str the created UNICODE_STRING
+/// will be nul terminated. The MaximumLength field of the UNICODE_STRING will
+/// be set greater than the Length field to indicate that a nul may be present.
+///
+/// If using a u16 array, the array is used exactly as provided and you cannot
+/// count on the string being nul terminated.
+/// This should generally be used for strings that come from the OS.
+///
+/// **NOTE:** we lack a UNICODE_STRING builder type as we don't currently have
+/// a use for it. If needing to dynamically build a UNICODE_STRING, the builder
+/// should try to ensure there's a nul one past the end of the string.
+pub macro unicode_str {
+    ($str:literal) => {const {
+        crate::sys::pal::windows::api::UnicodeStrRef::from_slice_with_nul(
+            crate::sys::pal::windows::api::wide_str!($str),
+        )
+    }},
+    ($array:expr) => {
+        crate::sys::pal::windows::api::UnicodeStrRef::from_slice(
+            $array,
+        )
+    }
+}
diff --git a/library/std/src/sys/pal/windows/c.rs b/library/std/src/sys/pal/windows/c.rs
index 53dec10..eee169d 100644
--- a/library/std/src/sys/pal/windows/c.rs
+++ b/library/std/src/sys/pal/windows/c.rs
@@ -37,13 +37,6 @@ pub fn nt_success(status: NTSTATUS) -> bool {
     status >= 0
 }
 
-impl UNICODE_STRING {
-    pub fn from_ref(slice: &[u16]) -> Self {
-        let len = size_of_val(slice);
-        Self { Length: len as _, MaximumLength: len as _, Buffer: slice.as_ptr() as _ }
-    }
-}
-
 impl OBJECT_ATTRIBUTES {
     pub fn with_length() -> Self {
         Self {
diff --git a/library/std/src/sys/pal/windows/pipe.rs b/library/std/src/sys/pal/windows/pipe.rs
index bc5d05c..b5ccf03 100644
--- a/library/std/src/sys/pal/windows/pipe.rs
+++ b/library/std/src/sys/pal/windows/pipe.rs
@@ -1,9 +1,8 @@
 use crate::io::{self, BorrowedCursor, IoSlice, IoSliceMut};
 use crate::ops::Neg;
 use crate::os::windows::prelude::*;
-use crate::sys::api::utf16;
-use crate::sys::c;
 use crate::sys::handle::Handle;
+use crate::sys::{api, c};
 use crate::sys_common::{FromInner, IntoInner};
 use crate::{mem, ptr};
 
@@ -73,8 +72,8 @@ pub fn anon_pipe(ours_readable: bool, their_handle_inheritable: bool) -> io::Res
         // Open a handle to the pipe filesystem (`\??\PIPE\`).
         // This will be used when creating a new annon pipe.
         let pipe_fs = {
-            let path = c::UNICODE_STRING::from_ref(utf16!(r"\??\PIPE\"));
-            object_attributes.ObjectName = &path;
+            let path = api::unicode_str!(r"\??\PIPE\");
+            object_attributes.ObjectName = path.as_ptr();
             let mut pipe_fs = ptr::null_mut();
             let status = c::NtOpenFile(
                 &mut pipe_fs,
@@ -93,8 +92,12 @@ pub fn anon_pipe(ours_readable: bool, their_handle_inheritable: bool) -> io::Res
 
         // From now on we're using handles instead of paths to create and open pipes.
         // So set the `ObjectName` to a zero length string.
+        // As a (perhaps overzealous) mitigation for #143078, we use the null pointer
+        // for empty.Buffer instead of unicode_str!("").
+        // There's no difference to the OS itself but it's possible that third party
+        // DLLs which hook in to processes could be relying on the exact form of this string.
         let empty = c::UNICODE_STRING::default();
-        object_attributes.ObjectName = &empty;
+        object_attributes.ObjectName = &raw const empty;
 
         // Create our side of the pipe for async access.
         let ours = {
diff --git a/library/stdarch/crates/intrinsic-test/README.md b/library/stdarch/crates/intrinsic-test/README.md
index 260d59f..bea95f9 100644
--- a/library/stdarch/crates/intrinsic-test/README.md
+++ b/library/stdarch/crates/intrinsic-test/README.md
@@ -7,7 +7,7 @@
     intrinsic-test [FLAGS] [OPTIONS] <INPUT>
 
 FLAGS:
-        --a32              Run tests for A32 instrinsics instead of A64
+        --a32              Run tests for A32 intrinsics instead of A64
         --generate-only    Regenerate test programs, but don't build or run them
     -h, --help             Prints help information
     -V, --version          Prints version information
diff --git a/src/bootstrap/Cargo.lock b/src/bootstrap/Cargo.lock
index a6ca699..2434a27 100644
--- a/src/bootstrap/Cargo.lock
+++ b/src/bootstrap/Cargo.lock
@@ -12,6 +12,15 @@
 ]
 
 [[package]]
+name = "ansi_term"
+version = "0.12.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d52a9bb7ec0cf484c551830a7ce27bd20d67eac647e1befb56b0be4ee39a55d2"
+dependencies = [
+ "winapi",
+]
+
+[[package]]
 name = "anstyle"
 version = "1.0.10"
 source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -62,8 +71,8 @@
  "toml",
  "tracing",
  "tracing-chrome",
+ "tracing-forest",
  "tracing-subscriber",
- "tracing-tree",
  "walkdir",
  "windows",
  "xz2",
@@ -450,15 +459,6 @@
 ]
 
 [[package]]
-name = "nu-ansi-term"
-version = "0.50.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d4a28e057d01f97e61255210fcff094d74ed0466038633e95017f5beb68e4399"
-dependencies = [
- "windows-sys 0.52.0",
-]
-
-[[package]]
 name = "objc2-core-foundation"
 version = "0.3.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -776,6 +776,26 @@
 ]
 
 [[package]]
+name = "thiserror"
+version = "1.0.69"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52"
+dependencies = [
+ "thiserror-impl",
+]
+
+[[package]]
+name = "thiserror-impl"
+version = "1.0.69"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1"
+dependencies = [
+ "proc-macro2",
+ "quote",
+ "syn",
+]
+
+[[package]]
 name = "thread_local"
 version = "1.1.8"
 source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -838,6 +858,19 @@
 ]
 
 [[package]]
+name = "tracing-forest"
+version = "0.1.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ee40835db14ddd1e3ba414292272eddde9dad04d3d4b65509656414d1c42592f"
+dependencies = [
+ "ansi_term",
+ "smallvec",
+ "thiserror",
+ "tracing",
+ "tracing-subscriber",
+]
+
+[[package]]
 name = "tracing-log"
 version = "0.2.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
@@ -855,7 +888,7 @@
 checksum = "e8189decb5ac0fa7bc8b96b7cb9b2701d60d48805aca84a238004d665fcc4008"
 dependencies = [
  "matchers",
- "nu-ansi-term 0.46.0",
+ "nu-ansi-term",
  "once_cell",
  "regex",
  "sharded-slab",
@@ -867,18 +900,6 @@
 ]
 
 [[package]]
-name = "tracing-tree"
-version = "0.4.0"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f459ca79f1b0d5f71c54ddfde6debfc59c8b6eeb46808ae492077f739dc7b49c"
-dependencies = [
- "nu-ansi-term 0.50.1",
- "tracing-core",
- "tracing-log",
- "tracing-subscriber",
-]
-
-[[package]]
 name = "typenum"
 version = "1.17.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
diff --git a/src/bootstrap/Cargo.toml b/src/bootstrap/Cargo.toml
index 9785a30..073cebd 100644
--- a/src/bootstrap/Cargo.toml
+++ b/src/bootstrap/Cargo.toml
@@ -7,7 +7,7 @@
 
 [features]
 build-metrics = ["sysinfo"]
-tracing = ["dep:tracing", "dep:tracing-chrome", "dep:tracing-subscriber", "dep:tracing-tree"]
+tracing = ["dep:tracing", "dep:tracing-chrome", "dep:tracing-subscriber", "dep:tracing-forest"]
 
 [lib]
 path = "src/lib.rs"
@@ -64,7 +64,7 @@
 tracing = { version = "0.1", optional = true, features = ["attributes"] }
 tracing-chrome = { version = "0.7", optional = true }
 tracing-subscriber = { version = "0.3", optional = true, features = ["env-filter", "fmt", "registry", "std"] }
-tracing-tree = { version = "0.4.0", optional = true }
+tracing-forest = { version = "0.1.6", optional = true, default-features =  false, features = ["smallvec", "ansi", "env-filter"] }
 
 [target.'cfg(windows)'.dependencies.junction]
 version = "1.0.0"
diff --git a/src/bootstrap/defaults/bootstrap.dist.toml b/src/bootstrap/defaults/bootstrap.dist.toml
index f0cb34e..9daf9fa 100644
--- a/src/bootstrap/defaults/bootstrap.dist.toml
+++ b/src/bootstrap/defaults/bootstrap.dist.toml
@@ -20,7 +20,6 @@
 channel = "auto-detect"
 # Never download a rustc, distributions must build a fresh compiler.
 download-rustc = false
-lld = true
 # Build the llvm-bitcode-linker
 llvm-bitcode-linker = true
 
diff --git a/src/bootstrap/src/bin/main.rs b/src/bootstrap/src/bin/main.rs
index 833f802..e1862a4 100644
--- a/src/bootstrap/src/bin/main.rs
+++ b/src/bootstrap/src/bin/main.rs
@@ -217,12 +217,11 @@ fn check_version(config: &Config) -> Option<String> {
 //   "tracing", instrument(..))]`.
 #[cfg(feature = "tracing")]
 fn setup_tracing() -> impl Drop {
+    use tracing_forest::ForestLayer;
     use tracing_subscriber::EnvFilter;
     use tracing_subscriber::layer::SubscriberExt;
 
     let filter = EnvFilter::from_env("BOOTSTRAP_TRACING");
-    // cf. <https://docs.rs/tracing-tree/latest/tracing_tree/struct.HierarchicalLayer.html>.
-    let layer = tracing_tree::HierarchicalLayer::default().with_targets(true).with_indent_amount(2);
 
     let mut chrome_layer = tracing_chrome::ChromeLayerBuilder::new().include_args(true);
 
@@ -233,7 +232,8 @@ fn setup_tracing() -> impl Drop {
 
     let (chrome_layer, _guard) = chrome_layer.build();
 
-    let registry = tracing_subscriber::registry().with(filter).with(layer).with(chrome_layer);
+    let registry =
+        tracing_subscriber::registry().with(filter).with(ForestLayer::default()).with(chrome_layer);
 
     tracing::subscriber::set_global_default(registry).unwrap();
     _guard
diff --git a/src/bootstrap/src/core/build_steps/compile.rs b/src/bootstrap/src/core/build_steps/compile.rs
index 8200e15..8406415 100644
--- a/src/bootstrap/src/core/build_steps/compile.rs
+++ b/src/bootstrap/src/core/build_steps/compile.rs
@@ -2241,7 +2241,7 @@ fn run(self, builder: &Builder<'_>) -> Compiler {
         debug!("copying codegen backends to sysroot");
         copy_codegen_backends_to_sysroot(builder, build_compiler, target_compiler);
 
-        if builder.config.lld_enabled && !builder.config.is_system_llvm(target_compiler.host) {
+        if builder.config.lld_enabled {
             builder.ensure(crate::core::build_steps::tool::LldWrapper {
                 build_compiler,
                 target_compiler,
diff --git a/src/bootstrap/src/core/build_steps/tool.rs b/src/bootstrap/src/core/build_steps/tool.rs
index 83c0525..a722051 100644
--- a/src/bootstrap/src/core/build_steps/tool.rs
+++ b/src/bootstrap/src/core/build_steps/tool.rs
@@ -120,14 +120,14 @@ fn run(mut self, builder: &Builder<'_>) -> ToolBuildResult {
 
         match self.mode {
             Mode::ToolRustc => {
-                // If compiler was forced, its artifacts should be prepared earlier.
+                // If compiler was forced, its artifacts should have been prepared earlier.
                 if !self.compiler.is_forced_compiler() {
                     builder.std(self.compiler, self.compiler.host);
                     builder.ensure(compile::Rustc::new(self.compiler, target));
                 }
             }
             Mode::ToolStd => {
-                // If compiler was forced, its artifacts should be prepared earlier.
+                // If compiler was forced, its artifacts should have been prepared earlier.
                 if !self.compiler.is_forced_compiler() {
                     builder.std(self.compiler, target)
                 }
diff --git a/src/bootstrap/src/core/config/config.rs b/src/bootstrap/src/core/config/config.rs
index d1ffdf2..0cdfbbd 100644
--- a/src/bootstrap/src/core/config/config.rs
+++ b/src/bootstrap/src/core/config/config.rs
@@ -1003,9 +1003,7 @@ fn get_table(option: &str) -> Result<TomlConfig, toml::de::Error> {
         }
 
         if config.lld_enabled && config.is_system_llvm(config.host_target) {
-            eprintln!(
-                "Warning: LLD is enabled when using external llvm-config. LLD will not be built and copied to the sysroot."
-            );
+            panic!("Cannot enable LLD with `rust.lld = true` when using external llvm-config.");
         }
 
         config.optimized_compiler_builtins =
diff --git a/src/bootstrap/src/core/sanity.rs b/src/bootstrap/src/core/sanity.rs
index 958058d..f2119e8 100644
--- a/src/bootstrap/src/core/sanity.rs
+++ b/src/bootstrap/src/core/sanity.rs
@@ -34,8 +34,6 @@ pub struct Finder {
 // Targets can be removed from this list once they are present in the stage0 compiler (usually by updating the beta compiler of the bootstrap).
 const STAGE0_MISSING_TARGETS: &[&str] = &[
     // just a dummy comment so the list doesn't get onelined
-    "loongarch32-unknown-none",
-    "loongarch32-unknown-none-softfloat",
 ];
 
 /// Minimum version threshold for libstdc++ required when using prebuilt LLVM
diff --git a/src/bootstrap/src/utils/change_tracker.rs b/src/bootstrap/src/utils/change_tracker.rs
index 7c588cf..f873c62 100644
--- a/src/bootstrap/src/utils/change_tracker.rs
+++ b/src/bootstrap/src/utils/change_tracker.rs
@@ -431,4 +431,14 @@ pub fn human_readable_changes(changes: &[ChangeInfo]) -> String {
         severity: ChangeSeverity::Warning,
         summary: "It is no longer possible to `x build` with stage 0. All build commands have to be on stage 1+.",
     },
+    ChangeInfo {
+        change_id: 143175,
+        severity: ChangeSeverity::Info,
+        summary: "It is no longer possible to combine `rust.lld = true` with configuring external LLVM using `llvm.llvm-config`.",
+    },
+    ChangeInfo {
+        change_id: 143255,
+        severity: ChangeSeverity::Warning,
+        summary: "`llvm.lld` is no longer enabled by default for the dist profile.",
+    },
 ];
diff --git a/src/ci/run.sh b/src/ci/run.sh
index a6721a8..f58a067 100755
--- a/src/ci/run.sh
+++ b/src/ci/run.sh
@@ -86,13 +86,12 @@
 # space required for CI artifacts.
 RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --dist-compression-formats=xz"
 
-if [ "$EXTERNAL_LLVM" = "1" ]; then
-  RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --set rust.lld=false"
-fi
-
 # Enable the `c` feature for compiler_builtins, but only when the `compiler-rt` source is available
 # (to avoid spending a lot of time cloning llvm)
 if [ "$EXTERNAL_LLVM" = "" ]; then
+  # Enable building & shipping lld
+  RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --set rust.lld=true"
+
   RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --set build.optimized-compiler-builtins"
   # Likewise, only demand we test all LLVM components if we know we built LLVM with them
   export COMPILETEST_REQUIRE_ALL_LLVM_COMPONENTS=1
diff --git a/src/doc/book b/src/doc/book
index 8a6d44e..ef1ce8f 160000
--- a/src/doc/book
+++ b/src/doc/book
@@ -1 +1 @@
-Subproject commit 8a6d44e45b7b564eeb6bae30507e1fbac439d72d
+Subproject commit ef1ce8f87a8b18feb1b6a9cf9a4939a79bde6795
diff --git a/src/doc/embedded-book b/src/doc/embedded-book
index 10fa1e0..41f688a 160000
--- a/src/doc/embedded-book
+++ b/src/doc/embedded-book
@@ -1 +1 @@
-Subproject commit 10fa1e084365f23f24ad0000df541923385b73b6
+Subproject commit 41f688a598a5022b749e23d37f3c524f6a0b28e1
diff --git a/src/doc/reference b/src/doc/reference
index 50fc162..e9fc99f 160000
--- a/src/doc/reference
+++ b/src/doc/reference
@@ -1 +1 @@
-Subproject commit 50fc1628f36563958399123829c73755fa7a8421
+Subproject commit e9fc99f107840813916f62e16b3f6d9556e1f2d8
diff --git a/src/doc/rust-by-example b/src/doc/rust-by-example
index 05c7d8b..288b4e4 160000
--- a/src/doc/rust-by-example
+++ b/src/doc/rust-by-example
@@ -1 +1 @@
-Subproject commit 05c7d8bae65f23a1837430c5a19be129d414f5ec
+Subproject commit 288b4e4948add43f387cad35adc7b1c54ca6fe12
diff --git a/src/doc/rustc-dev-guide/src/tests/ui.md b/src/doc/rustc-dev-guide/src/tests/ui.md
index 09dc476..f7e62e1 100644
--- a/src/doc/rustc-dev-guide/src/tests/ui.md
+++ b/src/doc/rustc-dev-guide/src/tests/ui.md
@@ -499,7 +499,7 @@
 - `//@ known-bug: rust-lang/chalk#123456`
   (allows arbitrary text before the `#`, which is useful when the issue is on another repo)
 - `//@ known-bug: unknown`
-  (when there is no known issue yet; preferrably open one if it does not already exist)
+  (when there is no known issue yet; preferably open one if it does not already exist)
 
 Do not include [error annotations](#error-annotations) in a test with
 `known-bug`. The test should still include other normal directives and
diff --git a/src/doc/rustdoc/src/write-documentation/the-doc-attribute.md b/src/doc/rustdoc/src/write-documentation/the-doc-attribute.md
index 65e6b41..4d7f1a4 100644
--- a/src/doc/rustdoc/src/write-documentation/the-doc-attribute.md
+++ b/src/doc/rustdoc/src/write-documentation/the-doc-attribute.md
@@ -62,7 +62,7 @@
 This will put `<link rel="icon" href="{}">` into your docs, where
 the string for the attribute goes into the `{}`.
 
-If you don't use this attribute, there will be no favicon.
+If you don't use this attribute, a default favicon will be used.
 
 ### `html_logo_url`
 
diff --git a/src/doc/unstable-book/src/language-features/type-alias-impl-trait.md b/src/doc/unstable-book/src/language-features/type-alias-impl-trait.md
index a6fb25a..10464e5 100644
--- a/src/doc/unstable-book/src/language-features/type-alias-impl-trait.md
+++ b/src/doc/unstable-book/src/language-features/type-alias-impl-trait.md
@@ -64,7 +64,7 @@
 
 In this example, the concrete type referred to by `Alias` is guaranteed to be the same wherever `Alias` occurs.
 
-> Orginally this feature included type aliases as an associated type of a trait. In [#110237] this was split off to [`impl_trait_in_assoc_type`].
+> Originally this feature included type aliases as an associated type of a trait. In [#110237] this was split off to [`impl_trait_in_assoc_type`].
 
 ### `type_alias_impl_trait` in argument position.
 
diff --git a/src/librustdoc/clean/types.rs b/src/librustdoc/clean/types.rs
index 3cac554..600c564 100644
--- a/src/librustdoc/clean/types.rs
+++ b/src/librustdoc/clean/types.rs
@@ -753,9 +753,12 @@ fn attributes_without_repr(&self, tcx: TyCtxt<'_>, is_json: bool) -> Vec<String>
             .other_attrs
             .iter()
             .filter_map(|attr| {
+                if let hir::Attribute::Parsed(AttributeKind::LinkSection { name, .. }) = attr {
+                    Some(format!("#[link_section = \"{name}\"]"))
+                }
                 // NoMangle is special cased, as it appears in HTML output, and we want to show it in source form, not HIR printing.
                 // It is also used by cargo-semver-checks.
-                if let hir::Attribute::Parsed(AttributeKind::NoMangle(..)) = attr {
+                else if let hir::Attribute::Parsed(AttributeKind::NoMangle(..)) = attr {
                     Some("#[no_mangle]".to_string())
                 } else if let hir::Attribute::Parsed(AttributeKind::ExportName { name, .. }) = attr
                 {
diff --git a/src/stage0 b/src/stage0
index 4cff7ba..3313edf 100644
--- a/src/stage0
+++ b/src/stage0
@@ -13,466 +13,486 @@
 # All changes below this comment will be overridden the next time the
 # tool is executed.
 
-compiler_date=2025-05-26
+compiler_date=2025-06-24
 compiler_version=beta
-rustfmt_date=2025-05-27
+rustfmt_date=2025-06-24
 rustfmt_version=nightly
 
-dist/2025-05-26/rustc-beta-aarch64-apple-darwin.tar.gz=4dbdbac9216bb9a1e277f02d1fbbe6125709456a26440d0b8b852f615c8d0e5e
-dist/2025-05-26/rustc-beta-aarch64-apple-darwin.tar.xz=14cfac4d029e4960d3d822d2a02fd5a604b4d545ccf9b2a6c8ce7d1a7fffd2a2
-dist/2025-05-26/rustc-beta-aarch64-pc-windows-msvc.tar.gz=af901ff979cb9ec448ca8d5ae8dd70987b015614265dc7d8c5fbcf0c7d7f06f1
-dist/2025-05-26/rustc-beta-aarch64-pc-windows-msvc.tar.xz=afe5ac02574f8b996a8eb7dd7e95d717655da8a49f652694a31f52fdb39eb044
-dist/2025-05-26/rustc-beta-aarch64-unknown-linux-gnu.tar.gz=f2eaa46be24e7d5504628f05f799e58dd993d8ac3158328c238b834c14b5ad33
-dist/2025-05-26/rustc-beta-aarch64-unknown-linux-gnu.tar.xz=2c4a949aee410d9ed6602c3f95d58895fb0051fe7a3f1d0abd585f3d952a31d7
-dist/2025-05-26/rustc-beta-aarch64-unknown-linux-musl.tar.gz=e8aec1f37de24b6532056f5e3be512f5ddde86e536a9b68dab0baac76df36778
-dist/2025-05-26/rustc-beta-aarch64-unknown-linux-musl.tar.xz=64457bd80c7575c0792a5b998d407dea844d38d102560d1fce824ac8241efa7c
-dist/2025-05-26/rustc-beta-arm-unknown-linux-gnueabi.tar.gz=fd5dac6844caaccc15f29bea41b81e9d271f4408057580a86fdd7f5a032f4233
-dist/2025-05-26/rustc-beta-arm-unknown-linux-gnueabi.tar.xz=3095a4442404eb8e958ab9205fca9cfff13ca52cc18602fb322b410d497e6849
-dist/2025-05-26/rustc-beta-arm-unknown-linux-gnueabihf.tar.gz=d02a4cd721a8fa1f82f64bd9953f4867e1628dbb9e223e04c3ab7954f7eec055
-dist/2025-05-26/rustc-beta-arm-unknown-linux-gnueabihf.tar.xz=84c1a1e5e8dfb796c1c6b643329dfb65f53df372455fc70f4f3abd5dc8f614d8
-dist/2025-05-26/rustc-beta-armv7-unknown-linux-gnueabihf.tar.gz=86b675fa61c7cfd494e7e6ed514e9ccf6beab425238c236f8425052df7800724
-dist/2025-05-26/rustc-beta-armv7-unknown-linux-gnueabihf.tar.xz=078b1d00b8c6a37823d724b7993e7b2bcc73f433230a25bcbeb191eb2a0e8714
-dist/2025-05-26/rustc-beta-i686-pc-windows-gnu.tar.gz=08b47eca900f48b51ad4da927dca1a29b761e4e62b8e8eed7486cb150101afe1
-dist/2025-05-26/rustc-beta-i686-pc-windows-gnu.tar.xz=da0701faa92f4cfab71a78e707068d4840fb79393a00b14984a2bb37c24d99f5
-dist/2025-05-26/rustc-beta-i686-pc-windows-msvc.tar.gz=35de6670fbf76f3455be1630c8a3f628baea46473a69f0281e0dee20121b44be
-dist/2025-05-26/rustc-beta-i686-pc-windows-msvc.tar.xz=45bd16224593ae586358343ceb5c845af01b053800bc0dd9ddb3fca352abeb09
-dist/2025-05-26/rustc-beta-i686-unknown-linux-gnu.tar.gz=1de0f032ca7755c2b2c7d79d048bb8e25279a728619b9bec65f8e373ef58ff0f
-dist/2025-05-26/rustc-beta-i686-unknown-linux-gnu.tar.xz=00506ca8eeca547c844c48165e80afc71fa5bc9ad5734c2b90ebd9d6184540f5
-dist/2025-05-26/rustc-beta-loongarch64-unknown-linux-gnu.tar.gz=3067489dbd5bd1713e0d256a13061f484d662b4dad46e502a0d7507db69506c4
-dist/2025-05-26/rustc-beta-loongarch64-unknown-linux-gnu.tar.xz=09337bbecb0933162c1dcd5c85a5fa430b85c4b541b70f01ba77a82d5e64cbdb
-dist/2025-05-26/rustc-beta-loongarch64-unknown-linux-musl.tar.gz=aac2f6ca44fd4541ec6acdb658631e7907365f27b874c5cb14a15bd1fd23ee78
-dist/2025-05-26/rustc-beta-loongarch64-unknown-linux-musl.tar.xz=51505bc92660d2e206ea35218b682e23155f5d006ab200cbb1398f6a23c63fcf
-dist/2025-05-26/rustc-beta-powerpc-unknown-linux-gnu.tar.gz=35e4fa7207810cd8490e3d7ba181356d55e946d740a7a4f36e18d38e8a3b35a2
-dist/2025-05-26/rustc-beta-powerpc-unknown-linux-gnu.tar.xz=4cc9f12877323f5ebcf7f3d2878800dbc4d0930615b9baeb40e0a2824536d5d9
-dist/2025-05-26/rustc-beta-powerpc64-unknown-linux-gnu.tar.gz=9d8b217d6733c5f0375eaf6a38aa1a1b596ac5ef979f9440ff51ec7e7df25b08
-dist/2025-05-26/rustc-beta-powerpc64-unknown-linux-gnu.tar.xz=b32b303840f35d6a2f42751cada1f833b4c55b7d83634b1cc6d469902539d168
-dist/2025-05-26/rustc-beta-powerpc64le-unknown-linux-gnu.tar.gz=2fb8b2e97e7d1adea24302e2d2cf47b04200c6ad0299498d07b4ab59b6d4df08
-dist/2025-05-26/rustc-beta-powerpc64le-unknown-linux-gnu.tar.xz=33c763eeedd8f3a3ca885f94ade5c3a2355a479a0186ddae33e4cb068529de72
-dist/2025-05-26/rustc-beta-powerpc64le-unknown-linux-musl.tar.gz=6f59fecc08d6e84616bb89c2ee73b2f285c4bb2ebdfb122538c49b2fda41d1f9
-dist/2025-05-26/rustc-beta-powerpc64le-unknown-linux-musl.tar.xz=4723d0b463897004959e91675aa50aff0c9a9beca943267d77d11d5beee257cb
-dist/2025-05-26/rustc-beta-riscv64gc-unknown-linux-gnu.tar.gz=96a0400a43b8bc948619b51a9b8dbe778584b4225baf11f97bb59a443dfad1bb
-dist/2025-05-26/rustc-beta-riscv64gc-unknown-linux-gnu.tar.xz=cee9ff6682f8c87d5b81082dd6dd7eea26c59c246ef34c70c934b07a2d520817
-dist/2025-05-26/rustc-beta-s390x-unknown-linux-gnu.tar.gz=fa4d770e564aa0863825d5111a4b6c01d8486c65e8b9ef06db25ef778a448813
-dist/2025-05-26/rustc-beta-s390x-unknown-linux-gnu.tar.xz=945070094b80ac73cb013d3f556767caf6437258121f76921227e44d18249678
-dist/2025-05-26/rustc-beta-x86_64-apple-darwin.tar.gz=cf87e17e8f2fd18d9146671a393f31ab40ccfaf4c781bb81cdf02dff8bab5435
-dist/2025-05-26/rustc-beta-x86_64-apple-darwin.tar.xz=7cf73955adfb107f454829d3503d6cf91430e4cf5c4640466073c2c0f8a42732
-dist/2025-05-26/rustc-beta-x86_64-pc-windows-gnu.tar.gz=12b7528b31d971ccd36a44fff62ccc377dfa322a22af85fbcc7dcf2c8f2e0539
-dist/2025-05-26/rustc-beta-x86_64-pc-windows-gnu.tar.xz=21a305e0b085d73db5d79dabb61e1aad213b623f12708f94ff448a2db60d7651
-dist/2025-05-26/rustc-beta-x86_64-pc-windows-msvc.tar.gz=444aa1eea6824d1b73c0f653a2703806bd04154da160f96b9700c39b9e201dc3
-dist/2025-05-26/rustc-beta-x86_64-pc-windows-msvc.tar.xz=16c6000c46bab4f46ec2084d7e920d2099b8759870057e62bf0e8df8eb4ccb9f
-dist/2025-05-26/rustc-beta-x86_64-unknown-freebsd.tar.gz=6ad9c67484aa6598c4f0f70799980f57e4749560306ce1190dcb38476006247d
-dist/2025-05-26/rustc-beta-x86_64-unknown-freebsd.tar.xz=b8f921568dbca553484936adb267d384b8ce6bfd40efa0b54d22cd98a6638c43
-dist/2025-05-26/rustc-beta-x86_64-unknown-illumos.tar.gz=14083e187d62529058dc0de8657024f5dc2ac5af37986053fc21f2334e1217af
-dist/2025-05-26/rustc-beta-x86_64-unknown-illumos.tar.xz=2410d5423581ec2d205a47bfeb3c95bf3071303b5b71343254492d53fa27cd48
-dist/2025-05-26/rustc-beta-x86_64-unknown-linux-gnu.tar.gz=6561e72c72b5a2a10ef97632c0af2ce8112fe0faf6d12d83da0ec9f0b347b88f
-dist/2025-05-26/rustc-beta-x86_64-unknown-linux-gnu.tar.xz=14b944631444b666019e0c2f3590b78b3de3dcd499c0f7254dd22a95703e8585
-dist/2025-05-26/rustc-beta-x86_64-unknown-linux-musl.tar.gz=cd09f6ef2c26b2f192cf1a05badd3603e8cab4141e120ec98c1afbcda7036aa5
-dist/2025-05-26/rustc-beta-x86_64-unknown-linux-musl.tar.xz=53745c050956b886e5e3f523b1a77f40c6c73c1df867505cb9f1ec2cb5026f56
-dist/2025-05-26/rustc-beta-x86_64-unknown-netbsd.tar.gz=d88ccdea31b269ad513cd8106c0aec60124ee1ec50c839dbc7218dc1d2b80e0a
-dist/2025-05-26/rustc-beta-x86_64-unknown-netbsd.tar.xz=d10add7b925f1492d2b1c9ecd76df2065bac118fa6a27fde7b73d5ec55f30c0c
-dist/2025-05-26/rust-std-beta-aarch64-apple-darwin.tar.gz=4076b5062f1e3f098c0b5ce5cacbaed784afcae6f7db740c0939fcf3a58025e6
-dist/2025-05-26/rust-std-beta-aarch64-apple-darwin.tar.xz=91c94ea57ca9eebf103d89532c6b1b24f3a2529f3a755b1c29ae0897b759dec6
-dist/2025-05-26/rust-std-beta-aarch64-apple-ios.tar.gz=8b89d32f731c103945efedaf2d9050d96e525d50f066239175f629cc0e3b944c
-dist/2025-05-26/rust-std-beta-aarch64-apple-ios.tar.xz=b139ea399a96514732007ba26488cc6f75cd86e710938638dc3b1c7913a8b103
-dist/2025-05-26/rust-std-beta-aarch64-apple-ios-macabi.tar.gz=7bb6dd559ef08d5e8bbfee75243eca8760d411f952ff646356ce4fe74564dc2a
-dist/2025-05-26/rust-std-beta-aarch64-apple-ios-macabi.tar.xz=c17c372f13bddd9d0629fc1bab0dac6004f7356752db20b196da0e46860b174d
-dist/2025-05-26/rust-std-beta-aarch64-apple-ios-sim.tar.gz=a2a01f111d234d89b820591428b036cc6de2b74e6c0e96c32211b085e537b4f6
-dist/2025-05-26/rust-std-beta-aarch64-apple-ios-sim.tar.xz=06380c88a781e584feea822c91b1b6f98412ed5699d4d00d65e5ef7075dbf4c4
-dist/2025-05-26/rust-std-beta-aarch64-linux-android.tar.gz=1ab07c597044c1eed2224aa72893e14055494d8fcf0e746426578055ee881087
-dist/2025-05-26/rust-std-beta-aarch64-linux-android.tar.xz=c55be970bcde2866cb2d66830476cd7fd52692a791fbe3f198e84913a4247a4b
-dist/2025-05-26/rust-std-beta-aarch64-pc-windows-gnullvm.tar.gz=7445b8979d6d325a1a6714e28048ce965159b7fa326c9b7d663c771129f81a7b
-dist/2025-05-26/rust-std-beta-aarch64-pc-windows-gnullvm.tar.xz=f3fe861b5d81b54c7861663519324a5d305f3300c733cb7f146b6a93770fb73b
-dist/2025-05-26/rust-std-beta-aarch64-pc-windows-msvc.tar.gz=57be8b656ae0f4fa9164803155c9af5eafdd961bac752ff3833e5ceba4accb18
-dist/2025-05-26/rust-std-beta-aarch64-pc-windows-msvc.tar.xz=e64807cbdf82117a127d85a35a1303683dbe3c95366bf469c13a2781ed66916b
-dist/2025-05-26/rust-std-beta-aarch64-unknown-fuchsia.tar.gz=d8d4737d031170d5c6f8bb1aede6c863a3ad6c32007de2e1b7ff03242710ab17
-dist/2025-05-26/rust-std-beta-aarch64-unknown-fuchsia.tar.xz=27998ee47c29ba860a5c56155332091275e7e9669e035fcf11a02c9089b6e8f2
-dist/2025-05-26/rust-std-beta-aarch64-unknown-linux-gnu.tar.gz=9dc717d80d91e833580748c831c2a80bca2f8d7bce9af51d21f0375c44cce395
-dist/2025-05-26/rust-std-beta-aarch64-unknown-linux-gnu.tar.xz=88ffb04366bc06c331113026ea64b04ce970f01f13a0e80736fd59676e4e974a
-dist/2025-05-26/rust-std-beta-aarch64-unknown-linux-musl.tar.gz=5ac4a726e875af3387a2214f722b676e21e3d0afbfbcf1969107c34c6eeb1706
-dist/2025-05-26/rust-std-beta-aarch64-unknown-linux-musl.tar.xz=7fe9cd0d76f9c4778d53b5fba083616ac06d04b622e9e783e3e0fd3e0d3756e8
-dist/2025-05-26/rust-std-beta-aarch64-unknown-linux-ohos.tar.gz=5813b23bccf3fe10ec2ab540149bed4739668d9f9b198a476300e50e53721d52
-dist/2025-05-26/rust-std-beta-aarch64-unknown-linux-ohos.tar.xz=383a1758e3f2f1d20b23b8095f3772f79ea5377312602cd577a2b047ed062115
-dist/2025-05-26/rust-std-beta-aarch64-unknown-none.tar.gz=3589b1e3c4367b369050062e9df8838a797059056c98662e47d1cf71ecdcd787
-dist/2025-05-26/rust-std-beta-aarch64-unknown-none.tar.xz=47e290959699c9bc9093cd6603bf3357492ef7a05a5c2335393d41ef94955c30
-dist/2025-05-26/rust-std-beta-aarch64-unknown-none-softfloat.tar.gz=e690ad47757a726cfe621e936dd0ac76d96dd4b838ba3e5dd582565d5b2c3618
-dist/2025-05-26/rust-std-beta-aarch64-unknown-none-softfloat.tar.xz=2d17e86eaaddc93e81b3bd39d3faeed3ccb1765a9a13144d4bab726d384f8eba
-dist/2025-05-26/rust-std-beta-aarch64-unknown-uefi.tar.gz=a5f8b8e8ee3859d877430760132180ef956e597de3ab539e980aa48c937e3e10
-dist/2025-05-26/rust-std-beta-aarch64-unknown-uefi.tar.xz=225b50bb3500d46291bdf877cdce57d8bf8133f1302b98c3b8d07d34a91cfadc
-dist/2025-05-26/rust-std-beta-arm-linux-androideabi.tar.gz=aa93b2e198a1ea5f586851ecde2b1fc56a0e28e2c16e7210cd77b4357e327196
-dist/2025-05-26/rust-std-beta-arm-linux-androideabi.tar.xz=00e020d2654c6324b6c8070c9ac32b0838470ad74df711ea7c9940a4bdcbb71f
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-gnueabi.tar.gz=c0ed57ac290b57f654419e35f7950c6b2b2594638bfca5a060a49dff6febd2de
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-gnueabi.tar.xz=bcb7a661e83d7973ac0cf9ead4588595cbcf39e71867d1e2fb3e6e94f2506d39
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-gnueabihf.tar.gz=baf206be5648992a7280836ed7520b5fd6ca59a28d9aecfbf3769022ececc753
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-gnueabihf.tar.xz=a86cb2309e93b7a0ff92199e47e0a36f192221eb376966b1e4a49c8d5d5de7bd
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-musleabi.tar.gz=703b6baab5a33e6ed1acaad52781c1779146e1fa5d5974d19d354dc2279ccec6
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-musleabi.tar.xz=55e56cda5e2af49b0ccab4baeb0e8051c416c0321832742609edde9b1ebae8ee
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-musleabihf.tar.gz=7080221a8911393a012306c934043df6aa4d483411c90ca275d2539704d38120
-dist/2025-05-26/rust-std-beta-arm-unknown-linux-musleabihf.tar.xz=8d9ed7e57a37f328aeb4004f043887edd980e7ac0df8ff714566b0bf474bce99
-dist/2025-05-26/rust-std-beta-arm64ec-pc-windows-msvc.tar.gz=85cd1a37bc2977c116264a6e84f2c578c7a698e26bf7bd99e0713b14ec6c74c5
-dist/2025-05-26/rust-std-beta-arm64ec-pc-windows-msvc.tar.xz=6ee7ea565266040310050a4cf3e2afb1e85f956e0ad54a9642291949e1b376bc
-dist/2025-05-26/rust-std-beta-armebv7r-none-eabi.tar.gz=8c41876321a8bec594d028460c93396786739ed82f79ed8703cf54dfc1e7d51b
-dist/2025-05-26/rust-std-beta-armebv7r-none-eabi.tar.xz=fb1a88a048e1945dc2bb84aa47e027455c5a94acf416865c5ef26c6a1616414f
-dist/2025-05-26/rust-std-beta-armebv7r-none-eabihf.tar.gz=61561a8324bced38f5ee6c1c65348750162655315ddb5eb0f0142a48872faa8c
-dist/2025-05-26/rust-std-beta-armebv7r-none-eabihf.tar.xz=3e57bdf2dfb8cbcdd4b4f7e2523cd7946dd0d64d0ee17cf794b5a04dab26a46b
-dist/2025-05-26/rust-std-beta-armv5te-unknown-linux-gnueabi.tar.gz=c2586abead3190b936f1cdb46c472ee4c4b6bdfeb9c33165765922d3da0151a0
-dist/2025-05-26/rust-std-beta-armv5te-unknown-linux-gnueabi.tar.xz=24a64cbdabd8074219f7a27f266f695109bcd7fc3646cc78652cf2f3bc2ea099
-dist/2025-05-26/rust-std-beta-armv5te-unknown-linux-musleabi.tar.gz=a6b7e5ec522eb29582c7ca2d9a2a79f1658058c4db6b0442ccfae40e1403ff07
-dist/2025-05-26/rust-std-beta-armv5te-unknown-linux-musleabi.tar.xz=94f88e141605997ae9578b062de3f750761648847d0ed6fd18394d8dbb81afff
-dist/2025-05-26/rust-std-beta-armv7-linux-androideabi.tar.gz=e50086fac3b8e433d1a59724349122bde2172bc22db1175c7826635d978973c0
-dist/2025-05-26/rust-std-beta-armv7-linux-androideabi.tar.xz=2700b25ce1e6db9eadd2b3f63582fc3759963449781799216239b9e2daa9e51b
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-gnueabi.tar.gz=e507fd70d155f17fc3cd5e1b38b97a871d51090d4dd7069366d3e3e2a48c0355
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-gnueabi.tar.xz=8988863479cb0280851e1765de2810eebcfc1592100b052e88c51386a88c4c87
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-gnueabihf.tar.gz=519cfee0178123e15bea3544113ac3f4914a72fd619fdf11044ccc1b8b31c848
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-gnueabihf.tar.xz=5cf09c2f66482863ca9586782f56aa453c3fbe8ab48d80c18d5570b1d7a80455
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-musleabi.tar.gz=9949d9684b83610bcba9fd91cc66587d6216dc850cc7b6413a7dc0f80dc4ca2b
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-musleabi.tar.xz=cd87009d6362cc5777a664e537261227fda510a5e9ac1080a42b0f2fa7b4d364
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-musleabihf.tar.gz=a9a5280fc64bcb40dbd43f3fae1ee01dfffb06d4bbf1a635b79b923343f97060
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-musleabihf.tar.xz=bf1e9ef03fc1d727b59ffcd991c207c503db884b14134154ff674b6435dd7c92
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-ohos.tar.gz=9171f328fc67817f3f2e10209e0122ec7e9f0138ad8ffb4b19b64d21a72b9414
-dist/2025-05-26/rust-std-beta-armv7-unknown-linux-ohos.tar.xz=9d9974ccdd87fb741a568ca8966e21a044f8c40415b4e58bcf359605c6c3d8fb
-dist/2025-05-26/rust-std-beta-armv7a-none-eabi.tar.gz=402f7b7b4c132ec6a1d51c0528608291a423e16090b9f4327e447fdef5d8e771
-dist/2025-05-26/rust-std-beta-armv7a-none-eabi.tar.xz=9a8d857299c24a54a5c49b25d5b07bdd9eb77b4a4be853d6d12e5df4ac404c56
-dist/2025-05-26/rust-std-beta-armv7r-none-eabi.tar.gz=c8fc641d53bc04751d16283d50696ade8925e22d530cdd4f97facd7e2e4f878c
-dist/2025-05-26/rust-std-beta-armv7r-none-eabi.tar.xz=4773a4a02fa088d3c4231695cc698edeef39c2a0ac3f4d3a0eb272d7b8663705
-dist/2025-05-26/rust-std-beta-armv7r-none-eabihf.tar.gz=4ffc1f544f164f5e4a803fb9aacff693e00abcead950bde2d7065739e189058a
-dist/2025-05-26/rust-std-beta-armv7r-none-eabihf.tar.xz=e64d238b9468ecc3df0e3a20cbc0c2b3bd5a12500fad4b7194382106ee5c4aa3
-dist/2025-05-26/rust-std-beta-i586-unknown-linux-gnu.tar.gz=82ac2e07233a629ff1ea556be728fb1617ce085f5909ae3f3b9d8a792f73baca
-dist/2025-05-26/rust-std-beta-i586-unknown-linux-gnu.tar.xz=2c54755349f8d94511b15b29b527533be186f6865ee1b2022e5345f42b00f5bf
-dist/2025-05-26/rust-std-beta-i586-unknown-linux-musl.tar.gz=5debce1f9edbbbf0b8e2e8055525296d2d7c4a14bf561c7bc05e7eb953b5a034
-dist/2025-05-26/rust-std-beta-i586-unknown-linux-musl.tar.xz=e559611ce05ba79894c4e3bd9066701ea851708ca44c0189c93607fe8721640a
-dist/2025-05-26/rust-std-beta-i686-linux-android.tar.gz=17be4d733c597bc7ff5aefe1b5944df0d2f3f2274773f2691e863fcf18877251
-dist/2025-05-26/rust-std-beta-i686-linux-android.tar.xz=2603b3e9fa2b8a2f769ea3558037e4a20b1bd13101c518f05a5800935bb5b02b
-dist/2025-05-26/rust-std-beta-i686-pc-windows-gnu.tar.gz=3c2c9283b1fb0196bfedd8f87f1aaf00dbcadd52ca8fb40382262f86e21701d9
-dist/2025-05-26/rust-std-beta-i686-pc-windows-gnu.tar.xz=3067d576128325449174c9220d10c543644e94d6045764e32bfccd30cd94e94b
-dist/2025-05-26/rust-std-beta-i686-pc-windows-gnullvm.tar.gz=6df448b2a49f2f9f3f4fd0cb0ef758f31f00fbf2008b4a9ae2a1cc5818bbb21c
-dist/2025-05-26/rust-std-beta-i686-pc-windows-gnullvm.tar.xz=537a695b2377b1aa4ed31970b8170ddc575c18c180faec5602febe71bc44088d
-dist/2025-05-26/rust-std-beta-i686-pc-windows-msvc.tar.gz=d45afe32951d926702d62d5a94b5343c3cd2f1d04497af3412dc6d1ccb97be05
-dist/2025-05-26/rust-std-beta-i686-pc-windows-msvc.tar.xz=bd8a25921b63d3d4fe13219422a324a538a08284dac681153d960cd25fd02c6c
-dist/2025-05-26/rust-std-beta-i686-unknown-freebsd.tar.gz=e8ad2a8eae371b8a99251bc3337732f3e47457a8d740a9609f96206291589f43
-dist/2025-05-26/rust-std-beta-i686-unknown-freebsd.tar.xz=e2edeb9636cab8ba8489d28e829c039d4e547ccdbfd4023f98943341f5cad96c
-dist/2025-05-26/rust-std-beta-i686-unknown-linux-gnu.tar.gz=9b319357a2c6d75d0140bad5241a72e4d858e06962c024414449299f83bce9b4
-dist/2025-05-26/rust-std-beta-i686-unknown-linux-gnu.tar.xz=b4447663123e42a950943829f661283d6b36f3da14750c811d6704a2edc64b40
-dist/2025-05-26/rust-std-beta-i686-unknown-linux-musl.tar.gz=4391070bdb67171c4063df3d801dc66e16c097165873c5c219659e1e706028fb
-dist/2025-05-26/rust-std-beta-i686-unknown-linux-musl.tar.xz=48e566d549dff7bde2a1cb07c55ee0a2537147f66e4ca8a7bc9ac9ebe104de28
-dist/2025-05-26/rust-std-beta-i686-unknown-uefi.tar.gz=3176685b3b5b3d0f44655f5449b328ff8c2e4a577d1076a2692f2e7062004e3d
-dist/2025-05-26/rust-std-beta-i686-unknown-uefi.tar.xz=2c0983eaec9d5cca76fdf0fceb3461960e5bcb162c2409169d0c6ddfc5497f8a
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-linux-gnu.tar.gz=17e49779ef3931acbc2828a5a674e1d9032f08ca6166cb62a9ba7dc156b06ee8
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-linux-gnu.tar.xz=7411b776b6fb10d0a10e3de19183caeb9980f523aa014a5b320bb4422f2301a8
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-linux-musl.tar.gz=1a54d2d8b31a84693738a896068e38506b9d8e94f660368c6674ca66d38fee89
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-linux-musl.tar.xz=1023907e072bf083168497dea8801544d2f407cdba1ad3157977032c92e7c4d8
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-none.tar.gz=86135dbb69909d33a0d6bf0caeb35f190299f594b062238e3d18ec7ffab26150
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-none.tar.xz=3e9733daceb421f6a2e00a1c8d7ba2ad87332127ca0fedfc391bd0715836da2f
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-none-softfloat.tar.gz=6190b439b569ef1a5aa832445ac60bb5b4ef605ff8f41a0ad1cdc5f5cb0de28b
-dist/2025-05-26/rust-std-beta-loongarch64-unknown-none-softfloat.tar.xz=8e5a7224d8abd8010a4278f7e767aecdcde7060ffb16e0a5c8de579c5d86e21b
-dist/2025-05-26/rust-std-beta-nvptx64-nvidia-cuda.tar.gz=2006ea99dcecccabf97d74f3f582f8a29c4e69caf27fa9a689a28702a6d9b1ad
-dist/2025-05-26/rust-std-beta-nvptx64-nvidia-cuda.tar.xz=7baffc71f0e9279439775b95280206411ef04bea7eb4ad38096a11a38e38dd47
-dist/2025-05-26/rust-std-beta-powerpc-unknown-linux-gnu.tar.gz=9650a6a1812492df104c0df20c5db422678e2f7a84e33a83aedf1d9c602369d6
-dist/2025-05-26/rust-std-beta-powerpc-unknown-linux-gnu.tar.xz=4a265f557aca1b2cc3d377be693bf9fe90c4b0ced99e77a406849aaaf3ad7eff
-dist/2025-05-26/rust-std-beta-powerpc64-unknown-linux-gnu.tar.gz=6aedb018d3758c3f1e8d5d3e69f0c996c35fba18338346b43ad7e9099621d714
-dist/2025-05-26/rust-std-beta-powerpc64-unknown-linux-gnu.tar.xz=3886265ec1bd94ae47146db67bc2a72fdd9d70b64c74878fc1ef9c50498b9f23
-dist/2025-05-26/rust-std-beta-powerpc64le-unknown-linux-gnu.tar.gz=60c8355e9f6c59a329b111b4abd7b8feeb493dc0e4d8d4ec1b07809a9ac6923e
-dist/2025-05-26/rust-std-beta-powerpc64le-unknown-linux-gnu.tar.xz=0c687a9b04b1b36a14c972913dfb9f0d230551f301a895593f1623677b59a26d
-dist/2025-05-26/rust-std-beta-powerpc64le-unknown-linux-musl.tar.gz=29fc686f26c6258a542e118a035924167c3c6b2b007980f89101cd50ca3543f4
-dist/2025-05-26/rust-std-beta-powerpc64le-unknown-linux-musl.tar.xz=a6d643c2c794a405ee6bfa7e8f3c19cf2b94a17c61d743763dd6939ed8641d0e
-dist/2025-05-26/rust-std-beta-riscv32i-unknown-none-elf.tar.gz=781b81baa8dfd9a5e7eb346176e9cac1e83cba42d1943677b08c689d535debd4
-dist/2025-05-26/rust-std-beta-riscv32i-unknown-none-elf.tar.xz=ca46997729ba43239372bda073a20c1a5d6d25c00cfd79105dd44ff634cacf84
-dist/2025-05-26/rust-std-beta-riscv32im-unknown-none-elf.tar.gz=d0173b18212cf346c5477b8fa1292f51db7fa7275455417ede405f6e822548b1
-dist/2025-05-26/rust-std-beta-riscv32im-unknown-none-elf.tar.xz=6357a65bf47d918d8375e0f7f0f3cfa137026a3be7123a2ae1ae827a71e96c31
-dist/2025-05-26/rust-std-beta-riscv32imac-unknown-none-elf.tar.gz=dc0b7a21b4e597320bcf63c84812ae9caab0aafd215aafa10187820ba91d6490
-dist/2025-05-26/rust-std-beta-riscv32imac-unknown-none-elf.tar.xz=f42b4e807be249463cb9e4f3781b45c45492c0badc45ee6baacb50d61fd3fd42
-dist/2025-05-26/rust-std-beta-riscv32imafc-unknown-none-elf.tar.gz=78cfa47f2376a73f7247ac69968ce0752129cc57f7961fe0c12509b27411e232
-dist/2025-05-26/rust-std-beta-riscv32imafc-unknown-none-elf.tar.xz=2b2ba34b8c6992e4f253e30d80df578e9ac8063264f61cfec0b0fedb9b823ef6
-dist/2025-05-26/rust-std-beta-riscv32imc-unknown-none-elf.tar.gz=27ef3d52ca7b2e1294506f3e105fb5753f468e5a29f1a84804213a055a885719
-dist/2025-05-26/rust-std-beta-riscv32imc-unknown-none-elf.tar.xz=71b0a54a82cf5f69da177559494b2601c55c3e3bd0bea539ce69e7499c3150a1
-dist/2025-05-26/rust-std-beta-riscv64gc-unknown-linux-gnu.tar.gz=d11ccac57c31274b7b3dac4b1761a04a806ddf368c00e7a16644390ba221154a
-dist/2025-05-26/rust-std-beta-riscv64gc-unknown-linux-gnu.tar.xz=f636c9cee16b8e676597b31956d6827e1bac7ccd83c730653953affce9724a96
-dist/2025-05-26/rust-std-beta-riscv64gc-unknown-linux-musl.tar.gz=806dab8bfe031f0043706992a9426e8580e82a92df11ef5728e6a00da13cb40a
-dist/2025-05-26/rust-std-beta-riscv64gc-unknown-linux-musl.tar.xz=b48f6e9641db567e8728db48a062b0cc570ee2712af7adfc64dcb4f4ab355396
-dist/2025-05-26/rust-std-beta-riscv64gc-unknown-none-elf.tar.gz=8d779f261e4c0e62e8c6a616f2635dc74cb4637366386b0857f31fb015fcf152
-dist/2025-05-26/rust-std-beta-riscv64gc-unknown-none-elf.tar.xz=7d12366c1c1166e50d2a78f1ac3fe3166935b4920eac8f64e878a6b5f8653a6a
-dist/2025-05-26/rust-std-beta-riscv64imac-unknown-none-elf.tar.gz=6c01c064a5812f55004ecce5c514c1aeead262dda2525fc7225bbc68d0020d5b
-dist/2025-05-26/rust-std-beta-riscv64imac-unknown-none-elf.tar.xz=1be564ed4d96e15ed8eaad48a0b64112d05a9096a2fc56245e38ef9fc3098865
-dist/2025-05-26/rust-std-beta-s390x-unknown-linux-gnu.tar.gz=9329f4c55d1c9216ddbe684d0b246f65724d0919a009d066987052bb27a867db
-dist/2025-05-26/rust-std-beta-s390x-unknown-linux-gnu.tar.xz=3e164f2c3af1850902a7852d5b043f6ac2065b02d0786912b66c83c1371f71e6
-dist/2025-05-26/rust-std-beta-sparc64-unknown-linux-gnu.tar.gz=613cd5db53ae3f2c69eddbbbf39957a6931b9b5ab1766135b150e01396cff220
-dist/2025-05-26/rust-std-beta-sparc64-unknown-linux-gnu.tar.xz=03d9f75b9a4126c81b1896dcfafadecbbb6f4e81fdc774023f81acc28ed125c9
-dist/2025-05-26/rust-std-beta-sparcv9-sun-solaris.tar.gz=fd5aad29a1ac50b469629fa7ead7d503060909f2640750084f0a72f8d9699456
-dist/2025-05-26/rust-std-beta-sparcv9-sun-solaris.tar.xz=942a34da917069072ac610dbc3667cd847dfadfe3df09d6ff3aebefd49311041
-dist/2025-05-26/rust-std-beta-thumbv6m-none-eabi.tar.gz=91024331bd867a1ed71b687509fe694f924bef58047a9137c7a759ae783179f3
-dist/2025-05-26/rust-std-beta-thumbv6m-none-eabi.tar.xz=e3b5096e07f3587c87fd6832b852882f7d63fbc6b8819de452ce5883e26742e1
-dist/2025-05-26/rust-std-beta-thumbv7em-none-eabi.tar.gz=40f0dcf8654464732add7e8b3e1a1d898699fbf50be74b116650c8251209f913
-dist/2025-05-26/rust-std-beta-thumbv7em-none-eabi.tar.xz=6193c72b9c4c7ca27b12da0f13dca0ac1d11b1cb2a8868a7f2e7f24ab3e7a78f
-dist/2025-05-26/rust-std-beta-thumbv7em-none-eabihf.tar.gz=a008f4debee859f5c5b90aa4000774cdaae045f8161b8e7fbfaab68db7f2341e
-dist/2025-05-26/rust-std-beta-thumbv7em-none-eabihf.tar.xz=bb96feab15991aea5fa38f22848a715422c0b1da060b34a7273f3ec077d4a4e3
-dist/2025-05-26/rust-std-beta-thumbv7m-none-eabi.tar.gz=46e8c8f891c22cee04de8c02aa1e0f5604a9bcd33219cfd1a299c43b4005f93f
-dist/2025-05-26/rust-std-beta-thumbv7m-none-eabi.tar.xz=d4dbed9d96c6b57e185ede566a3dc610f03d854ff696466e9c68815b85dee963
-dist/2025-05-26/rust-std-beta-thumbv7neon-linux-androideabi.tar.gz=222d18565a0d40edc3d6cb051f2647b5416b417933fcdcd25bba54fc55de625f
-dist/2025-05-26/rust-std-beta-thumbv7neon-linux-androideabi.tar.xz=4190060ea541ad1f1f5eb91815027ba475d0e1281ded77ee3116561660919550
-dist/2025-05-26/rust-std-beta-thumbv7neon-unknown-linux-gnueabihf.tar.gz=bf99b1d2a8997d36f994f31bcb48482ec3d48f962ed66beb8642025859c53d97
-dist/2025-05-26/rust-std-beta-thumbv7neon-unknown-linux-gnueabihf.tar.xz=477fe3a269b43ca2f795fef83b50697600021129678aa6af1594858bfeb9479d
-dist/2025-05-26/rust-std-beta-thumbv8m.base-none-eabi.tar.gz=bbd981f00bdad617fdaf823d78cd6f500807b742e050a3d4cbd42ed2966ac7d7
-dist/2025-05-26/rust-std-beta-thumbv8m.base-none-eabi.tar.xz=8a8c004818d5fe2eb9f99d77f65810f577bc1e8cbba0ba2ec6e045234c6a700b
-dist/2025-05-26/rust-std-beta-thumbv8m.main-none-eabi.tar.gz=7e015ea2920c65337b61d5fc1a5f619cfef6589483a4e6c09d8dfbe1529972b2
-dist/2025-05-26/rust-std-beta-thumbv8m.main-none-eabi.tar.xz=37b2b934afd57a81c4007cb4b8b901fe7b15334588625e98d79b037876f18725
-dist/2025-05-26/rust-std-beta-thumbv8m.main-none-eabihf.tar.gz=919db1cc7cbe3e52a6e33f03fe4e79504bef2825ffe58895e24130907bad7b6b
-dist/2025-05-26/rust-std-beta-thumbv8m.main-none-eabihf.tar.xz=59b8ced330f72dc06635aff3de2cc7c796baee86320ff8458d8dc995ba11b909
-dist/2025-05-26/rust-std-beta-wasm32-unknown-emscripten.tar.gz=5d5298f0a3d9a8a8cee3ad9003c409adeed1b3fcacac449a5827f14099b052a6
-dist/2025-05-26/rust-std-beta-wasm32-unknown-emscripten.tar.xz=e9b8868b05e0d210419f3b041839f60e0d4fdd7bd54eca6b0f96b5f90148cdf9
-dist/2025-05-26/rust-std-beta-wasm32-unknown-unknown.tar.gz=35a70b6c8369ca487d93c9cf445a0011ff13dd5cea485a4d01558167473130f0
-dist/2025-05-26/rust-std-beta-wasm32-unknown-unknown.tar.xz=5243ebcffd4880cecae8c3a90c9c76bae1da188478d5e572a8a71cf4442ca991
-dist/2025-05-26/rust-std-beta-wasm32-wasip1.tar.gz=f39ae9fc833c1e0d6b3aa3a3782f7dd1e547c7f6b0141c52e0c7cb5b6fa30def
-dist/2025-05-26/rust-std-beta-wasm32-wasip1.tar.xz=caa1d6e9eb7663ba34dc7db1d47bbd972b41f22f458afd95a6a0aaa0d7e26f59
-dist/2025-05-26/rust-std-beta-wasm32-wasip1-threads.tar.gz=9f0de2858a6ee7de500562fb9639e68cdebc45a6181778ffb41be77af74fdead
-dist/2025-05-26/rust-std-beta-wasm32-wasip1-threads.tar.xz=98523168355e334dbcf0730c314ad9fe901751eefd61d567878c34f21c30ec98
-dist/2025-05-26/rust-std-beta-wasm32-wasip2.tar.gz=8cfdd1d718208fead76aaebd54ad44e9f98145664e475914f7b9951372c1813d
-dist/2025-05-26/rust-std-beta-wasm32-wasip2.tar.xz=64fed08a0d9b09097a9370ee4b013332d19587b5de67b0f0af49bc09625c765c
-dist/2025-05-26/rust-std-beta-wasm32v1-none.tar.gz=ff212273e3d5c4e465d8a3d8838716f2b2e2380f82c158d13dba997df4a8fb0b
-dist/2025-05-26/rust-std-beta-wasm32v1-none.tar.xz=8300711696bc8988e6e00baea2d15012f373525436f1415f54037e10511acd83
-dist/2025-05-26/rust-std-beta-x86_64-apple-darwin.tar.gz=77d89abf4d00195e240b8f55ab2bc5558d21f0f1fee33bf419d14a3e3f2b3ab1
-dist/2025-05-26/rust-std-beta-x86_64-apple-darwin.tar.xz=817dc01f12d7a2c388b001bd708aab2967afce42a11aecfa278a40235800e1cf
-dist/2025-05-26/rust-std-beta-x86_64-apple-ios.tar.gz=cdcbeb20884c7782e080ae38ec6dd955706fa2e924ddfd235d775e39be2cb446
-dist/2025-05-26/rust-std-beta-x86_64-apple-ios.tar.xz=378d04709658b08a24edff046bbc6b3fbee7d0127fff93818e92cda0234e0837
-dist/2025-05-26/rust-std-beta-x86_64-apple-ios-macabi.tar.gz=81d68c70d385f38f526856d021aa1b5b25e9bddff52b8098d76a87c53721784f
-dist/2025-05-26/rust-std-beta-x86_64-apple-ios-macabi.tar.xz=e9cd869473a379a72364b1246fee3007d9b45801e40a3cd2eecc7831edba5bb4
-dist/2025-05-26/rust-std-beta-x86_64-fortanix-unknown-sgx.tar.gz=49c18132004107623e554264b000d07ea0a1dc51ee1e21d02b833b9fdb07b855
-dist/2025-05-26/rust-std-beta-x86_64-fortanix-unknown-sgx.tar.xz=be2269500b5522f677eebf74c0a201751c74481568ba235200716fe368f443e2
-dist/2025-05-26/rust-std-beta-x86_64-linux-android.tar.gz=25801215e0bfa5af3b2b84aa0b881fa723cef308872de58e36d2de943746e51b
-dist/2025-05-26/rust-std-beta-x86_64-linux-android.tar.xz=f692f2f3c69c8fa62d5344faa75375fd2a48a1b81284a7fbfe4b41f575c7263f
-dist/2025-05-26/rust-std-beta-x86_64-pc-solaris.tar.gz=7d79359bc70414d23174aac81b1e5c341b541f6a8361142a3d48ddfc956dc7fd
-dist/2025-05-26/rust-std-beta-x86_64-pc-solaris.tar.xz=ec42340a3bbaeb9723ec77a48b4c49496ee61a928ae20c1bdf3ca33859a3fa52
-dist/2025-05-26/rust-std-beta-x86_64-pc-windows-gnu.tar.gz=6ad0c0a19a92af2749dc8680dcc14bc1fa9fc1d3f4bcf8e28b0646c3bb50859b
-dist/2025-05-26/rust-std-beta-x86_64-pc-windows-gnu.tar.xz=e3e1ecbf40411fa9216a43573b765c526652205f2978409b5488c25b19e98375
-dist/2025-05-26/rust-std-beta-x86_64-pc-windows-gnullvm.tar.gz=a62671dc133e7cc059ed4ad004946e9030e8b882094ddd81b282c56363b0644a
-dist/2025-05-26/rust-std-beta-x86_64-pc-windows-gnullvm.tar.xz=16aac5f5f78f067dd4e2106d62a31fff071757bebf53742eb72f25a5abb2d7af
-dist/2025-05-26/rust-std-beta-x86_64-pc-windows-msvc.tar.gz=d2c5c7a89dc122a7edf1120c3765e55001b3ecca57fb8077b6f4e6085c9fb6af
-dist/2025-05-26/rust-std-beta-x86_64-pc-windows-msvc.tar.xz=14b0a62b8dca999d96ff6cbc7fa8dfc3486555be9aae4d509dd95fba01db8f65
-dist/2025-05-26/rust-std-beta-x86_64-unknown-freebsd.tar.gz=fc3ead4c4599e5371668c610658538dc2bab3b3db2ca9aa1645da087649df131
-dist/2025-05-26/rust-std-beta-x86_64-unknown-freebsd.tar.xz=9e7477e05192ce11190e9b1291a5e171a9cd9da9ca2f4c53d08b98025a697255
-dist/2025-05-26/rust-std-beta-x86_64-unknown-fuchsia.tar.gz=b21552a046715dabb5b14d82fc9707c6622073b013b839f1b08e0463dcf536ac
-dist/2025-05-26/rust-std-beta-x86_64-unknown-fuchsia.tar.xz=1ed92b1672f0d18ff0d6f8365326478cdcf60af25837924f54d3c7459a4dcdf4
-dist/2025-05-26/rust-std-beta-x86_64-unknown-illumos.tar.gz=14d1ffa188c1e4b64d9ac941698922d2a46d0fab78498c6499d5782edd529968
-dist/2025-05-26/rust-std-beta-x86_64-unknown-illumos.tar.xz=41cca6d938e5c39e4032f94256ecb4efdd76c1569e29f84191d58be5d3c0773a
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-gnu.tar.gz=444f4875970842d935d1a42a46ac524b6bac248d4bb5993e5ac578ee88f519cf
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz=354c0e9396e7b241a7e8c69e3670d98a42ed8bb7359d4f06deefa4fdf81df675
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-gnux32.tar.gz=efb7bc1afab8d3f3f6de3fbf41bfb3ae17bb3e193644ae40be5d497aba20d1cb
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-gnux32.tar.xz=c717608c4378ecf44cf3ef9d3ab8c5e6bc29db0b1c9b04054b42c60fb5109ff0
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-musl.tar.gz=1e4f8c03396b130a284a3a11c20da15185d3a9cbbb6d9a219a76e0e192cbd2a0
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-musl.tar.xz=b5639086009cc35a8fd493fc885cebbf2dc68b4d4fc956b00bd5061ec4ed75b1
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-ohos.tar.gz=cd577082d0fb089e42ea31509f92321b40221b54f73edb0f80510f6e170acc6d
-dist/2025-05-26/rust-std-beta-x86_64-unknown-linux-ohos.tar.xz=2257286555b3208b43390284db141d2db7282a7d2d4c438fd3b217de3ede790a
-dist/2025-05-26/rust-std-beta-x86_64-unknown-netbsd.tar.gz=61205a7f309f18f9e1a8c12c9b74902f014475ea357fdadf728858f9f81d6e73
-dist/2025-05-26/rust-std-beta-x86_64-unknown-netbsd.tar.xz=d11ae113c9d4156ef31561c002a9b65ef702302c89b0dd2b3005bef57ba92d01
-dist/2025-05-26/rust-std-beta-x86_64-unknown-none.tar.gz=8583686c6aa8eaeb57b64dbc288d564fdaf4939d6f552143e7cdc0641147192d
-dist/2025-05-26/rust-std-beta-x86_64-unknown-none.tar.xz=64a654c790902abf4f936a3194757eb6885d88a68cbd8de19767a8e7a0f21335
-dist/2025-05-26/rust-std-beta-x86_64-unknown-redox.tar.gz=b80e62b6982c684d5550233c15299533fa709e540e53bf20e7ed06fc09e396d1
-dist/2025-05-26/rust-std-beta-x86_64-unknown-redox.tar.xz=63a195aab6fe29882c7a0688ca2368a611127381320349c7cb1097dcde2b4603
-dist/2025-05-26/rust-std-beta-x86_64-unknown-uefi.tar.gz=3f285485b3a7bd957ad69cb76ff717d7987ad0bc50368aeb1b813f9b2d3b5af5
-dist/2025-05-26/rust-std-beta-x86_64-unknown-uefi.tar.xz=dc1e9a9952adbb65711ebcb79b7afc149ac1c9f73b69b97f6b059a53ac71067c
-dist/2025-05-26/cargo-beta-aarch64-apple-darwin.tar.gz=368b6cb43f573346237012bdc23e5c44d476db779795464cecc2065f6fda8b8f
-dist/2025-05-26/cargo-beta-aarch64-apple-darwin.tar.xz=4bbf76bc026d740269c09658a3218eee2dfcc7422fe233db192cfee4dc4a371e
-dist/2025-05-26/cargo-beta-aarch64-pc-windows-msvc.tar.gz=afd53341d1c84f86ddcb4ee85affc0413715c05bd43c075ef193306e86126488
-dist/2025-05-26/cargo-beta-aarch64-pc-windows-msvc.tar.xz=2cf06c20e07ab905f329c8ffcf275b7cd528488893c7014a1cc03faafb13d2c6
-dist/2025-05-26/cargo-beta-aarch64-unknown-linux-gnu.tar.gz=8ca26bf35ed608b6b6ebdff67f7949bf8219f32edb1ece3ca9f8d49a182cd8ed
-dist/2025-05-26/cargo-beta-aarch64-unknown-linux-gnu.tar.xz=61a8743d62dd505d7d76b2ffd282e2b41653b0b30eb96e7f950f144201270a21
-dist/2025-05-26/cargo-beta-aarch64-unknown-linux-musl.tar.gz=8cd37cda7f2f2c323ebda896fc2fb8d8a83b30f2b9c102a1305bf724c261566c
-dist/2025-05-26/cargo-beta-aarch64-unknown-linux-musl.tar.xz=fa5f4fa4da574b2bc79db4dd37969ba5549b32acb65554e35735b55913ab6e53
-dist/2025-05-26/cargo-beta-arm-unknown-linux-gnueabi.tar.gz=30a29adc0c331a3cdff5c1f1d8b541f720212a3b8b2c96795e95f96ffb5982b2
-dist/2025-05-26/cargo-beta-arm-unknown-linux-gnueabi.tar.xz=069071883eee8226003b1cd8501868b3aa51ec8d0f0637e4538b30b920d05823
-dist/2025-05-26/cargo-beta-arm-unknown-linux-gnueabihf.tar.gz=0151634d3a2a1757b9671cf9d48cbfd5fa34df77744ffeac02d8cb5f6949cdc1
-dist/2025-05-26/cargo-beta-arm-unknown-linux-gnueabihf.tar.xz=524386061e1b6b212cd9f94d9d7baf2cd1eb9b2ee105c334aaffcc192cb38e19
-dist/2025-05-26/cargo-beta-armv7-unknown-linux-gnueabihf.tar.gz=d392c9fac6521b2377928305d87e1d65f70e6a5472d4ded3475e08118186f2b1
-dist/2025-05-26/cargo-beta-armv7-unknown-linux-gnueabihf.tar.xz=b1ff6f50dd621d7af5224dce74a25ae895e6b06216fe8e1501ff4199c04f0374
-dist/2025-05-26/cargo-beta-i686-pc-windows-gnu.tar.gz=52ebc95b1c29d3c0714c66505f0ef838c13d12d9436f1d2c2291cf027a38697f
-dist/2025-05-26/cargo-beta-i686-pc-windows-gnu.tar.xz=c6acb26d5e9a4f8c51c13f8b92560849cc4df822a80d04b0e61b1407e93555d5
-dist/2025-05-26/cargo-beta-i686-pc-windows-msvc.tar.gz=af54473c85c035105c429138cfc0d5ab30dcc1b13ea01a3e4d12a8342c309e98
-dist/2025-05-26/cargo-beta-i686-pc-windows-msvc.tar.xz=3a44659128f07fe5953659506c1b6c93fbea96a327401064dbe0393ddb28542d
-dist/2025-05-26/cargo-beta-i686-unknown-linux-gnu.tar.gz=39632af7bcf55760161ddd4ebfe40a3c9a49b6191ec88d1b1d66390668d09905
-dist/2025-05-26/cargo-beta-i686-unknown-linux-gnu.tar.xz=190e8b6bda864b4316f530e5d693e779074de8665a5abe6a4f5cbd01ce8fe6b7
-dist/2025-05-26/cargo-beta-loongarch64-unknown-linux-gnu.tar.gz=87d25663fa5b4b09fff9ea02c07bdddf760873bad7c425015d6e1750a24f66a4
-dist/2025-05-26/cargo-beta-loongarch64-unknown-linux-gnu.tar.xz=b0789d6fe6d8f7e07f0858211e59ae9278adee7d14dee64fc359b3079773993d
-dist/2025-05-26/cargo-beta-loongarch64-unknown-linux-musl.tar.gz=d0f43421313fb6d43ec9b165dc2c9f6be91daee61f201eaea6735fa6ddaadda7
-dist/2025-05-26/cargo-beta-loongarch64-unknown-linux-musl.tar.xz=3e2de8fe7062494c260d0560253e03fc45baa680f9a62171350c5caf2e5fb426
-dist/2025-05-26/cargo-beta-powerpc-unknown-linux-gnu.tar.gz=93a901615aeaa14dcaa0ccd2fe870ccd29bb4f52601cb7ff3b2da7bc6c3e1b22
-dist/2025-05-26/cargo-beta-powerpc-unknown-linux-gnu.tar.xz=28ab251856c6a252beb72a5db0e18e68e40b342fcbd903dd75811ba393b44194
-dist/2025-05-26/cargo-beta-powerpc64-unknown-linux-gnu.tar.gz=6c1f5cb9ec7787cf004c3efa6da81a93155ff3b5319ba7c6ffd29ba631a0feb2
-dist/2025-05-26/cargo-beta-powerpc64-unknown-linux-gnu.tar.xz=9a09c0f8d027310b26909c193227466402ef616c27b943ec16cd5a7eabca5ca9
-dist/2025-05-26/cargo-beta-powerpc64le-unknown-linux-gnu.tar.gz=c5c81cbf63206e47989c5a11953289f99e72647aff4d876d18fb8d2c99a54d1a
-dist/2025-05-26/cargo-beta-powerpc64le-unknown-linux-gnu.tar.xz=d187d131e679bebcdae5a7b9e828285f55b61cbc124e72d233725e4e0f2dbc39
-dist/2025-05-26/cargo-beta-powerpc64le-unknown-linux-musl.tar.gz=883c45f3a2a659560187cbc7696a3132163d6385dd155007c4d5fd2fb068dfb7
-dist/2025-05-26/cargo-beta-powerpc64le-unknown-linux-musl.tar.xz=f9d36abf952bed0e4df94dbeab0ef732ed731e6f8740c5be0ff96f603c46f4c1
-dist/2025-05-26/cargo-beta-riscv64gc-unknown-linux-gnu.tar.gz=23e25b899432df81b660105786f038e95bbddb3bab60a7917e4ca077d5b7520a
-dist/2025-05-26/cargo-beta-riscv64gc-unknown-linux-gnu.tar.xz=885a2c1e30eb3d489a1234034663131c8762645ec1c03ce94198053a21debfa7
-dist/2025-05-26/cargo-beta-s390x-unknown-linux-gnu.tar.gz=f9b69f26f868a5a2173de74424be26cb0d4e6db6867e1a8c32db799e9fb03ede
-dist/2025-05-26/cargo-beta-s390x-unknown-linux-gnu.tar.xz=bf3d01fc0202bcdea158e22821e1ffb8b07e4324ce487be96cde2cf1f1e5eaf6
-dist/2025-05-26/cargo-beta-x86_64-apple-darwin.tar.gz=65b4ee4359e402e06cee2c574a03389e36acb4e1caee4aa83cb281f95c48576a
-dist/2025-05-26/cargo-beta-x86_64-apple-darwin.tar.xz=2906bd00506ada8cffb743f355aa918531273f45f449616410dd0c3f913013b3
-dist/2025-05-26/cargo-beta-x86_64-pc-windows-gnu.tar.gz=7b4c8ad29c72d619c2977f5d79cb5c959bdd8acaae2364495962db5473478609
-dist/2025-05-26/cargo-beta-x86_64-pc-windows-gnu.tar.xz=0dfddbc3218d921ac75affe9d3b8595c8d49df9a98d91fe0f92341754f2b6296
-dist/2025-05-26/cargo-beta-x86_64-pc-windows-msvc.tar.gz=43a110d4e7cd3c8a764e4a2836fe368a347ba7fdfd40c8f565969244964d20c1
-dist/2025-05-26/cargo-beta-x86_64-pc-windows-msvc.tar.xz=703d2cce50711a9753c5b7a72c9468d73144a8f6015db913920795590c54ac97
-dist/2025-05-26/cargo-beta-x86_64-unknown-freebsd.tar.gz=9236099e0ffff060c483cc8996e66ca2e906a2c030941aa49163bdc4dfb7bd3b
-dist/2025-05-26/cargo-beta-x86_64-unknown-freebsd.tar.xz=ff50d29e650cf85f6aadee0618ffef15ac4f3c9b30f02f9a678129e9bf8f5ad3
-dist/2025-05-26/cargo-beta-x86_64-unknown-illumos.tar.gz=ea5bd3cd42867e5174f7661fb5254d2f3effadcf0551cf3cbe6fa60d718f48ae
-dist/2025-05-26/cargo-beta-x86_64-unknown-illumos.tar.xz=e3249f14d4467644a73b950d3d9a4f5ac20146923c961bdec3689bbbd4330a38
-dist/2025-05-26/cargo-beta-x86_64-unknown-linux-gnu.tar.gz=e0c5dc6ee9250c0ddbd7db218878fffc5a38641fc773ded5dc28d92a1750eed6
-dist/2025-05-26/cargo-beta-x86_64-unknown-linux-gnu.tar.xz=53921721c33e20275eb7a912ae80af22aa3e888a232360baa3f00f272114833f
-dist/2025-05-26/cargo-beta-x86_64-unknown-linux-musl.tar.gz=18ea106ff675f15b112c4f4dabcb068857a54c6dbd25e9e8661184b2ee3db556
-dist/2025-05-26/cargo-beta-x86_64-unknown-linux-musl.tar.xz=ea4db9c40954dd72896ef9323767384f2da48064465f8961b775f87c8944d0a8
-dist/2025-05-26/cargo-beta-x86_64-unknown-netbsd.tar.gz=05e8398cb96e2c5ebc2db71edd0965c6da755bd14b1598197f5d375d2b0c1cf3
-dist/2025-05-26/cargo-beta-x86_64-unknown-netbsd.tar.xz=ede3da14f0e405398aa9cfe3743d568a37b1adf62aa2a16489b710d773b1744f
-dist/2025-05-26/clippy-beta-aarch64-apple-darwin.tar.gz=43cbc31dce5ca5abc1efcf87fc4609d148d456429d41836c502f217de50aaaab
-dist/2025-05-26/clippy-beta-aarch64-apple-darwin.tar.xz=1ea6c9615a8c3101acb36585d12ec3a61ba55ec069155324675aeb0005738bf4
-dist/2025-05-26/clippy-beta-aarch64-pc-windows-msvc.tar.gz=eec62be5aaa28c856954a2d5e3fbdce10377bd164929ea6d18e43c085ff5044f
-dist/2025-05-26/clippy-beta-aarch64-pc-windows-msvc.tar.xz=76e60d581deb1989f93ec88e94fc984568c69486c9b50c88e1059f18560cf649
-dist/2025-05-26/clippy-beta-aarch64-unknown-linux-gnu.tar.gz=be69d0e6ac05d624dece95d6e6f9a90f8f8e52be2c1fde4b5d64fd9da8d89c7b
-dist/2025-05-26/clippy-beta-aarch64-unknown-linux-gnu.tar.xz=198c679a62e71d108688d3b64a5be76ecd6462f3301c0ee411943678bae640ce
-dist/2025-05-26/clippy-beta-aarch64-unknown-linux-musl.tar.gz=c9012719c15ed4fddd04d4ac3618018a1c194f048e9879acbbb580346a72bda9
-dist/2025-05-26/clippy-beta-aarch64-unknown-linux-musl.tar.xz=7f10e2a9164ae2cd916e82ef569a1f729853ecdc8edfd92012c63e03ff9b5786
-dist/2025-05-26/clippy-beta-arm-unknown-linux-gnueabi.tar.gz=8388777a665a098add359f5dfb10c2e85e6d5ff344b71844267750c589d9dd9f
-dist/2025-05-26/clippy-beta-arm-unknown-linux-gnueabi.tar.xz=ecbd41ae30412624507a6338c25b398b34153762d127bcb413321510334b7036
-dist/2025-05-26/clippy-beta-arm-unknown-linux-gnueabihf.tar.gz=47b420620eae76da5db8fbb2e0a7f23988b436bfce22d17cd44885daac011d7a
-dist/2025-05-26/clippy-beta-arm-unknown-linux-gnueabihf.tar.xz=21fe8e08a556bc6c70bff20e13ea2b54fc6f97656911b960f27c665c6d9d45d2
-dist/2025-05-26/clippy-beta-armv7-unknown-linux-gnueabihf.tar.gz=ded5cec25a893481d0735228946518b3bbf22becb298d5bd72ffa80c338d423b
-dist/2025-05-26/clippy-beta-armv7-unknown-linux-gnueabihf.tar.xz=26ce2e33c7434e2da0d3dd48ea2d57d2cb08eb52d041ff6539bc7d6e6f6ec13c
-dist/2025-05-26/clippy-beta-i686-pc-windows-gnu.tar.gz=e38aa8d7ee0d74e73ed07ebd173549be67654ecf3e781e8386d47c11175d150e
-dist/2025-05-26/clippy-beta-i686-pc-windows-gnu.tar.xz=e35de2fd0152277780464f80bed8aa78feb2e1e64b818888b32522d36ddc6ef2
-dist/2025-05-26/clippy-beta-i686-pc-windows-msvc.tar.gz=b4d259b042439f1324c91580b5d050eebfab04afb86715bc7571f17174f7622f
-dist/2025-05-26/clippy-beta-i686-pc-windows-msvc.tar.xz=7183a9094ebe14baf68a42e7879953c8d433febdad5b32153371d21c65dd86ca
-dist/2025-05-26/clippy-beta-i686-unknown-linux-gnu.tar.gz=d42ba45cc7f6ecec2cfad85fd15d69b17a84d19206fa5c33f1016d135ee29e6f
-dist/2025-05-26/clippy-beta-i686-unknown-linux-gnu.tar.xz=ef98b85f80e434c49b0c19eca16baab3d10345237642c7252b3ab5ddeb494fba
-dist/2025-05-26/clippy-beta-loongarch64-unknown-linux-gnu.tar.gz=6d2e11bbe7c0a1a9249146193e6879176460b90bb9b7909ec01065c02a20f801
-dist/2025-05-26/clippy-beta-loongarch64-unknown-linux-gnu.tar.xz=1eeb173bc287d7fba22091a7083c472aeace48679aae3450c77435376a5285b5
-dist/2025-05-26/clippy-beta-loongarch64-unknown-linux-musl.tar.gz=3d75d8f697609fd3ff857d9aba4947d5efcbe1791994a5a29204d87c625ad3b1
-dist/2025-05-26/clippy-beta-loongarch64-unknown-linux-musl.tar.xz=70ee5bd276113f98b2913c72564c0bf0d364167986d7db776669fb6e4e08e9e7
-dist/2025-05-26/clippy-beta-powerpc-unknown-linux-gnu.tar.gz=010fcc2d0e9724d6162383002d0c63039b9e24c0cb6e2d5187edbb869bc7e1b0
-dist/2025-05-26/clippy-beta-powerpc-unknown-linux-gnu.tar.xz=6b0bcca51760ec121f7ec64e2f6eaf91eeebb9da0318642a115f6852647ae806
-dist/2025-05-26/clippy-beta-powerpc64-unknown-linux-gnu.tar.gz=3b2306a5b60fd2f67eb805189457e1dc0350854eb3a47ae9dd53cc89df9f668d
-dist/2025-05-26/clippy-beta-powerpc64-unknown-linux-gnu.tar.xz=ccafe9b4403c6bcb87a244eb6afadcbab799e65dc105f60551a8a3b6153c31d9
-dist/2025-05-26/clippy-beta-powerpc64le-unknown-linux-gnu.tar.gz=d70a86b08254f64cb2c4d37e911f70aaa0c22f464e1c906d63e61a6b29d39184
-dist/2025-05-26/clippy-beta-powerpc64le-unknown-linux-gnu.tar.xz=2db59bb48172923ad3db736f51ccf1226bdb8ebc76daa29e220007897d76bf6d
-dist/2025-05-26/clippy-beta-powerpc64le-unknown-linux-musl.tar.gz=cf6915d74c6e8789380f5b986c2ed1b17e8709c2a41abd4cfe89033b45cd8642
-dist/2025-05-26/clippy-beta-powerpc64le-unknown-linux-musl.tar.xz=60c647b9fe5ab19522ef94dc5d5e6a03ce58e922ac55dd85feded92812b40879
-dist/2025-05-26/clippy-beta-riscv64gc-unknown-linux-gnu.tar.gz=36614d7f77357fbdcdaf35bebb4222e41617cb684a3daf69e2a1cbfe46ea60d1
-dist/2025-05-26/clippy-beta-riscv64gc-unknown-linux-gnu.tar.xz=0876fae91f3d54a745a73876b901d6551089264b408b7d1954475d3e6195f72b
-dist/2025-05-26/clippy-beta-s390x-unknown-linux-gnu.tar.gz=72247770c08147d59d93ece7d6fc97f46c091fc71c65d3a215f682608aecb2ba
-dist/2025-05-26/clippy-beta-s390x-unknown-linux-gnu.tar.xz=12d12c1c6a277af5c203ad0fbf6dcb4b04ea74614740734466ea7754f13696f6
-dist/2025-05-26/clippy-beta-x86_64-apple-darwin.tar.gz=a9e255811a75cba14ee0789c2263655407b8d293273252217a4fd7d0de813cec
-dist/2025-05-26/clippy-beta-x86_64-apple-darwin.tar.xz=8bac948774490e48e4193eef0415fd02ce0b7e6855d6cc59314e0f6234da927c
-dist/2025-05-26/clippy-beta-x86_64-pc-windows-gnu.tar.gz=fc5d7c3712d8be85f3992f01e2ade695e6c443983b46b4e1eaa3bbad9bc951a8
-dist/2025-05-26/clippy-beta-x86_64-pc-windows-gnu.tar.xz=0e20c9f824ac305c0fa0370376f977f5fd27aff485223ae1ce32c3de0e12b119
-dist/2025-05-26/clippy-beta-x86_64-pc-windows-msvc.tar.gz=c85932e32236b3365351b775cd382744fb47b3bb3117a65cee537ad79fc78881
-dist/2025-05-26/clippy-beta-x86_64-pc-windows-msvc.tar.xz=b4198fac7d359f3fea4240ab81b2f4f013c938e520a350ca21878c84c5ec16f5
-dist/2025-05-26/clippy-beta-x86_64-unknown-freebsd.tar.gz=e3e5d327a35c467ad44151db010a10ad61b0377d8f5c1844d79678d9388cd6e5
-dist/2025-05-26/clippy-beta-x86_64-unknown-freebsd.tar.xz=94637cf9f7715155e530fc9c295fb41555ebbac18255a8750255b13e2f691641
-dist/2025-05-26/clippy-beta-x86_64-unknown-illumos.tar.gz=8ea5ed861bbc11d47b8f6710b95b29acdeaf6d7a80562216a5e8094bfe440d90
-dist/2025-05-26/clippy-beta-x86_64-unknown-illumos.tar.xz=b14302a36f11794b181125c22af92eb5777f7f5f898c73194e82361ddbfacacb
-dist/2025-05-26/clippy-beta-x86_64-unknown-linux-gnu.tar.gz=611504bffef243a1ac873c7d18c42731d6e24caa6d4b370be1ab1858603bb201
-dist/2025-05-26/clippy-beta-x86_64-unknown-linux-gnu.tar.xz=52f4b0a2bd2a5d0bdbccfc1a8ad9cf24572c103c8713911e121fde4935c22854
-dist/2025-05-26/clippy-beta-x86_64-unknown-linux-musl.tar.gz=7af7df177e64881dd68fa1e8207fb4a0bd7ba4e642468024fa34fc3d5c839df8
-dist/2025-05-26/clippy-beta-x86_64-unknown-linux-musl.tar.xz=f2f9575cbd3e3f067aeda5f9b7ab424e0dc119448d12872692cb7c6669f61ae0
-dist/2025-05-26/clippy-beta-x86_64-unknown-netbsd.tar.gz=5e1dc30da47902c52ab1fbfa2216a6952385184b44854c47b8eb988bdd1b040d
-dist/2025-05-26/clippy-beta-x86_64-unknown-netbsd.tar.xz=23f21905caa5824a463fac01e18e0055009cecdfd406da76b838105eb78127e7
-dist/2025-05-27/rustfmt-nightly-aarch64-apple-darwin.tar.gz=5a3b21df1d525a049b9bd1fca0e32eb5aad1a82a2800e094af80f121e90878c0
-dist/2025-05-27/rustfmt-nightly-aarch64-apple-darwin.tar.xz=3f7edd6997839f12d70246edb672a13d808bd871bfaa4bda66bb4db4fb1158fc
-dist/2025-05-27/rustfmt-nightly-aarch64-pc-windows-msvc.tar.gz=99ecb24920480c06482d8b10f6dbc23247c66033991ad807f8228dff35626fac
-dist/2025-05-27/rustfmt-nightly-aarch64-pc-windows-msvc.tar.xz=fc716e83a694792c0b2355457cbe6f0a820ed85be725d6b3e742b257cc9cd245
-dist/2025-05-27/rustfmt-nightly-aarch64-unknown-linux-gnu.tar.gz=cc6bbe1ea77372ea927329aeb6e4d7602829b307a407466d9c6a3417c62b6ce0
-dist/2025-05-27/rustfmt-nightly-aarch64-unknown-linux-gnu.tar.xz=2018c51986de7be37f11ae05aa101b50f2d8f0e06f7ed8e3c6e4891b580a122f
-dist/2025-05-27/rustfmt-nightly-aarch64-unknown-linux-musl.tar.gz=11cbb36b62563209127c1c8b1f4c32ec1ebc6ca04f18a8e067333402120da00b
-dist/2025-05-27/rustfmt-nightly-aarch64-unknown-linux-musl.tar.xz=5bcdcf88ece597956dea20d63cf568a92cb841df529fb0c0b277f469c58bc742
-dist/2025-05-27/rustfmt-nightly-arm-unknown-linux-gnueabi.tar.gz=507753792ca1668ffb7ea4e4467f2ecbfee8753e269a29050cd4e22b1ff20b33
-dist/2025-05-27/rustfmt-nightly-arm-unknown-linux-gnueabi.tar.xz=3e2b0b89c373dc935dc6c0a882b7723d252792d831a6a81889f77df0964df819
-dist/2025-05-27/rustfmt-nightly-arm-unknown-linux-gnueabihf.tar.gz=40c728833bee43b25bf81eea8e9e6e3330d455729ec34c6b1c45d6c8b04f3ff4
-dist/2025-05-27/rustfmt-nightly-arm-unknown-linux-gnueabihf.tar.xz=c8dc03a4b1c1ed9f853f4c548d94d44b87fcdf52095e7b84d9ddd3be7be7a11a
-dist/2025-05-27/rustfmt-nightly-armv7-unknown-linux-gnueabihf.tar.gz=fefed8cce0ab0b90b7b58e1a417e031b0969148a427dbbf2f29a9170fb386646
-dist/2025-05-27/rustfmt-nightly-armv7-unknown-linux-gnueabihf.tar.xz=77b787221ec106ceb20e58e684f348bc5542bac506fc4a3084d4d2931164878a
-dist/2025-05-27/rustfmt-nightly-i686-pc-windows-gnu.tar.gz=3cd4ed08fe7dd4d921d60f15e7593d71db450c9e2e6d5a1f4fca3f409dabe8fe
-dist/2025-05-27/rustfmt-nightly-i686-pc-windows-gnu.tar.xz=df210bf84e04e83ff77cad6acd156393d687e89fd74fff4c288762edfa0853de
-dist/2025-05-27/rustfmt-nightly-i686-pc-windows-msvc.tar.gz=1f3b532d841f5c78fbdb5d0a1c513ab45bd942de27ce650dfca459e33db9b27c
-dist/2025-05-27/rustfmt-nightly-i686-pc-windows-msvc.tar.xz=e9e52af5658861dfa2d1caed954b078a2630b42de08205727b368098348fa0dd
-dist/2025-05-27/rustfmt-nightly-i686-unknown-linux-gnu.tar.gz=c81689ec620c0fbdd4a4daed7a3de6ecbc0b13b98fa06dd1f2d1beb5cc98d5c8
-dist/2025-05-27/rustfmt-nightly-i686-unknown-linux-gnu.tar.xz=a9cb725755e64fff80dfcd2fddf8cb3a62508dee90c6b6aa6786d8e03a2dd232
-dist/2025-05-27/rustfmt-nightly-loongarch64-unknown-linux-gnu.tar.gz=96fae51d3f3443e28f2789a7117510840f24a3270f8a77cf3103c6e7100079b7
-dist/2025-05-27/rustfmt-nightly-loongarch64-unknown-linux-gnu.tar.xz=78a3298fa4f70001326aec0d080873fd8c64b18beca91c8eb93f2d2786b27b5e
-dist/2025-05-27/rustfmt-nightly-loongarch64-unknown-linux-musl.tar.gz=a87af95c57af0edacceb7072fb81291f9e935d548fa5c68afa58d2d5f53d4497
-dist/2025-05-27/rustfmt-nightly-loongarch64-unknown-linux-musl.tar.xz=924b5fbbec1a00b714787b7489ab592a6c0ec9c72d57f06f3ac4ff9960a610a5
-dist/2025-05-27/rustfmt-nightly-powerpc-unknown-linux-gnu.tar.gz=c11fc36cf2ae84737ca5d1fc441acbf755053eba26fd962f12a9b1a76a0a52ec
-dist/2025-05-27/rustfmt-nightly-powerpc-unknown-linux-gnu.tar.xz=6f2fa0295e91031a1f9f1e6c344435021a6b18212c2e21c50a46baafd6694071
-dist/2025-05-27/rustfmt-nightly-powerpc64-unknown-linux-gnu.tar.gz=40e7a2d6986084a630161809132213cf3a2858f04c60902fa09eedbf9caa8bb0
-dist/2025-05-27/rustfmt-nightly-powerpc64-unknown-linux-gnu.tar.xz=112d9a416fb43ed6dcc8b066133ded75354977ea9e2d14e6d8310b35bfdf338e
-dist/2025-05-27/rustfmt-nightly-powerpc64le-unknown-linux-gnu.tar.gz=6c30107bfcc9c5b72be06570efa37d356ba9ee9a14385fb84e392095533a8352
-dist/2025-05-27/rustfmt-nightly-powerpc64le-unknown-linux-gnu.tar.xz=6e80b773b5e2353bad7a5e01e3b330dd569133aae505bceaf605864fda12d55c
-dist/2025-05-27/rustfmt-nightly-powerpc64le-unknown-linux-musl.tar.gz=b250ceb2e2360bf0366a91f6533aff91e17d7c9f3ca48fe448ca18008da3aedb
-dist/2025-05-27/rustfmt-nightly-powerpc64le-unknown-linux-musl.tar.xz=62cebf6541b0d3b2f247f3e43492160750eabb227be9ca98b34714538e176cbc
-dist/2025-05-27/rustfmt-nightly-riscv64gc-unknown-linux-gnu.tar.gz=ac31569b7367b4a44fd64c6cc778849196a7d02ca4b413c08568a4318100246d
-dist/2025-05-27/rustfmt-nightly-riscv64gc-unknown-linux-gnu.tar.xz=0ef0aa7518da52dcea41e979aba1e4e93268bfc43140a83e00dff566ea2ee0e1
-dist/2025-05-27/rustfmt-nightly-s390x-unknown-linux-gnu.tar.gz=811c1024ca9b92a9512105c6589f557ddc409df6ce7dda3f1ad537f0b5e5520c
-dist/2025-05-27/rustfmt-nightly-s390x-unknown-linux-gnu.tar.xz=f0deb894b1f9921ab401c8e4fe3a1eb2cef4c2b51352f54c87fad0dc8689d927
-dist/2025-05-27/rustfmt-nightly-x86_64-apple-darwin.tar.gz=18b3231a7df8e5ab2fa961de699880878aa234f56cff9d7a1126c17b8f249846
-dist/2025-05-27/rustfmt-nightly-x86_64-apple-darwin.tar.xz=74a69eb74ebd5ae965f2f7fd251743ad81efc2e6e5684886d47427414d39b2e7
-dist/2025-05-27/rustfmt-nightly-x86_64-pc-windows-gnu.tar.gz=815169fe5a0bced72ae2a7a187597d56bfc402cd5c318f9258d5576c178a19e2
-dist/2025-05-27/rustfmt-nightly-x86_64-pc-windows-gnu.tar.xz=0849e77b370332530f51bc486cb3b67a26a13369267e1978aeb895e66d8c62a1
-dist/2025-05-27/rustfmt-nightly-x86_64-pc-windows-msvc.tar.gz=b003015eb6622e2ee16a4471e9d1b6908556b4f544ee8574d793e94e866258b9
-dist/2025-05-27/rustfmt-nightly-x86_64-pc-windows-msvc.tar.xz=2fb0722be5ecec129175e74928464f57b4595208e87b5295186f163389aee8c3
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-freebsd.tar.gz=d780af4579941b6a1d1825a3d512cf541486cd365699243634f134af1af80661
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-freebsd.tar.xz=7109ac35f05e8d0f013eaa530c6271cc943ae8076cb7056383b93422329dbc0a
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-illumos.tar.gz=9e3d61435933b25f5e489cfd97cc3d9737fc99403e72fd2b2c302a2850d6e7ac
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-illumos.tar.xz=8a8dfcea26c974826693c776a64e89b3ef9104f61772e84918c780c92c5a13a5
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-linux-gnu.tar.gz=c4b37e59ef93c647a1533bb7427cfc97a3766a40dd551ae8eb3668a44702e1df
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-linux-gnu.tar.xz=5ad72eb343c31b8da7edd7c1fe56e9920a4f7662190fab6e20dfb258e3c38c60
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-linux-musl.tar.gz=f99a565ea5a7d2238f7cd79364c39fdd2b83559f4cc668cee10c0e3564a5420c
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-linux-musl.tar.xz=a470498028404e7c64cb5fb77f88dfac560772320fd6aa620eb25c37bf879c9a
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-netbsd.tar.gz=e9c10350ba54a7d8a190a32aa913cc581e918cfdda14c12553e0278db8e78239
-dist/2025-05-27/rustfmt-nightly-x86_64-unknown-netbsd.tar.xz=63e5effaf0b5bfaf8fc9350d1bc0eb30cf0e8076da85c805fbb4988fff1b8f3c
-dist/2025-05-27/rustc-nightly-aarch64-apple-darwin.tar.gz=16ca9b794c74a72cf9ca68fff71b9f56db1e832feb919c3ff95b65133718719d
-dist/2025-05-27/rustc-nightly-aarch64-apple-darwin.tar.xz=52c42f611e409b50e857c3ce2857afd5f45f19d30f0c8ca1d0a7e1add6fadcbe
-dist/2025-05-27/rustc-nightly-aarch64-pc-windows-msvc.tar.gz=687337020aca4e3e97a5313aafecbbce548cd54fe599c6d62b07f530c39ea755
-dist/2025-05-27/rustc-nightly-aarch64-pc-windows-msvc.tar.xz=2d558352e8f441d1eba929dd5598db5f717a5dec3f813dcc34c4c43da169aea2
-dist/2025-05-27/rustc-nightly-aarch64-unknown-linux-gnu.tar.gz=1eab60c4ce6e7e8e0e245a5928f26ab0b76dc9a4545eb89e481eae0673bc9c84
-dist/2025-05-27/rustc-nightly-aarch64-unknown-linux-gnu.tar.xz=be47b529deb209ae5120a359047b6353114e7a7cceeee5b038a2fa1464fc9c14
-dist/2025-05-27/rustc-nightly-aarch64-unknown-linux-musl.tar.gz=a9985e558669e2f8f6142c3ae25010b834a4d9069344abeb69e4d4cf5c244777
-dist/2025-05-27/rustc-nightly-aarch64-unknown-linux-musl.tar.xz=ce8e9f473ef4247d011055ac6787a9b92b2fb0e932a8b0f08278c8db2529655e
-dist/2025-05-27/rustc-nightly-arm-unknown-linux-gnueabi.tar.gz=709f050c2c73b2788d0c5bbe388296c94db9bc014996015e41688d119b42b0cd
-dist/2025-05-27/rustc-nightly-arm-unknown-linux-gnueabi.tar.xz=010b92069ba7a9de01966e54f09bda22b9ff436929a2e17ea1e9f5b379114780
-dist/2025-05-27/rustc-nightly-arm-unknown-linux-gnueabihf.tar.gz=0685aa646c5bcf6c2b6a70e6384023bd79571f1f87bf85c74c452ea7adbcab32
-dist/2025-05-27/rustc-nightly-arm-unknown-linux-gnueabihf.tar.xz=f3cb40e7a13f75e40c36dea7b916ed245976e9d82a37299c94b6d6245e697f66
-dist/2025-05-27/rustc-nightly-armv7-unknown-linux-gnueabihf.tar.gz=a4c876c4d4c8829ec4755f71ac8efa69baa2875782a371a9aa6ae84d13270ae1
-dist/2025-05-27/rustc-nightly-armv7-unknown-linux-gnueabihf.tar.xz=5e64186cdb993c1ff56fbe10ee1fed73fe71384db6bfdfc57e15cc93924df816
-dist/2025-05-27/rustc-nightly-i686-pc-windows-gnu.tar.gz=92b706e06dc7b656038437b0c281436a28d8508ef13081b61438133d2fe952ef
-dist/2025-05-27/rustc-nightly-i686-pc-windows-gnu.tar.xz=fb8d2d68ac3600befba96f67acbeefec581e2b1eada7c33887fb792101eb2dda
-dist/2025-05-27/rustc-nightly-i686-pc-windows-msvc.tar.gz=8322ce000c9660d86b5a376da11b7da482b78e7e47a56f1fa2fe151b597d8024
-dist/2025-05-27/rustc-nightly-i686-pc-windows-msvc.tar.xz=4612835d7ba71cfe226d04d55c06222bd8b2dd56a8dcba07133dd02cac69fb16
-dist/2025-05-27/rustc-nightly-i686-unknown-linux-gnu.tar.gz=8663c35fe6371fe7ae91c391933a7165cefd5f9f26fe75bcedf6f9977cb4ad0f
-dist/2025-05-27/rustc-nightly-i686-unknown-linux-gnu.tar.xz=17c937f85f59fa7a876540ea60ecd5729c85409a64655041707865fd5f7cc849
-dist/2025-05-27/rustc-nightly-loongarch64-unknown-linux-gnu.tar.gz=639e0b5ed5b0afa3d8304189ed674e9d39b742dc61cc267043628b4c458ba157
-dist/2025-05-27/rustc-nightly-loongarch64-unknown-linux-gnu.tar.xz=faa19a69d37059f67afe8f031b8f743823422dc23939513877125cc2c4a9db2c
-dist/2025-05-27/rustc-nightly-loongarch64-unknown-linux-musl.tar.gz=3dffa8b59899fd9f4d0d7a999212a1737745883f6b6d1a15cee7ff75d7dda417
-dist/2025-05-27/rustc-nightly-loongarch64-unknown-linux-musl.tar.xz=1d5368b7d616d42b81b82d0f46e5ddfc2b7033bc13e06b06520dca4489631388
-dist/2025-05-27/rustc-nightly-powerpc-unknown-linux-gnu.tar.gz=66b1ef67218c651844ffa481e8a9dbbb81a2ef4b40e673bcde2a0c9612eaac95
-dist/2025-05-27/rustc-nightly-powerpc-unknown-linux-gnu.tar.xz=48306f0162b762424e5e7da9e8920c1be982e6e0989536f2d89e922cf7fe7d64
-dist/2025-05-27/rustc-nightly-powerpc64-unknown-linux-gnu.tar.gz=7d7557024f84240fa7cb0d42bbe223c49615eeadcff6c757a755a2e500f8f623
-dist/2025-05-27/rustc-nightly-powerpc64-unknown-linux-gnu.tar.xz=62ebda3f8a44be8c1498defb5059b93add29e95f867e2e7cfd648185fc21b6e5
-dist/2025-05-27/rustc-nightly-powerpc64le-unknown-linux-gnu.tar.gz=5f3579be74da3329e3af32b034fcae002c781f7933b522638cb84876e00efa56
-dist/2025-05-27/rustc-nightly-powerpc64le-unknown-linux-gnu.tar.xz=6191553b2216ef7e9f43763736708a50c9ba972ae51997676244c52795ac5486
-dist/2025-05-27/rustc-nightly-powerpc64le-unknown-linux-musl.tar.gz=70fe263d30c9ed08e00d4d10f9bcbdfda571e5468dcda304a137f7d980e027ac
-dist/2025-05-27/rustc-nightly-powerpc64le-unknown-linux-musl.tar.xz=973c090d6f72c9962fec065d99c02a79f857243306cc6b34a2f77f9c8f7f567c
-dist/2025-05-27/rustc-nightly-riscv64gc-unknown-linux-gnu.tar.gz=bcf3f416152378bac430f88da0fc79e34a7fcbb65e7e06ac890b8de9f2793e98
-dist/2025-05-27/rustc-nightly-riscv64gc-unknown-linux-gnu.tar.xz=cf0cce7680f97a7c248869e44c5571dcc46c5b85e8f00c567efbf9ca3c4af80e
-dist/2025-05-27/rustc-nightly-s390x-unknown-linux-gnu.tar.gz=e6e6094edf1a44f7f08e9d2cb814d3023f0261d5595be89d968b75b0ba0e368c
-dist/2025-05-27/rustc-nightly-s390x-unknown-linux-gnu.tar.xz=0f4b4c5d07b8cc6815094f49ad53e8520245da428afd80e0497676a0863764cf
-dist/2025-05-27/rustc-nightly-x86_64-apple-darwin.tar.gz=c9c5ff52a78d80c74ce0c40c0a2947dedfe99b195f06885d0e405c7f5b6bde28
-dist/2025-05-27/rustc-nightly-x86_64-apple-darwin.tar.xz=1cc3250c923e8647d6668c6e8ee14f2c92c50a73b080a2991768e3a88a9a99ca
-dist/2025-05-27/rustc-nightly-x86_64-pc-windows-gnu.tar.gz=04d2f910571ce2e2e32ab655589989538516cfc023cb6401c605973465054927
-dist/2025-05-27/rustc-nightly-x86_64-pc-windows-gnu.tar.xz=a420f9a4cc7fd01da0b86e56ed4d72f45cfd10c725f381d047dd701bd4e84178
-dist/2025-05-27/rustc-nightly-x86_64-pc-windows-msvc.tar.gz=ea454055258e3ccb6710ba86fc58e1d629c807aa52353d48d754eafe6e4f3522
-dist/2025-05-27/rustc-nightly-x86_64-pc-windows-msvc.tar.xz=9570ad0c65bc3226e3ec05185b01dbf5a1d9822de9aeabedcb4921cc8fbc2639
-dist/2025-05-27/rustc-nightly-x86_64-unknown-freebsd.tar.gz=08f400e47513fe7b8a3d3f5fb86510e28f87d5bfbd661fa8b106b16c0e22b444
-dist/2025-05-27/rustc-nightly-x86_64-unknown-freebsd.tar.xz=5c6467a38bff56ca4fa1722b092a157d0e258eb037bd5f784fae0827af842088
-dist/2025-05-27/rustc-nightly-x86_64-unknown-illumos.tar.gz=f007908e9cbc7defab2719a4f734f6f327952d59d6939b0e85ccb36dca670e0c
-dist/2025-05-27/rustc-nightly-x86_64-unknown-illumos.tar.xz=620be77081b1564ff626b1926d8242d8fc2e6f2c0308002f01cc214f8843701b
-dist/2025-05-27/rustc-nightly-x86_64-unknown-linux-gnu.tar.gz=8749217fd22d81ee2f380b1af63116e4c540fd11f617752e552f66568d50868c
-dist/2025-05-27/rustc-nightly-x86_64-unknown-linux-gnu.tar.xz=545ff3e0ac1c7c303b47bc062d029033a3d8de77c6fb54bad39a6a34b099c711
-dist/2025-05-27/rustc-nightly-x86_64-unknown-linux-musl.tar.gz=d146af52aa7fad3b198b9dd5242793bfc2dc8aad81642bf34702e409d5ae7f3b
-dist/2025-05-27/rustc-nightly-x86_64-unknown-linux-musl.tar.xz=d72ed1096917a5789f26564ddc920c3fdcd29056cf97452371e5141bcc2c8a8e
-dist/2025-05-27/rustc-nightly-x86_64-unknown-netbsd.tar.gz=94b608796d12feff92c54f942318e711879d86b1a3114a710b8366b7415ae025
-dist/2025-05-27/rustc-nightly-x86_64-unknown-netbsd.tar.xz=7d870360a35a34dffede096d62734d97a7bf60d0661e638f73d913cb93bd49ec
+dist/2025-06-24/rustc-beta-aarch64-apple-darwin.tar.gz=d52ba1003d317f779490731ac66bcf4ebeda0e56648ac35373c6f7385515c06d
+dist/2025-06-24/rustc-beta-aarch64-apple-darwin.tar.xz=1d4ab402eded5cfe91040f3af5128448cc4b57ceb53b82571bde8a86f42681df
+dist/2025-06-24/rustc-beta-aarch64-pc-windows-msvc.tar.gz=aa82360f0428aa3c918c9fb1b0f41752655aae5249f5795d34b1a4737362cf8d
+dist/2025-06-24/rustc-beta-aarch64-pc-windows-msvc.tar.xz=969a5aa9d69a2e64c918d1757489f2532544754563aae73aea9bde7d85d22d2f
+dist/2025-06-24/rustc-beta-aarch64-unknown-linux-gnu.tar.gz=bac05a8267c6dd563ae0869cdfaac9fa3a07e9d64c5c332bc4028f7f3e8ba668
+dist/2025-06-24/rustc-beta-aarch64-unknown-linux-gnu.tar.xz=3d37128f78af2b6fffb661dc05c2f7ace3a8307b3d60176fcc2b70bd4d802b90
+dist/2025-06-24/rustc-beta-aarch64-unknown-linux-musl.tar.gz=268f550fb51c63f0e8ad8c8a955633c79dde3011c26c1f3b555f2575a8366f88
+dist/2025-06-24/rustc-beta-aarch64-unknown-linux-musl.tar.xz=b706d4cdb5b4e86602994c74476b4be7ff94749c3104553ba6d73356cb914582
+dist/2025-06-24/rustc-beta-arm-unknown-linux-gnueabi.tar.gz=20b0e77b39b9ef5c80f19a3b6daec5e479cf3e0af8b623cee81d38f0a5318cfc
+dist/2025-06-24/rustc-beta-arm-unknown-linux-gnueabi.tar.xz=0add4728a9a993c6b33d8cda11c27520e013f0721532686b5919d3958d2333f0
+dist/2025-06-24/rustc-beta-arm-unknown-linux-gnueabihf.tar.gz=4bdd3e99737137d3595fa9e27e590d8589d5f380e9e634fdd65e8c526f872fed
+dist/2025-06-24/rustc-beta-arm-unknown-linux-gnueabihf.tar.xz=662c73cf5f9e0796be7d8ad19a064b5bbbace7b8d1e55644acc19880fa76526c
+dist/2025-06-24/rustc-beta-armv7-unknown-linux-gnueabihf.tar.gz=c31b823567177bba812b1074af46282083214314ba3e0c4c2386748526fb64d0
+dist/2025-06-24/rustc-beta-armv7-unknown-linux-gnueabihf.tar.xz=67eed549762b32d50117e200b5157a60388e67d246b60ddf8fc4e41defa3ed0e
+dist/2025-06-24/rustc-beta-i686-pc-windows-gnu.tar.gz=de5c004abce01c43ac7caaefa9ed10006e41b83d085bcbe6fceb4040138787ca
+dist/2025-06-24/rustc-beta-i686-pc-windows-gnu.tar.xz=f5b715035c76cae7099c74e0f00e924c2cf965aa7152518c2e6313ef04d81d8c
+dist/2025-06-24/rustc-beta-i686-pc-windows-msvc.tar.gz=48a97523dbc061b2a3a575a34b2ba87c0dfca2e56fee67260001ba51c3b37ac1
+dist/2025-06-24/rustc-beta-i686-pc-windows-msvc.tar.xz=5c2254445c7d5cdf3e64c86b29046699fe7f8a6828dcd3f2931aa26d026d71af
+dist/2025-06-24/rustc-beta-i686-unknown-linux-gnu.tar.gz=4515aa57b3f9191fb14d228bedee72044d2fda3e3166780e622d857460c77c57
+dist/2025-06-24/rustc-beta-i686-unknown-linux-gnu.tar.xz=8791d2c9321b36d64280902e0ec04b85728715bdd072f859fbe3d533209504de
+dist/2025-06-24/rustc-beta-loongarch64-unknown-linux-gnu.tar.gz=08b9941535edae23971a42803bc398bd87c353dda837ecc68e534be6604d7e35
+dist/2025-06-24/rustc-beta-loongarch64-unknown-linux-gnu.tar.xz=a2a109408ba5db4540ad7bbd1e67a9623aae96203c0238aca5fb3c3741ead97f
+dist/2025-06-24/rustc-beta-loongarch64-unknown-linux-musl.tar.gz=41709a32ceb106a618aedcebb1470e6bb3734362790d1aad7d0f59e25c9f76ca
+dist/2025-06-24/rustc-beta-loongarch64-unknown-linux-musl.tar.xz=67294e9465728d7a2e1f9553927067fbba176c1d806a59472b84a2dc18e46032
+dist/2025-06-24/rustc-beta-powerpc-unknown-linux-gnu.tar.gz=a18de5c31855d7a2f73a242217c628a49fe9a64b1374d6720e37e3eb0a584fae
+dist/2025-06-24/rustc-beta-powerpc-unknown-linux-gnu.tar.xz=7785929842939af15a8404f666c95e5786ca0941f1c15dc084f26a5124411e2c
+dist/2025-06-24/rustc-beta-powerpc64-unknown-linux-gnu.tar.gz=35e4e2c48895480d5c012d2741a1b3387c1ffb4c4d2440649c0eda182f27f6c1
+dist/2025-06-24/rustc-beta-powerpc64-unknown-linux-gnu.tar.xz=3cd480374907eb3816c8db73973abc676c96bc9598943dc89056eb5542d6b6b8
+dist/2025-06-24/rustc-beta-powerpc64le-unknown-linux-gnu.tar.gz=3901ff91a71c32808f23d715b9e04ce65dfac20746cad1b00c1a964220284cb5
+dist/2025-06-24/rustc-beta-powerpc64le-unknown-linux-gnu.tar.xz=c670f5201c14464d9e13da1922609369e784a1e482162cf3e9ed281fce926b01
+dist/2025-06-24/rustc-beta-powerpc64le-unknown-linux-musl.tar.gz=72f5c00badcc4a87e237b831262d12e94edb960d65f411557a54dc9bf587464b
+dist/2025-06-24/rustc-beta-powerpc64le-unknown-linux-musl.tar.xz=337f222313427704cfa4b9f68c89f82e3855f2b3d1cec1c151778fd631674452
+dist/2025-06-24/rustc-beta-riscv64gc-unknown-linux-gnu.tar.gz=b2a49ff470ce80e887f2eb3b69b39cd65b64a2a25b5f09df91a9e58762a6a159
+dist/2025-06-24/rustc-beta-riscv64gc-unknown-linux-gnu.tar.xz=1c2b2090ab6ec51df85e6495389adceca4fd414a709d2219fd7b39d1c47c7a49
+dist/2025-06-24/rustc-beta-s390x-unknown-linux-gnu.tar.gz=26ad57058ddb3ad1795300bff0bbbfc1bb3a0437638112655dbec279db78bb11
+dist/2025-06-24/rustc-beta-s390x-unknown-linux-gnu.tar.xz=742c09735a0b50acea601dfd2ae41e931cbb44d7700d6cba18df9e0ccb45bad8
+dist/2025-06-24/rustc-beta-sparcv9-sun-solaris.tar.gz=cc6c4e7bada6d864177a163f1d6b1f75e1e388abe1fcd4de87c2aeb8e609587a
+dist/2025-06-24/rustc-beta-sparcv9-sun-solaris.tar.xz=1fcf41f42ef399bb8c450f6a8c9cef8af960d6fa82495c53273419bd3cbb79a0
+dist/2025-06-24/rustc-beta-x86_64-apple-darwin.tar.gz=b1dd64d9ee00d14a4cf41556b70330606c793a81725494e4f14215092ded4d73
+dist/2025-06-24/rustc-beta-x86_64-apple-darwin.tar.xz=75de284a6a29a453e1e453d372affb5717434584445019582a50d169b7770d65
+dist/2025-06-24/rustc-beta-x86_64-pc-solaris.tar.gz=ff4832c37c0bfb55e54bd02f40251a4d43ab68f41d22ee54543fe37e33561925
+dist/2025-06-24/rustc-beta-x86_64-pc-solaris.tar.xz=e297337e331fab37350f0826328ef1086e210068cc764567905a4caae3f18d0d
+dist/2025-06-24/rustc-beta-x86_64-pc-windows-gnu.tar.gz=fd4dc0fb13dd1cc8ad58f143ff83a8a52fe31e277c6fd19dcf4d51dd5d004135
+dist/2025-06-24/rustc-beta-x86_64-pc-windows-gnu.tar.xz=347de9b9f7ce028fe479803dd846d13be8db6d0baf81a0a4eeb3511cfebe4821
+dist/2025-06-24/rustc-beta-x86_64-pc-windows-msvc.tar.gz=c84ee0f00b5f13fee3ce8c45301577a42866493aefa5460f3385d03398204acd
+dist/2025-06-24/rustc-beta-x86_64-pc-windows-msvc.tar.xz=4b6a27561bc94afe072b66c5bed3f30da712bdc812ff1609feb669556dc878ca
+dist/2025-06-24/rustc-beta-x86_64-unknown-freebsd.tar.gz=493c5c391e7829c8925bc447457c56617076ed32d3ee1465639fa02cda5717d4
+dist/2025-06-24/rustc-beta-x86_64-unknown-freebsd.tar.xz=71e9e3a1d1f5e8dc98403c2a6695c969908ba0cde594c4e20249fe81b67d62d1
+dist/2025-06-24/rustc-beta-x86_64-unknown-illumos.tar.gz=40e58bcfc116546268f5007e4092eeb43c3a582e7090f0bff29fb0ad24a0bc72
+dist/2025-06-24/rustc-beta-x86_64-unknown-illumos.tar.xz=e313e1b0136be269ff68b4d2a71d0414357df66e1ed192e9a60e908c6c64c37f
+dist/2025-06-24/rustc-beta-x86_64-unknown-linux-gnu.tar.gz=0725845044e9ecb37ff6b4c1a030a6c8bf287706601b29ba7fb5284f67d29ba4
+dist/2025-06-24/rustc-beta-x86_64-unknown-linux-gnu.tar.xz=4fdc2e7a65b3924d1577229fe02975a4618481aac35053426abd2b9ede18afde
+dist/2025-06-24/rustc-beta-x86_64-unknown-linux-musl.tar.gz=26426288117d71c8212aa30fa5b874e3aca9e4e706852f18d22da05bbd638dab
+dist/2025-06-24/rustc-beta-x86_64-unknown-linux-musl.tar.xz=bca55f330ec76ebdd6f6dc8764cfb31aa9158cb96758779f8eefc031d393e263
+dist/2025-06-24/rustc-beta-x86_64-unknown-netbsd.tar.gz=007e38bc7d09c4ca3a7ea389ed112a2de0e09f6688e5e1f161a4d11e41d43ab0
+dist/2025-06-24/rustc-beta-x86_64-unknown-netbsd.tar.xz=08a5d9cac358f115af3d0985439e2ff0c79b70b592f99fb3d31b65cb7f56d958
+dist/2025-06-24/rust-std-beta-aarch64-apple-darwin.tar.gz=2c38b17116d9a2d2020e7e84bbaad3b614e8a0c27fe26987416bd183138596ba
+dist/2025-06-24/rust-std-beta-aarch64-apple-darwin.tar.xz=c51b0e3932226017dfb70e8fbd879e9eefd65d5f17ad07db606ebe2ba1500dd0
+dist/2025-06-24/rust-std-beta-aarch64-apple-ios.tar.gz=f71b8bc726eb5f60bb1603607609a1c04569581875d697fb1026b8454ff0b403
+dist/2025-06-24/rust-std-beta-aarch64-apple-ios.tar.xz=ea0634039755708291275ee3af545982f3c29381b1e9675cb087ede59e03b461
+dist/2025-06-24/rust-std-beta-aarch64-apple-ios-macabi.tar.gz=c457134ea13cdbaf1af7f11148074ac01e6e19415b591a8ee6958ea5006f4754
+dist/2025-06-24/rust-std-beta-aarch64-apple-ios-macabi.tar.xz=cff6edde276467a7e3674506c9b668abf0004a12464fb22fd35f56537b0dc4b3
+dist/2025-06-24/rust-std-beta-aarch64-apple-ios-sim.tar.gz=c70fcec2f7610058c5cde51847879415376fedfae10ec49a7b198e5c5582aac5
+dist/2025-06-24/rust-std-beta-aarch64-apple-ios-sim.tar.xz=6e763366bfb635915ae7d505c35df55ebf8a1d5373bd5403584d7dd7ac682f21
+dist/2025-06-24/rust-std-beta-aarch64-linux-android.tar.gz=c4d13dcea814eb20b4c7045e6d881df185f6ee1539b42428348068d752718498
+dist/2025-06-24/rust-std-beta-aarch64-linux-android.tar.xz=67d3cc8f90712e50909aca5e734211baeab3ccd47a3cd00dea07839f16770a19
+dist/2025-06-24/rust-std-beta-aarch64-pc-windows-gnullvm.tar.gz=d882aeee9217327a650ad37b902380c87dd3d02d0d49015cb3052537da42b380
+dist/2025-06-24/rust-std-beta-aarch64-pc-windows-gnullvm.tar.xz=4aaee0fdc8aad773eb8576c869b111dbfa4e3882cf5cf50da174e63528db01c6
+dist/2025-06-24/rust-std-beta-aarch64-pc-windows-msvc.tar.gz=56b70c5445d95471651093ebe31a16fef54ec91b2acef533f3c1f06c2f18f924
+dist/2025-06-24/rust-std-beta-aarch64-pc-windows-msvc.tar.xz=d60d4aea6fc5345bd0478c92a81bca7ec3589775ec67733aca845d78b9364e8c
+dist/2025-06-24/rust-std-beta-aarch64-unknown-fuchsia.tar.gz=b6946f0c1d01d370d217e3512505211ca4aff4f07c1f7c55d99065b70c9d52fb
+dist/2025-06-24/rust-std-beta-aarch64-unknown-fuchsia.tar.xz=e3479f792c61b425459c691169d8fe55a149dd6c0440aea4a0d9be41d6806b00
+dist/2025-06-24/rust-std-beta-aarch64-unknown-linux-gnu.tar.gz=47c5e35cf704a1496a5d01143d2f418880a4540bbd6b4fd41e4f9988a71ded83
+dist/2025-06-24/rust-std-beta-aarch64-unknown-linux-gnu.tar.xz=010bae09b5a25a7b1b0c1a10dc67f5d7db89212fa9ef7149cea4e4f586d5f252
+dist/2025-06-24/rust-std-beta-aarch64-unknown-linux-musl.tar.gz=2dba8ca097a3afbc9d51b75c8338f3536b079fa751dbd4a877d89a36cb0e616b
+dist/2025-06-24/rust-std-beta-aarch64-unknown-linux-musl.tar.xz=9ae1856c909ba57b3c5638e8546fec2e2741a54f5f5b14c73c1c031f33096815
+dist/2025-06-24/rust-std-beta-aarch64-unknown-linux-ohos.tar.gz=f0f25e623f96ea98d004039add0232abd5ba7216ba347db3a827d4ec323d3ab1
+dist/2025-06-24/rust-std-beta-aarch64-unknown-linux-ohos.tar.xz=fcfec16c209afc3362f710d0207e5ff8a596ba7ad7123335ad3670294d0b4e6f
+dist/2025-06-24/rust-std-beta-aarch64-unknown-none.tar.gz=00d63ef3e735db06d0989601a78a21dcbfa4c62bc1ab063a53c48f94ec24b92d
+dist/2025-06-24/rust-std-beta-aarch64-unknown-none.tar.xz=50934b2bec9bfff0c58e9a70adeafa7875236814e8338cc01fab3373822e8d5a
+dist/2025-06-24/rust-std-beta-aarch64-unknown-none-softfloat.tar.gz=211e95246719c6242dc243559175bc0d8154c4878b8ca72e4acb6f29c60aca8c
+dist/2025-06-24/rust-std-beta-aarch64-unknown-none-softfloat.tar.xz=ba53e4fae39fa980c6eeb1a2d2299eb53ded22dcdfc0390938bdd7b9563ed9eb
+dist/2025-06-24/rust-std-beta-aarch64-unknown-uefi.tar.gz=93e56e090c416f038faca4837c4fb72894f3d6d1a3ba8b9fe27b2ca032deedb6
+dist/2025-06-24/rust-std-beta-aarch64-unknown-uefi.tar.xz=f0f0aebb6b764b648736b9f4a1a335463c4de7076a2be3bfb7bbcd04e3aaccd2
+dist/2025-06-24/rust-std-beta-arm-linux-androideabi.tar.gz=3ade9cb0c40515ed3b1601ec66bab1cc81f46e9814790a3589259750be8c9ec8
+dist/2025-06-24/rust-std-beta-arm-linux-androideabi.tar.xz=cf6997822547dc1b776443cee80acff76ec66747e6cdb16784d81877922a9d57
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-gnueabi.tar.gz=09525696ac31ab025a27cd61daa457f6687a526e4ecb8fecb87e0152fff65bcf
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-gnueabi.tar.xz=d5cb742fec22224144fde555dcda683a3efa262d1c7e7986e038fe545d8ad9e8
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-gnueabihf.tar.gz=ae119ef640163fe7c73179d0f895794520c790b05decd31548631f288ba6d01e
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-gnueabihf.tar.xz=11f07bc11660e4a4b6b2a97d26cfa31c36976fb74a36b5dba7dd66c4bb81608a
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-musleabi.tar.gz=2c9f4567c766e85152981a594169f6f656d89048947d2d9a30ff805ca6f1e59b
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-musleabi.tar.xz=427c70145dc35701b0888b7863657ef0fd5d4b7bff7081e984a5e977d423c7f5
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-musleabihf.tar.gz=c042af9e0d8fb02ed80b57bae19ed8608c005dd279ec1c64dde53d65752a0b14
+dist/2025-06-24/rust-std-beta-arm-unknown-linux-musleabihf.tar.xz=b6fd66abb9f14c4b8bb43d6c8b32d9aa666be01468b60768fc8d0db4414da920
+dist/2025-06-24/rust-std-beta-arm64ec-pc-windows-msvc.tar.gz=896294c85fe8570f024a08aa0c22668f38b998dabb0008e5a4f8d7e1ecb2236e
+dist/2025-06-24/rust-std-beta-arm64ec-pc-windows-msvc.tar.xz=03a2a8658186e48c7bffa4b120821e99d4066fd115b550af4d76998545e1fb24
+dist/2025-06-24/rust-std-beta-armebv7r-none-eabi.tar.gz=3302d8df9dd73c44603b7629ece46a0a0c1f03a838a354973fe8aa2ed13ac10e
+dist/2025-06-24/rust-std-beta-armebv7r-none-eabi.tar.xz=3c9d1278136a92c6c829a07eeb991f9047e703a82145af2ba0373c0d01429ab4
+dist/2025-06-24/rust-std-beta-armebv7r-none-eabihf.tar.gz=864a261c4c337e692d4c3aa0f2659e9d87ce946309d0e61fea752f4fd7835a6b
+dist/2025-06-24/rust-std-beta-armebv7r-none-eabihf.tar.xz=ef22b1321da09ac6d64b5e965c02ab0886dd9f4281520cad4050764203b153bc
+dist/2025-06-24/rust-std-beta-armv5te-unknown-linux-gnueabi.tar.gz=d057fd26541f096995e3d774659d5d8b602e67354b8551f0b99c7595945aa194
+dist/2025-06-24/rust-std-beta-armv5te-unknown-linux-gnueabi.tar.xz=afad054eee6bcdafbb68308d7c53438e561ec26196683552d2f825c63948d325
+dist/2025-06-24/rust-std-beta-armv5te-unknown-linux-musleabi.tar.gz=65306dbc9e7d75810b28624a9dc146034b3c7764313ddac084309a36e688ba0b
+dist/2025-06-24/rust-std-beta-armv5te-unknown-linux-musleabi.tar.xz=ed4f9cffcb7b1bb1bf72b952afa422cfbc74ab9e04d6acb750126da5d0f24094
+dist/2025-06-24/rust-std-beta-armv7-linux-androideabi.tar.gz=7e39283a3e4e469e6b9dd35497515481a9050fbc1fb9f10334cf495b3c34980a
+dist/2025-06-24/rust-std-beta-armv7-linux-androideabi.tar.xz=7af0e068e2ebad42c79926ff1480e4ec07d7a48db142a497fb8f75b7a065e0fe
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-gnueabi.tar.gz=677d3328d721fbcf515bbd0628b59dde2ac1e0d7ed567f2784666430d61e391a
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-gnueabi.tar.xz=550c6df5954535165b55c07411144a122f8156658c1f46f74a71a7f17974fd29
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-gnueabihf.tar.gz=b5deee5b5ba9048dbfc1c416972df6a4d42d52f4a6d1857757e0d01d8c47a824
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-gnueabihf.tar.xz=7f898d3e1f6ec6d53a269803d4d4a248e052892bc9f46c3bb9095ffcfb0e04a5
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-musleabi.tar.gz=56f8943fc65b732dc971f01bed589d9fc19a2a263a4af4f20810f7b586ae391c
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-musleabi.tar.xz=1802d041656132519baf110e5a072260a7fe809fda87c6e01fd5fc4809249f8e
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-musleabihf.tar.gz=36917662d6e98b19782c9d81087857f52b7dfdbb37872387285c9507a1bff391
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-musleabihf.tar.xz=e6aec6411c740e5470879e64c85882cf3627c24c7d584f359c77397a782a613c
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-ohos.tar.gz=0c9a18a6b7a7c981c5e0ef337e66915d14499c6392bbfeb55a65c4f3340a4835
+dist/2025-06-24/rust-std-beta-armv7-unknown-linux-ohos.tar.xz=f1cce70c71bb712a9aba0827ebb7d5783b977a674606cf5fe10879db81627c5d
+dist/2025-06-24/rust-std-beta-armv7a-none-eabi.tar.gz=d477ce01b099b81e96a9edf6617c21725808c4c234c4ab2f84216565f6a6efcb
+dist/2025-06-24/rust-std-beta-armv7a-none-eabi.tar.xz=a2339cd5cd3dcbb5b897740b7e7bbf6c5130feb1f6ef7c2c09012eb6cc79d417
+dist/2025-06-24/rust-std-beta-armv7r-none-eabi.tar.gz=40fd9ed6b6b428cd476f690ebd3e2265cac040f4772b91af76b071115b16b9aa
+dist/2025-06-24/rust-std-beta-armv7r-none-eabi.tar.xz=c2dae5167d4f7f6e1d797b065404cb647d102d0f0165fff89d040c5c89faadb6
+dist/2025-06-24/rust-std-beta-armv7r-none-eabihf.tar.gz=c4731d34cb23614cda51fba5e66d6327c653c21df71795bdbcfa48f20aa0ef17
+dist/2025-06-24/rust-std-beta-armv7r-none-eabihf.tar.xz=561f5934f8bcbd9860f7b042d9baa4d4ffe0696eeb3a0447ae04467497b749ad
+dist/2025-06-24/rust-std-beta-i586-unknown-linux-gnu.tar.gz=035ad6be061e3a3bbe36baffd1bca5cfb91d827e07b441e3e2c32b0b9e1212f4
+dist/2025-06-24/rust-std-beta-i586-unknown-linux-gnu.tar.xz=5ca691898ea3cc66822aa32ac9d24996610cd79e34275b35a53e252f5c99fae7
+dist/2025-06-24/rust-std-beta-i586-unknown-linux-musl.tar.gz=614a68e5593b672f87601c07f95b30324a3a60e10ffe814fe2a772d533a9eabf
+dist/2025-06-24/rust-std-beta-i586-unknown-linux-musl.tar.xz=78f7ed2c2f0f3e0e0d883ffc94a4fae43e7e5f3fff6e91e16d8a459a40570fee
+dist/2025-06-24/rust-std-beta-i686-linux-android.tar.gz=d6e5a0fa260c5222e4cce351be2eeed9b85951a8e79bdfe379a4fc2be354d558
+dist/2025-06-24/rust-std-beta-i686-linux-android.tar.xz=3e0c1ff1e8528a7c0a6cda3a7a90c2ee88b0b1b697b2430d410dad944df11a46
+dist/2025-06-24/rust-std-beta-i686-pc-windows-gnu.tar.gz=f944a4982a6ca520284bcc5633f05226f636747b8df4325ca1a2c77049e2ebe7
+dist/2025-06-24/rust-std-beta-i686-pc-windows-gnu.tar.xz=6664ba19dd85737fb5276e8e83a30989c49e795dd4608e67f33f4115253c0753
+dist/2025-06-24/rust-std-beta-i686-pc-windows-gnullvm.tar.gz=9e7e7838710db5f340448e957a5ba812a3fe91baa40ba68c355fdee653b0413b
+dist/2025-06-24/rust-std-beta-i686-pc-windows-gnullvm.tar.xz=c5d4c6274444e695630309ca66fd52f08645eefe424b5e287e89064eb10aee2a
+dist/2025-06-24/rust-std-beta-i686-pc-windows-msvc.tar.gz=e1bdc0d04736e0bc95e131eed25944f62a4d2896d80778b8a2260df38e0f9946
+dist/2025-06-24/rust-std-beta-i686-pc-windows-msvc.tar.xz=7df4a0e74e6ad457fbe38d0eaf40a3d190f0d77d6b4d1d3940028e9c7935558b
+dist/2025-06-24/rust-std-beta-i686-unknown-freebsd.tar.gz=a791a76c83a257590c8ab653b92ce65d74f4885faebf64c91c111363d237aeb5
+dist/2025-06-24/rust-std-beta-i686-unknown-freebsd.tar.xz=7455eb781d0e1a0b6a154e93d7cf2ae2891f20fd77b8a2a0a3011e94a5013147
+dist/2025-06-24/rust-std-beta-i686-unknown-linux-gnu.tar.gz=c6f770e2cf229e97640845137df23a7da8f6e6e9753d494dc9d5aa8dfb506e95
+dist/2025-06-24/rust-std-beta-i686-unknown-linux-gnu.tar.xz=d7c351e3a45181f040acd5f8c20c655d878a0d53927489891603b91c80c4abb6
+dist/2025-06-24/rust-std-beta-i686-unknown-linux-musl.tar.gz=547a90d1f7742389642590bfc45b66474febebe3c6c5209cb1b22773e65ad03e
+dist/2025-06-24/rust-std-beta-i686-unknown-linux-musl.tar.xz=6c7476b7b93ac2a97ec5385ecb55463b11118b84aaf9a155a1cdbb68ea879241
+dist/2025-06-24/rust-std-beta-i686-unknown-uefi.tar.gz=1f45c12ccc6d27bc6931a6348dd0a0a3f4e5eb63ad45e4ec362f706bb327ee24
+dist/2025-06-24/rust-std-beta-i686-unknown-uefi.tar.xz=43c76c933f3eee6f7c4230fd34e702a59b5a5ad088c9bc20112e4e0b2d5dbaae
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-linux-gnu.tar.gz=caed38451c419ab05e54b8d20f6af56a274b3c59b000a0ffa51b7b63ea314c27
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-linux-gnu.tar.xz=5418975da12a39cecfb1a040dbb2ae6b8b63a76b652aca582ce04aeebb3c05fb
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-linux-musl.tar.gz=b0d0856119c2b15f1ce6c3fe26e9f50550817c896235784333afd502ee804957
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-linux-musl.tar.xz=22c39fa9a460b12e782951794fe92537fbf8108db1e4cee4c641a07d9741145b
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-none.tar.gz=2433c862a1fec8a983112f6472bdd0e6bf9ce66ce9484f89b78d80c65375a70e
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-none.tar.xz=dfff451f7f16c309cd0335def206429b2f10ab4943d59dd7cabe8afd8c072dfd
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-none-softfloat.tar.gz=d975fafa4271c774d8295cd93944ca91528960c12aa087435074b78c0ad783a7
+dist/2025-06-24/rust-std-beta-loongarch64-unknown-none-softfloat.tar.xz=561172fcbb2448dfa60a0daff761d8e6022543dbff191b584614adfcef8f255d
+dist/2025-06-24/rust-std-beta-nvptx64-nvidia-cuda.tar.gz=f381683e2aca2a54f9aaa920c71eb8a06f50edb2967968b63a32a53bae3c2e7f
+dist/2025-06-24/rust-std-beta-nvptx64-nvidia-cuda.tar.xz=e09536466bf24c3ddf250bcd4e92677446341902e6c20bbed7f20a9a11250462
+dist/2025-06-24/rust-std-beta-powerpc-unknown-linux-gnu.tar.gz=56484912fc1ee60288b5739b5e08680361cf8abbc927cb30012f491e77483192
+dist/2025-06-24/rust-std-beta-powerpc-unknown-linux-gnu.tar.xz=96bb329f992b3c8e060796e52aca2ba384225f350ccc2c12d0aa8022b1305842
+dist/2025-06-24/rust-std-beta-powerpc64-unknown-linux-gnu.tar.gz=806c017f5a94c70722ebb38d4e2ee8fa87d5d53b63712763114fc318d33edb8f
+dist/2025-06-24/rust-std-beta-powerpc64-unknown-linux-gnu.tar.xz=e4bcfd4ffb2db92ff57f881875755b9808744c8e59efb2a3ae9c215a05e696ea
+dist/2025-06-24/rust-std-beta-powerpc64le-unknown-linux-gnu.tar.gz=8082559bc3da5b9e6e39732e83682a892df8535f75321710c6e5748f6e7e1985
+dist/2025-06-24/rust-std-beta-powerpc64le-unknown-linux-gnu.tar.xz=d05626a5f3c364aba66aa214530fbf37a38b7c613c8c1a54c5ba46d66477db96
+dist/2025-06-24/rust-std-beta-powerpc64le-unknown-linux-musl.tar.gz=03690be0e07e3158da23750b4fc063c25b5760bca3447877cbcd45707eda9780
+dist/2025-06-24/rust-std-beta-powerpc64le-unknown-linux-musl.tar.xz=4b1997788c727c36a64eb335de3c7d8f100c3825129a1e4a2187e3a23851f083
+dist/2025-06-24/rust-std-beta-riscv32i-unknown-none-elf.tar.gz=421dd99dcdc80a55c8a159d22c3c596424029f1fa1d7c12bfdc7b718091b776c
+dist/2025-06-24/rust-std-beta-riscv32i-unknown-none-elf.tar.xz=1a574ae822a4ad793c10313d79dd5566d9ff74d7a7b83d860e06df0aa752a151
+dist/2025-06-24/rust-std-beta-riscv32im-unknown-none-elf.tar.gz=0b0891369b16ea1480554b2670311aaf6b7937420056d04b1ce2c80ef3955bb2
+dist/2025-06-24/rust-std-beta-riscv32im-unknown-none-elf.tar.xz=366db574f295053b2bbdeb35a7c597fb624396b1896bf482067d5d5cee7e4f19
+dist/2025-06-24/rust-std-beta-riscv32imac-unknown-none-elf.tar.gz=813cced4f75479412b22dba98148036da9ccfe9e1181009b8ca99f3e12398932
+dist/2025-06-24/rust-std-beta-riscv32imac-unknown-none-elf.tar.xz=5378810bc555e2d4be7bf5d43731649f803943854ea23da7a36887254f473a59
+dist/2025-06-24/rust-std-beta-riscv32imafc-unknown-none-elf.tar.gz=709c652ec071033227867dd87ba19483e30f6f68e95b36c448d46b0321b693ef
+dist/2025-06-24/rust-std-beta-riscv32imafc-unknown-none-elf.tar.xz=cd6935d932ef81beab950126dd932ee6d0fa11105974f94485640fff894c1bc8
+dist/2025-06-24/rust-std-beta-riscv32imc-unknown-none-elf.tar.gz=43ac51227f85776f98c91dea378b765cfe870141d6bac7ae8aa0cbb0ce821de8
+dist/2025-06-24/rust-std-beta-riscv32imc-unknown-none-elf.tar.xz=c5ddf06de14b22ba431c1f8d1944425ea325b0cc83c3f2a2ee85291570187824
+dist/2025-06-24/rust-std-beta-riscv64gc-unknown-linux-gnu.tar.gz=d45fe2a30afd25bb2975e006cd17b612221a710814611670d804a9bd2f4efd84
+dist/2025-06-24/rust-std-beta-riscv64gc-unknown-linux-gnu.tar.xz=b43a87dbd6ab3b3d440f2bbeeacc77719d29347b980e74160301539902f039ea
+dist/2025-06-24/rust-std-beta-riscv64gc-unknown-linux-musl.tar.gz=cfb5d97f24c7daf95d833b519a8912b2fcdaba31d8d1bece90c406ae8a2ebd32
+dist/2025-06-24/rust-std-beta-riscv64gc-unknown-linux-musl.tar.xz=66e5fb37d89bd0fa7b8a2721f4b610711ca6069f9e406c5cb9b90d792e70b5ae
+dist/2025-06-24/rust-std-beta-riscv64gc-unknown-none-elf.tar.gz=5e1f10a92f1ca7bd4a0325662d15933371e756f0eee554e04b525f35b036e050
+dist/2025-06-24/rust-std-beta-riscv64gc-unknown-none-elf.tar.xz=7c09140b3af9ea56fafb724f66bb67d73bc788d139330b373eccd9fecf014024
+dist/2025-06-24/rust-std-beta-riscv64imac-unknown-none-elf.tar.gz=1c41567f55b86e683efff62f0fd397dc43324e2e664c0702f1c79db8b407759b
+dist/2025-06-24/rust-std-beta-riscv64imac-unknown-none-elf.tar.xz=63573b32f25f53bfe42b1a4beecc75dba0f0e8f02be9e680a45a2429a46a6f9b
+dist/2025-06-24/rust-std-beta-s390x-unknown-linux-gnu.tar.gz=3725c30ee0938a4cf3c9f29e115c61d8045f437c06887e39644a1211ba18a4b6
+dist/2025-06-24/rust-std-beta-s390x-unknown-linux-gnu.tar.xz=2bb94be7f6ee32bc23748e69e399a5fd087671e3e4fd8d77e819e51dff8cee5c
+dist/2025-06-24/rust-std-beta-sparc64-unknown-linux-gnu.tar.gz=b789df52548c45c070057ade63f1d6351ba3cb39403a9e33c0776bafa5985abb
+dist/2025-06-24/rust-std-beta-sparc64-unknown-linux-gnu.tar.xz=84179facb34fb286545622407ac6bfd5bb2b7546e02e56597152ab5bab49fe93
+dist/2025-06-24/rust-std-beta-sparcv9-sun-solaris.tar.gz=ec9de10d91c1f912d97f2a96aea58e6c7cca5ab864a14a7aae62064c8ddb1e53
+dist/2025-06-24/rust-std-beta-sparcv9-sun-solaris.tar.xz=6628f2b64f56ff05ac18bc7486231a3f072de23979de2bc1fb7133670e32f98e
+dist/2025-06-24/rust-std-beta-thumbv6m-none-eabi.tar.gz=a202ee09869f4902d1769b42cd05a992293003f92d4d62db8d87c195f9c9dd9b
+dist/2025-06-24/rust-std-beta-thumbv6m-none-eabi.tar.xz=e34431bd5a7a00fbc9af4ee5c697b7244cf768477e05e68c6739a4c9561feb11
+dist/2025-06-24/rust-std-beta-thumbv7em-none-eabi.tar.gz=681da6a51ba84e4f517f1390ff4e8c09fbb9cca0515e67ce074c3431d582cc7a
+dist/2025-06-24/rust-std-beta-thumbv7em-none-eabi.tar.xz=ca7a21b1e58625bed5a9d8ee9e20ae7fd33fc822741e1aa8b4cf2599e45f6edd
+dist/2025-06-24/rust-std-beta-thumbv7em-none-eabihf.tar.gz=51f4d95e11a9b5dc59534e63277c1567e8ba8edf205f50bfb857d0bc2d2a0a16
+dist/2025-06-24/rust-std-beta-thumbv7em-none-eabihf.tar.xz=066189a75cba466b8f6881e559c5501a987741a5314a3be18045339111eaff67
+dist/2025-06-24/rust-std-beta-thumbv7m-none-eabi.tar.gz=97395d2c7f9ffca227434df59925082be1c19656f78af8914886e37ec687bac6
+dist/2025-06-24/rust-std-beta-thumbv7m-none-eabi.tar.xz=9904335b8a696233694a96538d965a8ca6b62a1cb8e155818061fd1ae3f7d8e2
+dist/2025-06-24/rust-std-beta-thumbv7neon-linux-androideabi.tar.gz=8227426bae9b1c242deca19312af3bb3e64fcf736e7902cb74daed2e3595bfe5
+dist/2025-06-24/rust-std-beta-thumbv7neon-linux-androideabi.tar.xz=0908f15689366fa9cb3a6acf5f85a6355aba2f30387d17b0ea51edef5a7903b1
+dist/2025-06-24/rust-std-beta-thumbv7neon-unknown-linux-gnueabihf.tar.gz=f2b3fec136958adf29a43d3307505f6fe79fd0e00f9abc42a56c0a04fadcf227
+dist/2025-06-24/rust-std-beta-thumbv7neon-unknown-linux-gnueabihf.tar.xz=4520b3d88a48e054ea4c243904d3c7fdaa8dda0a448e48014d78d9ada1982220
+dist/2025-06-24/rust-std-beta-thumbv8m.base-none-eabi.tar.gz=da25e5bb90b522db9ab502068b7a7f4ec0a9ce7fbc0b98949e345490ff5854fd
+dist/2025-06-24/rust-std-beta-thumbv8m.base-none-eabi.tar.xz=eebf1b73a75a4dab88bcc70121c024f40184ac30668ff298620853bd770a6e03
+dist/2025-06-24/rust-std-beta-thumbv8m.main-none-eabi.tar.gz=ad77f75d12be96cd135cb7dec17688635f98101072c014724e118d1e1d124afe
+dist/2025-06-24/rust-std-beta-thumbv8m.main-none-eabi.tar.xz=038927ed53bca15d35ceaa33d9d8ca3e21be380d853b67404535317327e42ec5
+dist/2025-06-24/rust-std-beta-thumbv8m.main-none-eabihf.tar.gz=e5f4e09db94d0a92985bb4e0e72c1cf9402c81647bf4ee2f56b5b0626da1bfe5
+dist/2025-06-24/rust-std-beta-thumbv8m.main-none-eabihf.tar.xz=662c722d3445141d1f3aeb070e789c5115776a3dd909faf5a39b9ce3df8c8933
+dist/2025-06-24/rust-std-beta-wasm32-unknown-emscripten.tar.gz=cb2630b14ef721b43366e8f6135fb37ec3d2185951bd66344e329644fdc31812
+dist/2025-06-24/rust-std-beta-wasm32-unknown-emscripten.tar.xz=4c7e117fa93c9220b5e6103fb7802c18b4a6c53f2836480d60263046e73c3a8b
+dist/2025-06-24/rust-std-beta-wasm32-unknown-unknown.tar.gz=1e9ac4f3fb341dfb1719fe5643e7cf867ebe69172e352ba94fb18b63bc2518e9
+dist/2025-06-24/rust-std-beta-wasm32-unknown-unknown.tar.xz=c207fb92fa666f3113c451cd584ebe666e36d6a1b97a3b91be1d513920ddf26c
+dist/2025-06-24/rust-std-beta-wasm32-wasip1.tar.gz=e68f2697d3824721abeeb1d953455dd3d54ba8549d3b7c6998f00869747f3e99
+dist/2025-06-24/rust-std-beta-wasm32-wasip1.tar.xz=46150b8817705718589a85bf9b657acf60bd9c8829cb42fc4b59264cb357921a
+dist/2025-06-24/rust-std-beta-wasm32-wasip1-threads.tar.gz=1a718af362f1314cdf934901b4eb26c8ea678a28009e8e725d46452420b1d7c9
+dist/2025-06-24/rust-std-beta-wasm32-wasip1-threads.tar.xz=f4c785ae809fa803562e2a1e406fd7a0362f44174e40913803e3332672bd1e40
+dist/2025-06-24/rust-std-beta-wasm32-wasip2.tar.gz=f17386b04a3f003bb42ca83a2044b23bb1b766b65b64b44c10e9d24f09a1bfc8
+dist/2025-06-24/rust-std-beta-wasm32-wasip2.tar.xz=9f90613dc5c6f659087144d6e25b091cd1a6fa09697a0d2d4c896bf74f473d9b
+dist/2025-06-24/rust-std-beta-wasm32v1-none.tar.gz=753c77345c3b1fd7407a69d29a3cf3fb8c2dcd813c2ad63c1e97fe0dcf203f94
+dist/2025-06-24/rust-std-beta-wasm32v1-none.tar.xz=3bee75d197b4679c2355fad5739aebf721b182e93bfe76f1b8b9e004bd146d5c
+dist/2025-06-24/rust-std-beta-x86_64-apple-darwin.tar.gz=aa7ac11017e96b2bc2c103c160dd03aa0e1826034c30a417b11d67b9fb657f2d
+dist/2025-06-24/rust-std-beta-x86_64-apple-darwin.tar.xz=89a065f72d284cf2f886b7af2edc89f89812531d85aec8608ca0c1516365082e
+dist/2025-06-24/rust-std-beta-x86_64-apple-ios.tar.gz=b814b2fb46db55b18e1b5bcd0ceba73745ca6f7a57afc7b90009275d61bb95c8
+dist/2025-06-24/rust-std-beta-x86_64-apple-ios.tar.xz=5a82ad2a7e45df8f5f1c374ac5bef2dd4f7da81dec2a348c75593e1bb752dd40
+dist/2025-06-24/rust-std-beta-x86_64-apple-ios-macabi.tar.gz=2482863c941aec4d9de753a8787961206e1ba8129180e2e85a4ac3eb158ae8a7
+dist/2025-06-24/rust-std-beta-x86_64-apple-ios-macabi.tar.xz=744d487c980f455d967df95c466399b181a891a879c25eac677fadfd87ebbaf3
+dist/2025-06-24/rust-std-beta-x86_64-fortanix-unknown-sgx.tar.gz=9ebd84ebf36aaf8707268965ccc9efa69b259edd7d3a5fe13be4d21dc63f6bfd
+dist/2025-06-24/rust-std-beta-x86_64-fortanix-unknown-sgx.tar.xz=06020c24f4d5b339c794cd16fe87b1fd7f77d8d54f9d83f0d6088fbd062c900b
+dist/2025-06-24/rust-std-beta-x86_64-linux-android.tar.gz=f5054210cba3367f5c9fc0c37b7f2cdfcf90ec624e7b1b3cddf24b2bbba53c7b
+dist/2025-06-24/rust-std-beta-x86_64-linux-android.tar.xz=65dca5fdb5c9138b4361819aed754a574d74bed1a2d7a7aace1fda15821ba2f2
+dist/2025-06-24/rust-std-beta-x86_64-pc-solaris.tar.gz=575392afe724160d65c05dcfeda4d9b4868c182aefd8981a4b233222bc1168c1
+dist/2025-06-24/rust-std-beta-x86_64-pc-solaris.tar.xz=f385ad71529ff286607a461c84a15df81e9a8f880ee64a50cff8979c52262f27
+dist/2025-06-24/rust-std-beta-x86_64-pc-windows-gnu.tar.gz=647b7e4a44d1802721461e6c9d6ab1f7e148183476c01e410b7052e485081a61
+dist/2025-06-24/rust-std-beta-x86_64-pc-windows-gnu.tar.xz=817535fcf0efdd1e84ed85787fce6e674c22b120bce0c8aa1dbe53b2b41aebdc
+dist/2025-06-24/rust-std-beta-x86_64-pc-windows-gnullvm.tar.gz=c6486c9cbf372d64858d4d251750c3dcf07e95d58b55ccec87a4c71292eb7d11
+dist/2025-06-24/rust-std-beta-x86_64-pc-windows-gnullvm.tar.xz=75c3f76b85534f0d058913328b9ee58c32a3a08414b4c5e7a046a87970b9eba1
+dist/2025-06-24/rust-std-beta-x86_64-pc-windows-msvc.tar.gz=d61125fae17e7627e7b56ca4ed32500b48a146d000e4a723ba34780568d8c0d0
+dist/2025-06-24/rust-std-beta-x86_64-pc-windows-msvc.tar.xz=590b14dfe52e3a286763d19ac19a83315c47f33a284d59169e145c8860eddfd3
+dist/2025-06-24/rust-std-beta-x86_64-unknown-freebsd.tar.gz=76e7066a540a06ac241a11df8fbefd511b48d85aa46f380a8b122bc342395faf
+dist/2025-06-24/rust-std-beta-x86_64-unknown-freebsd.tar.xz=7cc4adb3c102eac53916b28c0dad40bd095e19ea3fd0430e84a2e0b094445809
+dist/2025-06-24/rust-std-beta-x86_64-unknown-fuchsia.tar.gz=b6b97c0e0348051a314bc705d8361f5609c63a42eaa3f85081d004c0258ac9fd
+dist/2025-06-24/rust-std-beta-x86_64-unknown-fuchsia.tar.xz=5dd625fd17faa417e1c0abc5aef7a3f40d16122227c8078f8e0ad2530ef6d271
+dist/2025-06-24/rust-std-beta-x86_64-unknown-illumos.tar.gz=92bbecc4de50711693b54a11559a07f17569f60b1600ea40d6f6ce2e3a24ad10
+dist/2025-06-24/rust-std-beta-x86_64-unknown-illumos.tar.xz=fe3cb8e3adb7f4fd5f64feaa57587b4e41ba7437553e94a36f59a5bdca293f06
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-gnu.tar.gz=a81e77c04cbc0b0f456c117361e695b78ae234cd53043368e62dbf10810c2c8d
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-gnu.tar.xz=c71ecb0a0c44cb7a9f35b6fe71e73f605d025af16f1ee5f1fd9c8a432144c54a
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-gnux32.tar.gz=2fcfa0c62f69b5e6d78c31596e7b6136bac38d65efabdd8fafdedd731bb124cc
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-gnux32.tar.xz=b2cced1e9ac03a4aa4f39de7ca6b8ed8cef2201bc851a413214e414001601ee9
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-musl.tar.gz=178fe4f5b68e65450abaecf5c45c29e2a458bdde9b7c16f59755bdb1b4c1c218
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-musl.tar.xz=eac7c2aaf40a31c2fb9fd792bacdff8b573f2fdcd2e52f4c7e798b51e2586652
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-ohos.tar.gz=0c481e67a034eede634c201c88aae0cd2ecb36c656256728aff44b211657ab45
+dist/2025-06-24/rust-std-beta-x86_64-unknown-linux-ohos.tar.xz=4a1fc452d88bce5100d0da49c0a42621296731f7584de1e7869ec41800454bf9
+dist/2025-06-24/rust-std-beta-x86_64-unknown-netbsd.tar.gz=f7cb4b3d73ba6e571b77e5b58d877da5f89664d0107360f7c183c45df7b98e2a
+dist/2025-06-24/rust-std-beta-x86_64-unknown-netbsd.tar.xz=6dc733be1457802f8c54a6f2bbc6f337204c2baef693888c1302b6f2df11e7aa
+dist/2025-06-24/rust-std-beta-x86_64-unknown-none.tar.gz=16e3765f0c5b017ce3f6e2f3325c30e27eabb85fae1d935198f376fbe33e2551
+dist/2025-06-24/rust-std-beta-x86_64-unknown-none.tar.xz=60c87182e6f9d6ce4e8e612ac6aadd3989e69073f5fa0774d0e8dd76a47d122f
+dist/2025-06-24/rust-std-beta-x86_64-unknown-redox.tar.gz=757169fa5abdcbf592aecc8b77a7ac48de7fad19a0cc714e5e0c37f0c887b36d
+dist/2025-06-24/rust-std-beta-x86_64-unknown-redox.tar.xz=9888201cd4d10eeeb5b4c342aafcc10b1933f32df7e90ff2e9cf6ef0be6759f7
+dist/2025-06-24/rust-std-beta-x86_64-unknown-uefi.tar.gz=9d84268a50c1a730eb999761e248e166942dffbed9d6ab92ee1ef05ffa43d133
+dist/2025-06-24/rust-std-beta-x86_64-unknown-uefi.tar.xz=3ac1e6eecfc611b6be02a10eb4708c8d6932dea2004ed8c8441a619a61eb25f7
+dist/2025-06-24/cargo-beta-aarch64-apple-darwin.tar.gz=6dcf7741941f12ffac96f8210c9cafc3ee68bbed9211a95bcd33e1e835454b31
+dist/2025-06-24/cargo-beta-aarch64-apple-darwin.tar.xz=39d6bff308caf2fd5550325f2f930cbc3d77dd4f385d21e0509688d2203acdf7
+dist/2025-06-24/cargo-beta-aarch64-pc-windows-msvc.tar.gz=ff9d9c47fc85ee51ac1194138b25d8626704621e38871bf03a7e1c015c88ed60
+dist/2025-06-24/cargo-beta-aarch64-pc-windows-msvc.tar.xz=459006cc1a313e9ed28665015dcec313413722df20de729dada4f9e5a11d4809
+dist/2025-06-24/cargo-beta-aarch64-unknown-linux-gnu.tar.gz=62371da9200aa838f8e217347c3aa5568010d9fc2d963077e785d0f7f75417b9
+dist/2025-06-24/cargo-beta-aarch64-unknown-linux-gnu.tar.xz=cf7ec78f834f41c658179524a741b472c7ab4bbed3d6c0d7f61e7147d7353a78
+dist/2025-06-24/cargo-beta-aarch64-unknown-linux-musl.tar.gz=2ba26fb886020b136b6635ad89caa96d995c4179ffeb4c06bd8a5484c6e94669
+dist/2025-06-24/cargo-beta-aarch64-unknown-linux-musl.tar.xz=343f471ea1df375de51b881b6829855ca060d8e9e6bf3b066123d3e7fc348c18
+dist/2025-06-24/cargo-beta-arm-unknown-linux-gnueabi.tar.gz=4f03751e62a43cfe8aa9528a9af2903bee629ce1d7eb808a3f5c9881e7c3fa4a
+dist/2025-06-24/cargo-beta-arm-unknown-linux-gnueabi.tar.xz=4082553dfb3af462d9e70c1c13b505dece9a0dcdf5584da2a311d7d6c4e45838
+dist/2025-06-24/cargo-beta-arm-unknown-linux-gnueabihf.tar.gz=d80111e0b74f8e9d5412307c6dffe53cb77a8febd25ae6d8e66813aefa56a7e5
+dist/2025-06-24/cargo-beta-arm-unknown-linux-gnueabihf.tar.xz=d06aa271a329ba63c4d1a3a6adf6ced0c5c1b900b20870c666ba6764f2d5e5cd
+dist/2025-06-24/cargo-beta-armv7-unknown-linux-gnueabihf.tar.gz=5509454a5390a5732b340959974dab97e31b6f307d036e55b788633cb21e6f54
+dist/2025-06-24/cargo-beta-armv7-unknown-linux-gnueabihf.tar.xz=bc6e883addc936fe55009fa854922c2ec405ee2c085749476bf3848070098116
+dist/2025-06-24/cargo-beta-i686-pc-windows-gnu.tar.gz=2afa312411c50a629c62661d245f3672e305d7f083494cb0dc8034a726c72a54
+dist/2025-06-24/cargo-beta-i686-pc-windows-gnu.tar.xz=67e0cbfff31418c767e81bc45ddcfe6e9a47b0f279b49c0b0cad84aa589802c7
+dist/2025-06-24/cargo-beta-i686-pc-windows-msvc.tar.gz=1a9d5cf8c1dbe182b224687bdba0026120fc684232a89488db52160dd6f8145c
+dist/2025-06-24/cargo-beta-i686-pc-windows-msvc.tar.xz=9ce77b6d3ffbdde316b54c1abc6fec888ea5d4307e0a4bab7555b9460122e3cb
+dist/2025-06-24/cargo-beta-i686-unknown-linux-gnu.tar.gz=1d9fb35b564e718616ae2766cbc99e041d4e9d53bb0d8f885cf971e0803c85a8
+dist/2025-06-24/cargo-beta-i686-unknown-linux-gnu.tar.xz=c0c5c0f72726b577fec05670b6f9d46501b79af55c642d2b2f58a88e731db7ea
+dist/2025-06-24/cargo-beta-loongarch64-unknown-linux-gnu.tar.gz=2bd4605054472e27df314d795c524126a2ab54e9f37442f579e6d75b8a7a0534
+dist/2025-06-24/cargo-beta-loongarch64-unknown-linux-gnu.tar.xz=7f8dc8897f88659268ed0247bce6fd35b4de813fcac5bd488d20c28504bee028
+dist/2025-06-24/cargo-beta-loongarch64-unknown-linux-musl.tar.gz=dc52a8982e04f52b5c42a09c3fabf3529b3871d90039299ddbc2648713e3b8f9
+dist/2025-06-24/cargo-beta-loongarch64-unknown-linux-musl.tar.xz=c25a1beb08ba399a98eb77c4baf4bcad80003eaae09fcb7cb6253943d5ccbc05
+dist/2025-06-24/cargo-beta-powerpc-unknown-linux-gnu.tar.gz=4d0841925d6f2664b4b110b4fb3f3c62a64b34b925722d08cdcb2b568e3f0682
+dist/2025-06-24/cargo-beta-powerpc-unknown-linux-gnu.tar.xz=c81c32af1c4e7e432112515af1dbdd6e4adbea668710881b63af7acd5c4715f9
+dist/2025-06-24/cargo-beta-powerpc64-unknown-linux-gnu.tar.gz=08d06b8b77148626bb2bd17059619083cd13d3d3f344c146dd509bf5d0d3d7b1
+dist/2025-06-24/cargo-beta-powerpc64-unknown-linux-gnu.tar.xz=55cd74747e6993eee6ec3aba36a79d108bf952d64a646696883e33798b27ade7
+dist/2025-06-24/cargo-beta-powerpc64le-unknown-linux-gnu.tar.gz=eea9d0980545cd6ffde6ea512255cc2d66d335c23a8850695c87885bb931183c
+dist/2025-06-24/cargo-beta-powerpc64le-unknown-linux-gnu.tar.xz=7fe952473dca82b599745a9f3578b4976e43a6f91bba02a59da216a748d3a3f7
+dist/2025-06-24/cargo-beta-powerpc64le-unknown-linux-musl.tar.gz=6cba20c43713901144fe4542c4e410299e12306448d214614c19dfa201ee7853
+dist/2025-06-24/cargo-beta-powerpc64le-unknown-linux-musl.tar.xz=2c40f5715befa7938c3f1c2a65a787c497e97eb57bf03a82fba96f3eb55567a9
+dist/2025-06-24/cargo-beta-riscv64gc-unknown-linux-gnu.tar.gz=ad81074f9ea5c4373285dfaceafcb0d00f3372ac1d0655ac0ad0b2af816809bc
+dist/2025-06-24/cargo-beta-riscv64gc-unknown-linux-gnu.tar.xz=f963720adb03fdc4508d7037937345109973e1b15f9590ba7393dac26c493b6b
+dist/2025-06-24/cargo-beta-s390x-unknown-linux-gnu.tar.gz=b053764c635f2a943074c6f4b9f615ce6324d4c488143086ce2ead7d5e685790
+dist/2025-06-24/cargo-beta-s390x-unknown-linux-gnu.tar.xz=a214a89077adacb0e73acf6c7b0a312822eb72313be88aa5a1865dee7fba8dbe
+dist/2025-06-24/cargo-beta-sparcv9-sun-solaris.tar.gz=c2d95ad154fc06aefa53c54e5a71f019b46146d2efddcb2f605977a393dacfb8
+dist/2025-06-24/cargo-beta-sparcv9-sun-solaris.tar.xz=a4c001aa2a9def4fce93d910e0afc3dab6a8fa2c767e51f5bf5ad05b9fd8c2c9
+dist/2025-06-24/cargo-beta-x86_64-apple-darwin.tar.gz=3942f0f82e2797f146f171e69a4ea0c58c6c37aca319bf9a80ab3e96bb540407
+dist/2025-06-24/cargo-beta-x86_64-apple-darwin.tar.xz=07c111b584a728a6e1ffd2694864eceebf3cb6c58c6d860778f8266ee050fe50
+dist/2025-06-24/cargo-beta-x86_64-pc-solaris.tar.gz=175f782e1e9d4aa0fc12b618f46c75077d63014ce92e07b6a9faecad797ef787
+dist/2025-06-24/cargo-beta-x86_64-pc-solaris.tar.xz=b8c317d244fafbfbaa702b3fae80db1119f9e5804c30370c45e5070915241d29
+dist/2025-06-24/cargo-beta-x86_64-pc-windows-gnu.tar.gz=ec0a52c99193bc8b995627809ca18f09e3fd7ea2a7a2eb9cf02a7af0012438c4
+dist/2025-06-24/cargo-beta-x86_64-pc-windows-gnu.tar.xz=a85b1e69b0ecb3323f1ba57c99c6ab62befe0146ca52905cc7db063dafa75667
+dist/2025-06-24/cargo-beta-x86_64-pc-windows-msvc.tar.gz=c775f0978a7a7f09b7277e41ff4c07f5cf7d2bd16a15dbd6cc89217c79192a56
+dist/2025-06-24/cargo-beta-x86_64-pc-windows-msvc.tar.xz=e956dc392e72fae8e42de5450c53c30e2fba56656cda1c6d5307ddd0d58653e7
+dist/2025-06-24/cargo-beta-x86_64-unknown-freebsd.tar.gz=2c8abc632a6e197fd93ccac1f2649247d31ad48519c5ad12a2b9c059e6725bd1
+dist/2025-06-24/cargo-beta-x86_64-unknown-freebsd.tar.xz=be762a368c6dfbe47a0f8c4b09cea1755a6d311f713b57b57a87276c88e5c34d
+dist/2025-06-24/cargo-beta-x86_64-unknown-illumos.tar.gz=6a2f8043e69c1297da8084f3c37695dfccfe30c4b23f7607e39e55ba3bfd082c
+dist/2025-06-24/cargo-beta-x86_64-unknown-illumos.tar.xz=471e9de6a783b7be80e44ad7626869ab06f03df9de00fdd35e9937607c259314
+dist/2025-06-24/cargo-beta-x86_64-unknown-linux-gnu.tar.gz=634d3c89c05ca3b9f4579dd607a2122b03a15b342e616bb62355d642c286dcac
+dist/2025-06-24/cargo-beta-x86_64-unknown-linux-gnu.tar.xz=93eeaf15597a264f552c6d60d3d833f15503f6dcc7d909f4138e1daedd56bdd9
+dist/2025-06-24/cargo-beta-x86_64-unknown-linux-musl.tar.gz=e8711c3926302bf6e2647d19028716cbb6c77c2e858c6d452f61d2d0a65df559
+dist/2025-06-24/cargo-beta-x86_64-unknown-linux-musl.tar.xz=a34fc3ab20fecf5221014068128c9ca5806788d16b7c0e2b490ad2e611614388
+dist/2025-06-24/cargo-beta-x86_64-unknown-netbsd.tar.gz=7afdb8922a69f922fcfee48e8028e0541b66fd34c18dd64f38b76477efc4744b
+dist/2025-06-24/cargo-beta-x86_64-unknown-netbsd.tar.xz=494e3e4648b22e285a763c190dc510ce5b75495da4184bf3feee3b77107a4df0
+dist/2025-06-24/clippy-beta-aarch64-apple-darwin.tar.gz=a8d3580790758c6bff3972a189c7e5f18472459c533368fcd9d04c40338166dd
+dist/2025-06-24/clippy-beta-aarch64-apple-darwin.tar.xz=9af8d1dc8f8111e26aa509ada13561b19dbf3f47e3416faecc170abdb433cdc2
+dist/2025-06-24/clippy-beta-aarch64-pc-windows-msvc.tar.gz=866653887ddbb770d0acd843ab54bd688abd2f3a384bfafeaf47d0643d7c7be5
+dist/2025-06-24/clippy-beta-aarch64-pc-windows-msvc.tar.xz=62d0400196a347622b7cab566fe64a87082e94933d0d0f28c3f9d0b9682764b4
+dist/2025-06-24/clippy-beta-aarch64-unknown-linux-gnu.tar.gz=2659dd96831dfeabbe2f4806ec67a449dca2d3f950f705280a99da9d9e1fbb1b
+dist/2025-06-24/clippy-beta-aarch64-unknown-linux-gnu.tar.xz=3325ddf5704811e48b1f50daea60961d18296ac1626e68828c9eb757e52cf65a
+dist/2025-06-24/clippy-beta-aarch64-unknown-linux-musl.tar.gz=471b5577f82ceb6a1a5c7e017526835643472a30d51ac023c7a758ec77166691
+dist/2025-06-24/clippy-beta-aarch64-unknown-linux-musl.tar.xz=9d5a3296f07ba65b576ca4d3de09d26b476b390b876dc8c8e4eac2fff1270cc8
+dist/2025-06-24/clippy-beta-arm-unknown-linux-gnueabi.tar.gz=d2e1316aec639089a7d18ce41a9eb9c21317e25ba06c20f0551675a8aeebea43
+dist/2025-06-24/clippy-beta-arm-unknown-linux-gnueabi.tar.xz=027deae3f2518ef33f41055a8a11ebc32697bb3499cad98ae89a05d9c5bb354b
+dist/2025-06-24/clippy-beta-arm-unknown-linux-gnueabihf.tar.gz=d041ee879d9489d4258541041478b3efd9c6a89dee97892378269cf2cd2896b5
+dist/2025-06-24/clippy-beta-arm-unknown-linux-gnueabihf.tar.xz=1f5a4a3cce223b750f271f1ab469939d00055795a752a0c88b1b49f00f2f42c0
+dist/2025-06-24/clippy-beta-armv7-unknown-linux-gnueabihf.tar.gz=acd1d67dfd4176d2fdec865b4027492f43be7aa1d0635e6777cc6862dd6e306c
+dist/2025-06-24/clippy-beta-armv7-unknown-linux-gnueabihf.tar.xz=e79ba7baa995f160561868fe221267b1b2f448a932b518fafb3afaaaa1028b44
+dist/2025-06-24/clippy-beta-i686-pc-windows-gnu.tar.gz=ee9c369d91d58aac3894a40500e0c8b0c4136a82cc39b2e44c9524a8c6e0d7ca
+dist/2025-06-24/clippy-beta-i686-pc-windows-gnu.tar.xz=ddee9ab89250fbfa7f45a5121cdad5cb1a2fcc010e4a5082392862f7c0033d45
+dist/2025-06-24/clippy-beta-i686-pc-windows-msvc.tar.gz=8ea4c8e4bb9ad9447cbf7c648f36378911d85985fcb5af13908a89180443cae0
+dist/2025-06-24/clippy-beta-i686-pc-windows-msvc.tar.xz=bd57be99cfa8eedd284d2bc93a5abf74368aae021e83a367e426e4be0193cbd2
+dist/2025-06-24/clippy-beta-i686-unknown-linux-gnu.tar.gz=973c76613f1d049708587b84006c408fd8c8d5cf308c572257e45b8e5e33bb4b
+dist/2025-06-24/clippy-beta-i686-unknown-linux-gnu.tar.xz=b84d9b6918e18540e3073d66e9bc02845257fe2f1a39c9e62b44e81f2aae341d
+dist/2025-06-24/clippy-beta-loongarch64-unknown-linux-gnu.tar.gz=dc4e842ce58fd07eb59cfdd870fa311f925e5efda1044bb51719bd250ff03cda
+dist/2025-06-24/clippy-beta-loongarch64-unknown-linux-gnu.tar.xz=332e8549d7bedf4f97dd9b1cb8a5af47fc56374438e8878ebad2593bd36a48b6
+dist/2025-06-24/clippy-beta-loongarch64-unknown-linux-musl.tar.gz=d8181ee683bdd6831af1d882247353d2731ee08ffc0443a9cce0f6da44fc6b0d
+dist/2025-06-24/clippy-beta-loongarch64-unknown-linux-musl.tar.xz=c7b0a21c55e36372cb1dabdacb58b45bd02827e08e6524dad97b74e6ed9de1c5
+dist/2025-06-24/clippy-beta-powerpc-unknown-linux-gnu.tar.gz=38f2a198a952bb7002fbea1ae9a12ffdfb54ec774e04848b7950bd13f17199de
+dist/2025-06-24/clippy-beta-powerpc-unknown-linux-gnu.tar.xz=b4f5e016c5035cd2b70d4e3fbdf1d0ebcd0d1cc6f1d297bc04f99581a02febc5
+dist/2025-06-24/clippy-beta-powerpc64-unknown-linux-gnu.tar.gz=1beac7db7663f460e548f0efe9ef1737d114c6b8aa56ec81e536e170c21231a7
+dist/2025-06-24/clippy-beta-powerpc64-unknown-linux-gnu.tar.xz=0dbcfc800635438f803888caaf37677b424ef5a90cab81ceaac627bba7faf6b5
+dist/2025-06-24/clippy-beta-powerpc64le-unknown-linux-gnu.tar.gz=8c0dd34227e9b7a44ae8ed96be4110e10c01eafd46a7d050ab0121ca80f4fe09
+dist/2025-06-24/clippy-beta-powerpc64le-unknown-linux-gnu.tar.xz=7a56be9e5d58dbd2531d8c049fada5bdff5d98436afb63b92ddfc5f58d5835f9
+dist/2025-06-24/clippy-beta-powerpc64le-unknown-linux-musl.tar.gz=6bf5ed0793c38fed42974f8d0ae9442b926ac1072b3af08f97effbf32c5dfa54
+dist/2025-06-24/clippy-beta-powerpc64le-unknown-linux-musl.tar.xz=79adc7bbc8e4623c333ad3600305fce3c34fd35dcb026a654648707eef87cc6b
+dist/2025-06-24/clippy-beta-riscv64gc-unknown-linux-gnu.tar.gz=1f881bf6585354c5abadf2e7f8ba50247b47de0c317ab61cfcc550cb6755de6a
+dist/2025-06-24/clippy-beta-riscv64gc-unknown-linux-gnu.tar.xz=dcfa6d2fcfb96aed0ce6df6bf53cb8cdfe8529fb361cfaa78b92fc8773cc7446
+dist/2025-06-24/clippy-beta-s390x-unknown-linux-gnu.tar.gz=307884da83f8b77d2bde49a522d586e22c95febaca197d95380c7d60393ca948
+dist/2025-06-24/clippy-beta-s390x-unknown-linux-gnu.tar.xz=46db14272bd41ec2b89d146f8d200cf21b12bdb1183fbc303f8e8cebdf11080e
+dist/2025-06-24/clippy-beta-sparcv9-sun-solaris.tar.gz=09fcd95262f04a5e858baf04f47dc02632cd6860a9e747daf78fe1aaf787153c
+dist/2025-06-24/clippy-beta-sparcv9-sun-solaris.tar.xz=28905a71542485498261529d8cc4a2a47ebca4a9bbc8a2ffb22dc3ebb5ac96c6
+dist/2025-06-24/clippy-beta-x86_64-apple-darwin.tar.gz=884844e318557cfe8a2175795ffad57919eb88c3d5246893e47fdb0db6ff9046
+dist/2025-06-24/clippy-beta-x86_64-apple-darwin.tar.xz=4b8594e3f2945857c4316fa7a46eb8d8ad025ae9b87af58fbb7b6913f843b48a
+dist/2025-06-24/clippy-beta-x86_64-pc-solaris.tar.gz=04a12879eb1fea5b646dfedda6f25bb349b1096d753137e41543f20bece4b6f8
+dist/2025-06-24/clippy-beta-x86_64-pc-solaris.tar.xz=4f3323454f0c53868637d98dae2d237b1d16857b18e8db40884e7c550ee1ca3e
+dist/2025-06-24/clippy-beta-x86_64-pc-windows-gnu.tar.gz=81eca7c5978dff34526a1e3921e42785190efe0e5064e006c677b82b6cab783d
+dist/2025-06-24/clippy-beta-x86_64-pc-windows-gnu.tar.xz=3f3fae70db224b98aa6d9ce38f35c31bccfecceb1c6111bf928008a545e93b48
+dist/2025-06-24/clippy-beta-x86_64-pc-windows-msvc.tar.gz=48ece2ad4610148df4dbf6c78c81c56eb66d3d3e9a8c08b8bec76b0abf640983
+dist/2025-06-24/clippy-beta-x86_64-pc-windows-msvc.tar.xz=b37de86534a8655cb41fac60c920d49ab3880b1ac4aeec124711fdeffb025052
+dist/2025-06-24/clippy-beta-x86_64-unknown-freebsd.tar.gz=140c8f99e13ec96256bbd50af6e8e3786885d718cdedadc2b2dc1d82cb3e5ab9
+dist/2025-06-24/clippy-beta-x86_64-unknown-freebsd.tar.xz=6f306a3fd1a920931393081ee431c7ab37f589bf7a449d36892e6b5945a71d80
+dist/2025-06-24/clippy-beta-x86_64-unknown-illumos.tar.gz=9faab86392b6d1ab0579f5ce61d94e2998357d2c8d82cb441d7a718ce52dd1a4
+dist/2025-06-24/clippy-beta-x86_64-unknown-illumos.tar.xz=ea03c88713cbe937d963a4f18e0cd5015aa2e5151e66cb3cb24eec76b56c4023
+dist/2025-06-24/clippy-beta-x86_64-unknown-linux-gnu.tar.gz=13fd137434d475440beae2ad047b58853e54d1063396ecaadae316fe81d761ab
+dist/2025-06-24/clippy-beta-x86_64-unknown-linux-gnu.tar.xz=c3b96035b40c01c23256ad5b4c2ba876e84e8bc5cfdc6c14cfc9d4eaf57fd74b
+dist/2025-06-24/clippy-beta-x86_64-unknown-linux-musl.tar.gz=2af28e2a0c1b8c6c41842b420251375dd2cd24a51cc0cfaf2de4bf3d49612a76
+dist/2025-06-24/clippy-beta-x86_64-unknown-linux-musl.tar.xz=e18561036958432a47c94c1b32202a3f843bf01b7a1edd61e51b835bee83d611
+dist/2025-06-24/clippy-beta-x86_64-unknown-netbsd.tar.gz=75ea015d2b9148d77ef7e060bee4b190cc73e7b117420f60abc77aac2a2aec7e
+dist/2025-06-24/clippy-beta-x86_64-unknown-netbsd.tar.xz=0282575f3ea1476994940e0a97a5720bf4452be01e0360cab58eec12c0480699
+dist/2025-06-24/rustfmt-nightly-aarch64-apple-darwin.tar.gz=3432f8489fe400b73d3cb01e4e49fc3305a0e5207e81a88a6f28eeb189b889b3
+dist/2025-06-24/rustfmt-nightly-aarch64-apple-darwin.tar.xz=62fbf75889736832087badca386546bce580601d8a396be707ccab1c77fc8ad1
+dist/2025-06-24/rustfmt-nightly-aarch64-pc-windows-msvc.tar.gz=0b50197c8e1b988d1cf6bbeef055bfdce5b01efc07742ee85221c57b2d70e33e
+dist/2025-06-24/rustfmt-nightly-aarch64-pc-windows-msvc.tar.xz=c555acf28f160f9b133c4e196305ac9e0f5b528a683690ea6980a457b3cd4184
+dist/2025-06-24/rustfmt-nightly-aarch64-unknown-linux-gnu.tar.gz=54b7acb5fcedd0fb50161acf1977e62904cf55a74f98e8530f64b5459a7f04ec
+dist/2025-06-24/rustfmt-nightly-aarch64-unknown-linux-gnu.tar.xz=a96e42605d11c5220a0de5164f32522c884c61782075933f1e6eaab1bb4a41f4
+dist/2025-06-24/rustfmt-nightly-aarch64-unknown-linux-musl.tar.gz=d4b7d8e5fac122215f6d75654b9a60ddfd8057818ad5bff945a7823bfa17354e
+dist/2025-06-24/rustfmt-nightly-aarch64-unknown-linux-musl.tar.xz=8cc5a0760dea509e435c0185f4c5a4a8d64515fb280808d18cc77d96632b4479
+dist/2025-06-24/rustfmt-nightly-arm-unknown-linux-gnueabi.tar.gz=c0bd020fdcc8eed3b34ee7aa12181c56197df339fd84b1cda5386e4848c0b0aa
+dist/2025-06-24/rustfmt-nightly-arm-unknown-linux-gnueabi.tar.xz=eb521c9a78be2c814b76910dfeb8dcf233a9e1076c655f3c682f5b79fd1ec4c6
+dist/2025-06-24/rustfmt-nightly-arm-unknown-linux-gnueabihf.tar.gz=34a4b7f51c39e5b41496f085d85396ea3f95384315c0e184dc78da3f75c3478d
+dist/2025-06-24/rustfmt-nightly-arm-unknown-linux-gnueabihf.tar.xz=a9da4962599db3fce8d5e31b0aeff681a05198d32838e9844b49de12af88217e
+dist/2025-06-24/rustfmt-nightly-armv7-unknown-linux-gnueabihf.tar.gz=27dab44d55602c98447d93a9f0e566e8f772c97c8322a7cb54144f9b6b29af71
+dist/2025-06-24/rustfmt-nightly-armv7-unknown-linux-gnueabihf.tar.xz=1598d5d8612de93539b36e1a421b5f1ce97a71eee8a5a9ee85aa6e8e9d778fca
+dist/2025-06-24/rustfmt-nightly-i686-pc-windows-gnu.tar.gz=a62d2f370fd9aa99152d66c0ce49ed2595f8e48b4ee40a95271bbd7a584410b3
+dist/2025-06-24/rustfmt-nightly-i686-pc-windows-gnu.tar.xz=e0378cd9afc1a9e6b6665b98a3a2c089e42bda56a855cd1d2011c14bc75e6886
+dist/2025-06-24/rustfmt-nightly-i686-pc-windows-msvc.tar.gz=f316d4b45a2d454ca2bac683d470794c80db84fcf6f809c20b11333035d6f2ab
+dist/2025-06-24/rustfmt-nightly-i686-pc-windows-msvc.tar.xz=6e73b85d0fb10b77646db2cdc2ad236a8a5d0ed71761e171b00ddfa6b6d7cd83
+dist/2025-06-24/rustfmt-nightly-i686-unknown-linux-gnu.tar.gz=034eb9ed25935694ee0c530bb58bb0dd5586d7361f1f1356fb67af5e5c440c62
+dist/2025-06-24/rustfmt-nightly-i686-unknown-linux-gnu.tar.xz=0873543b725aa062f2c6dd00f2be3ea66dad56bfa2a25251f92c0d8b495eb9b7
+dist/2025-06-24/rustfmt-nightly-loongarch64-unknown-linux-gnu.tar.gz=7cd21e55b12d13de4f6a7678e89141476dc96523f91622da662672e3b967547a
+dist/2025-06-24/rustfmt-nightly-loongarch64-unknown-linux-gnu.tar.xz=08c9a5e50cd50c2a5676ee49fbcb7b2a622c7823dd787f79ab1feee38ade84f9
+dist/2025-06-24/rustfmt-nightly-loongarch64-unknown-linux-musl.tar.gz=3e7ebe2cbd951ab9c9b4863aecaaf18ee09c200a1d58430d1bd6be788ac7c311
+dist/2025-06-24/rustfmt-nightly-loongarch64-unknown-linux-musl.tar.xz=76d79e2f26c19678a8191295563abc34c99ef971fd795cab8b690abb6afcc46a
+dist/2025-06-24/rustfmt-nightly-powerpc-unknown-linux-gnu.tar.gz=7f29b3b39f0d49fc6033006d8ff72fd9bf64ccdb9865f3654d06db46a62170d8
+dist/2025-06-24/rustfmt-nightly-powerpc-unknown-linux-gnu.tar.xz=25e85b3608dd57fb997f58d0bd626d1148eacd51fcc62066c3dae2b4edf475fe
+dist/2025-06-24/rustfmt-nightly-powerpc64-unknown-linux-gnu.tar.gz=2c6c869cdd36dbedcf8ec6b803f1cf737c2ef159ab0c7bad57f9fc1a9bbc944f
+dist/2025-06-24/rustfmt-nightly-powerpc64-unknown-linux-gnu.tar.xz=2a6135517dea234a8cf1e1bc503133b232f053e6043818ea11a38a9133742a50
+dist/2025-06-24/rustfmt-nightly-powerpc64le-unknown-linux-gnu.tar.gz=cd9957ba8ceee1cbbfc64c7d336cd14cf86d80d4e2f292300f1693b7f333c8c3
+dist/2025-06-24/rustfmt-nightly-powerpc64le-unknown-linux-gnu.tar.xz=002a7a3286cb9794d6d9b4a4ad711ddb83cda8acc5150ed82ceedc04861a19a2
+dist/2025-06-24/rustfmt-nightly-powerpc64le-unknown-linux-musl.tar.gz=1a905ec7b06ac868f448ebf96c8ace4397e65a040c3c284b37446f95a2004bcc
+dist/2025-06-24/rustfmt-nightly-powerpc64le-unknown-linux-musl.tar.xz=2f3ed860d7c5416a8ce8e7a9fbf3435d34653692adc153054af0044a3bc544d7
+dist/2025-06-24/rustfmt-nightly-riscv64gc-unknown-linux-gnu.tar.gz=f2eaf7ae2de5bc3b1c66944cfe145c5005bbdfaa7f395751863eb62650cf6f80
+dist/2025-06-24/rustfmt-nightly-riscv64gc-unknown-linux-gnu.tar.xz=4f646fe74c3a155837f2febdc720586a6bd03ebe93b130d042c4061012c36c62
+dist/2025-06-24/rustfmt-nightly-s390x-unknown-linux-gnu.tar.gz=cfea8bd86d79dd10200c80debd7b0a67c2f9e15aa32bbe293305b4cb1d4c140b
+dist/2025-06-24/rustfmt-nightly-s390x-unknown-linux-gnu.tar.xz=82dc1b9dcbc2a16948c73aa11fa7faaa1cc156c70811a76c9ae6bae87527cf05
+dist/2025-06-24/rustfmt-nightly-sparcv9-sun-solaris.tar.gz=1c78e4dcda6625502ea55945e60c489afb321c015b4d5bf98f16df36e363c5e1
+dist/2025-06-24/rustfmt-nightly-sparcv9-sun-solaris.tar.xz=90d072b9f5e23252ff98808f878718dc0eafbd2f379c33814cf355bf824b91bf
+dist/2025-06-24/rustfmt-nightly-x86_64-apple-darwin.tar.gz=fbc0a4f9b03caf6cef7b3b44f45e952b5f2386dabe27f6f57bb1d5a07e92b679
+dist/2025-06-24/rustfmt-nightly-x86_64-apple-darwin.tar.xz=334563dd55124add3f08e5ad0360870f7dacf643a2db10842da629e7b82d844b
+dist/2025-06-24/rustfmt-nightly-x86_64-pc-solaris.tar.gz=70a974c74c4bbf14ad52dd91feba8adcc7821e650e78beb46f375fb23519d433
+dist/2025-06-24/rustfmt-nightly-x86_64-pc-solaris.tar.xz=851b15e50d9b02518bd82f4269d80c31eee4f5559a5c871af013272e9f6e68a8
+dist/2025-06-24/rustfmt-nightly-x86_64-pc-windows-gnu.tar.gz=5608ac9918b30cf05ad1110a7a2da3f051fb97da630a6ce34ddb02927e6dcff2
+dist/2025-06-24/rustfmt-nightly-x86_64-pc-windows-gnu.tar.xz=8fcb4f2159189af9d94253c1b92034f8fd18d2dbe6c2c72b172fefb6acd1bab7
+dist/2025-06-24/rustfmt-nightly-x86_64-pc-windows-msvc.tar.gz=e2e85fa9b30cea48a5ed0dbeee8a14dea4c16b31208fb1b884e4c1253bcc20fe
+dist/2025-06-24/rustfmt-nightly-x86_64-pc-windows-msvc.tar.xz=cf11c5776728edf90ef7fec81f7f46d5edfa4d827629346f1b8cd1e00fb9b1c0
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-freebsd.tar.gz=5f8befb9ef7640b75d9c29955f3ced2a128015ca1f39bd24aab2ef2587a5fb99
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-freebsd.tar.xz=2a09a48f979bf762d465704bbb4f90cc1bf6b10a1d8b75434370b38dba91e62d
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-illumos.tar.gz=e0be33a6c1272d885939469354e9d8a670a370408c2c3f1b095a9f36de514849
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-illumos.tar.xz=9ac7896342c3a2411b3dd68984c6a94d8cec52852c551745c363552e54767fb6
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-linux-gnu.tar.gz=4adfe1a8ed77ee7f7aa17f4181e87f59482f7345735c939d181e86870ad4edef
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-linux-gnu.tar.xz=df97ab0f9a090b3a01b089ba8b259333c3e0cdc34a2cfb1f91d204a279b60783
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-linux-musl.tar.gz=ec13df06afe80f82ac7af36fb76461712ca6a5993a3935966c9dec9a9af15b74
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-linux-musl.tar.xz=db58fe88b3795306f08afc79b676c92397cbb5f49a934f764eab490826788ff5
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-netbsd.tar.gz=23f7bd79106676c6a26828e663a51b4c1450fd1097b684735a46ead2ff54a57c
+dist/2025-06-24/rustfmt-nightly-x86_64-unknown-netbsd.tar.xz=d294f8ed438c068b6792f7ccdecf9716e08b927249728f4aac7064b983e71e5c
+dist/2025-06-24/rustc-nightly-aarch64-apple-darwin.tar.gz=1f6dfb2fd4ef09e0889589747d239b5e1af57feb859d89efed7d30b9afc3e8e6
+dist/2025-06-24/rustc-nightly-aarch64-apple-darwin.tar.xz=1fcd2e30508b664208c236ff3b522a62c385197c9af4131b060d10b5a5b89d20
+dist/2025-06-24/rustc-nightly-aarch64-pc-windows-msvc.tar.gz=f0ddd8c974d8a0022260a193e16c045334c0526328604a4ad26b9efe6953de4a
+dist/2025-06-24/rustc-nightly-aarch64-pc-windows-msvc.tar.xz=9274d4b17011713f9a7b050e89ef7626b8d24300456463d1c7d7a65f8be54039
+dist/2025-06-24/rustc-nightly-aarch64-unknown-linux-gnu.tar.gz=4155841d5101c2f7b65282c4b5b33146acfe1bffcf2c68d48c5b4ca31d73b663
+dist/2025-06-24/rustc-nightly-aarch64-unknown-linux-gnu.tar.xz=3547deb9ca8fcd638b0c17f9e3848034d4b9dc2a859581932e95344715058b21
+dist/2025-06-24/rustc-nightly-aarch64-unknown-linux-musl.tar.gz=b63dcf52528338728f5a29b51f7f38f99999fec061b2b9bd789e456cff0a16bf
+dist/2025-06-24/rustc-nightly-aarch64-unknown-linux-musl.tar.xz=e77030ec0dfefa9ea571483c10a590c5d58f084fc8ce3e10031ce9cf503e9675
+dist/2025-06-24/rustc-nightly-arm-unknown-linux-gnueabi.tar.gz=a1da6251ad4cf9710382bb871d9400c0886fb17b2790477c4c2933c97bd1552e
+dist/2025-06-24/rustc-nightly-arm-unknown-linux-gnueabi.tar.xz=96051a8bb8c0fc377d8fe8af861398c39bc21edd6e808977d728eddf6393ab8c
+dist/2025-06-24/rustc-nightly-arm-unknown-linux-gnueabihf.tar.gz=fcb7eda9e1060cf4c4c702681d0a0ab6680f0e1875a7e0da2bde01f6b018e834
+dist/2025-06-24/rustc-nightly-arm-unknown-linux-gnueabihf.tar.xz=56217f3b73e8cbae769a0a20d2a01e1f2d474c67bc10f93e1a9f7c2d51da0ac1
+dist/2025-06-24/rustc-nightly-armv7-unknown-linux-gnueabihf.tar.gz=c02e586ee5732d8b89f4262333de9444f0cd48b897a51e8767e505abfe54921f
+dist/2025-06-24/rustc-nightly-armv7-unknown-linux-gnueabihf.tar.xz=4d0eda5553deea639d39d2ad663d6f077b14f7216b99268bd787196475fd1205
+dist/2025-06-24/rustc-nightly-i686-pc-windows-gnu.tar.gz=1e9acd43dae9e1a199c96e6842869e1f3418d0167f93f9220fd937ee63363645
+dist/2025-06-24/rustc-nightly-i686-pc-windows-gnu.tar.xz=5e12380c2c8d2ec40ac8e6141c9ef9c9430928fcf2491bb46e27ca6529b7a779
+dist/2025-06-24/rustc-nightly-i686-pc-windows-msvc.tar.gz=fcba4f7b348d06d5ac602111a53de9767d394298eeebde41200780e73bb39c93
+dist/2025-06-24/rustc-nightly-i686-pc-windows-msvc.tar.xz=ce2b140a46faa99a96f9c02fa44481f6414e1d4bed94015dcc773a07b133e39b
+dist/2025-06-24/rustc-nightly-i686-unknown-linux-gnu.tar.gz=eb57e8444762b11f88aac3217807c976a87e22dfdccb790c7ed1c30c445c033f
+dist/2025-06-24/rustc-nightly-i686-unknown-linux-gnu.tar.xz=b0395824f59a07c311ecdef0cd54a2734eb84a7a817561eb157ab66f5b46b9be
+dist/2025-06-24/rustc-nightly-loongarch64-unknown-linux-gnu.tar.gz=cd512e558d3cb27913cf79a188529d953b770452a3ec11d63c843424ddd04e6b
+dist/2025-06-24/rustc-nightly-loongarch64-unknown-linux-gnu.tar.xz=8fb1c1c32ccc3b62f100dbfa151c70e86de571adcf215d978e0fbcf80448a555
+dist/2025-06-24/rustc-nightly-loongarch64-unknown-linux-musl.tar.gz=ec39e3ed4f93d4ce31c748b2109e921065106ff850540bfbd4584ada5c296b83
+dist/2025-06-24/rustc-nightly-loongarch64-unknown-linux-musl.tar.xz=600c2457caf6ae99502e96e2ad6021628611e4feea6e8498178e257fe4e3bf8a
+dist/2025-06-24/rustc-nightly-powerpc-unknown-linux-gnu.tar.gz=6a91c5f05a167ffb7c32aa719422e816e592fcbc3f6da1d77e15df1360888133
+dist/2025-06-24/rustc-nightly-powerpc-unknown-linux-gnu.tar.xz=b8e935a3715139bc2d5fe89f08c8e2c7bf5e5cbe3ce555e0c6306bd4fc0d5c37
+dist/2025-06-24/rustc-nightly-powerpc64-unknown-linux-gnu.tar.gz=fc50b819def6bec22245776b01b1332086604a04170951a43713286c88a8ab06
+dist/2025-06-24/rustc-nightly-powerpc64-unknown-linux-gnu.tar.xz=07c23da71f7330c19cffb16866702341dab46a7cd3151b054a3020e16a72ef70
+dist/2025-06-24/rustc-nightly-powerpc64le-unknown-linux-gnu.tar.gz=b8c5f9a1868f6ef86630eab919aad9a8cbcec274badd85412d7a807d4539b648
+dist/2025-06-24/rustc-nightly-powerpc64le-unknown-linux-gnu.tar.xz=b555f6f3e5340a79766b652c686973d827a5e18676c2204880bfa76bd9b18379
+dist/2025-06-24/rustc-nightly-powerpc64le-unknown-linux-musl.tar.gz=78c4e13ec693969eef566a69845e167c881a2e3f1c668abe98511dc4e7ca4ce1
+dist/2025-06-24/rustc-nightly-powerpc64le-unknown-linux-musl.tar.xz=a4d67c535d135fc180a7cda7b012d67ed7b315aea2dacf875ece0d1364a573ff
+dist/2025-06-24/rustc-nightly-riscv64gc-unknown-linux-gnu.tar.gz=dda2348abc72eec12707421751185c6d90e8751aed4e8b36df01becdce35ab24
+dist/2025-06-24/rustc-nightly-riscv64gc-unknown-linux-gnu.tar.xz=03fa26da35f92d2f1833e06da81fb0ccdf60feeab5189ffe789e81afa93fcfbb
+dist/2025-06-24/rustc-nightly-s390x-unknown-linux-gnu.tar.gz=6e12884335ab012c78a4f672e143303cbda142a728a8379eedec97fba76f0f0c
+dist/2025-06-24/rustc-nightly-s390x-unknown-linux-gnu.tar.xz=e235dd111abe60b11ab020618a5eddbcdc105c8ea63f91c886972d6298b38512
+dist/2025-06-24/rustc-nightly-sparcv9-sun-solaris.tar.gz=53fc8dfc78e01dfef45bdb840cfd46acbca64a6177448f47d8fce52db6eef224
+dist/2025-06-24/rustc-nightly-sparcv9-sun-solaris.tar.xz=99eb657c275896295e2dac5868a7209de64ea9edb951a4bbf1336afb105bb6e7
+dist/2025-06-24/rustc-nightly-x86_64-apple-darwin.tar.gz=3d08912e28645fef5177ded3979abd93b8d2c2f1b391035b4709f0411180d772
+dist/2025-06-24/rustc-nightly-x86_64-apple-darwin.tar.xz=ec77aa5e779fa33e21b39501e19c9ae4be2b3fceb31372b571da7e55ed6e5493
+dist/2025-06-24/rustc-nightly-x86_64-pc-solaris.tar.gz=3e6639d90cb9f79d3d7e484f127b9d2074163eb6d6b82ee8d05c025380677afc
+dist/2025-06-24/rustc-nightly-x86_64-pc-solaris.tar.xz=7bc1294b1362773428bdb2604033658af83c9af75a4d986106d950fe2a6e7259
+dist/2025-06-24/rustc-nightly-x86_64-pc-windows-gnu.tar.gz=71d2ae019fb18e7b592a5a89e79256fd6cd77f594a8272a2d906ee0ad6a7c314
+dist/2025-06-24/rustc-nightly-x86_64-pc-windows-gnu.tar.xz=8592859eaf1453b98ff0d66e78bcc4507727df8b74e8019620f51ce61e2f0359
+dist/2025-06-24/rustc-nightly-x86_64-pc-windows-msvc.tar.gz=e85a7fdff5a848371da8ead8aa476e0bb966bbe7fa75f4fadea793a417ee2fd5
+dist/2025-06-24/rustc-nightly-x86_64-pc-windows-msvc.tar.xz=98ec37c80995927851cf2b4a47d520b2ee2a4431b0e31c117bc8df8dba813b15
+dist/2025-06-24/rustc-nightly-x86_64-unknown-freebsd.tar.gz=47885c0006351251d9db998bc8367d4ea59aa33798e35c40aad6dd804b057362
+dist/2025-06-24/rustc-nightly-x86_64-unknown-freebsd.tar.xz=8976ecfc666cdb9624b470e8f6d3fd6231d7e949663bea928775308ae89ae8c3
+dist/2025-06-24/rustc-nightly-x86_64-unknown-illumos.tar.gz=98b8058dbe9a783b4aa73678bb7efda29a5c13eefe332c873d265805eb9c7a4f
+dist/2025-06-24/rustc-nightly-x86_64-unknown-illumos.tar.xz=30abf5c4c71353451a6c23fa02a9160b1d65fb5946e2166a5b3c5c77e9905906
+dist/2025-06-24/rustc-nightly-x86_64-unknown-linux-gnu.tar.gz=eeed224afbd20219b4f19c4a31f9cdcf9672af7d20ec3cd688d02764404f7cdc
+dist/2025-06-24/rustc-nightly-x86_64-unknown-linux-gnu.tar.xz=01e1f185c4a0c18b256b4d13e1eb8aff312a6969f630ce70411367454642fe4e
+dist/2025-06-24/rustc-nightly-x86_64-unknown-linux-musl.tar.gz=4c57c6805d18f1bc53acce957c0b1279a1b0894efcf0f24c744b3765a82c59fd
+dist/2025-06-24/rustc-nightly-x86_64-unknown-linux-musl.tar.xz=3da2e26f0fb0a94e3caac0385c82eab54e553eb9759723dfd601f5dc25a87906
+dist/2025-06-24/rustc-nightly-x86_64-unknown-netbsd.tar.gz=a1b2db0321e9b22c11eb0ae1a6ed052917600bbe18b46bf732fdb20a60cc0950
+dist/2025-06-24/rustc-nightly-x86_64-unknown-netbsd.tar.xz=306d96754bdfdadd4d1c2dd303f5db06f3e405b343210209c256d1b1862d47a5
diff --git a/src/tools/clippy/clippy_lints/src/approx_const.rs b/src/tools/clippy/clippy_lints/src/approx_const.rs
index 852e48c..5ed4c82 100644
--- a/src/tools/clippy/clippy_lints/src/approx_const.rs
+++ b/src/tools/clippy/clippy_lints/src/approx_const.rs
@@ -74,7 +74,7 @@ pub fn new(conf: &'static Conf) -> Self {
 }
 
 impl LateLintPass<'_> for ApproxConstant {
-    fn check_lit(&mut self, cx: &LateContext<'_>, _hir_id: HirId, lit: &Lit, _negated: bool) {
+    fn check_lit(&mut self, cx: &LateContext<'_>, _hir_id: HirId, lit: Lit, _negated: bool) {
         match lit.node {
             LitKind::Float(s, LitFloatType::Suffixed(fty)) => match fty {
                 FloatTy::F16 => self.check_known_consts(cx, lit.span, s, "f16"),
diff --git a/src/tools/clippy/clippy_lints/src/bool_assert_comparison.rs b/src/tools/clippy/clippy_lints/src/bool_assert_comparison.rs
index 8f95e44..581fe33 100644
--- a/src/tools/clippy/clippy_lints/src/bool_assert_comparison.rs
+++ b/src/tools/clippy/clippy_lints/src/bool_assert_comparison.rs
@@ -42,7 +42,7 @@ fn extract_bool_lit(e: &Expr<'_>) -> Option<bool> {
     }) = e.kind
         && !e.span.from_expansion()
     {
-        Some(*b)
+        Some(b)
     } else {
         None
     }
diff --git a/src/tools/clippy/clippy_lints/src/casts/manual_dangling_ptr.rs b/src/tools/clippy/clippy_lints/src/casts/manual_dangling_ptr.rs
index d9e88d6..92910cf 100644
--- a/src/tools/clippy/clippy_lints/src/casts/manual_dangling_ptr.rs
+++ b/src/tools/clippy/clippy_lints/src/casts/manual_dangling_ptr.rs
@@ -46,7 +46,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &Expr<'_>, from: &Expr<'_>, to:
 fn is_expr_const_aligned(cx: &LateContext<'_>, expr: &Expr<'_>, to: &Ty<'_>) -> bool {
     match expr.kind {
         ExprKind::Call(fun, _) => is_align_of_call(cx, fun, to),
-        ExprKind::Lit(lit) => is_literal_aligned(cx, lit, to),
+        ExprKind::Lit(lit) => is_literal_aligned(cx, &lit, to),
         _ => false,
     }
 }
diff --git a/src/tools/clippy/clippy_lints/src/casts/unnecessary_cast.rs b/src/tools/clippy/clippy_lints/src/casts/unnecessary_cast.rs
index 010f09d..c88a053 100644
--- a/src/tools/clippy/clippy_lints/src/casts/unnecessary_cast.rs
+++ b/src/tools/clippy/clippy_lints/src/casts/unnecessary_cast.rs
@@ -243,7 +243,7 @@ fn lint_unnecessary_cast(
     );
 }
 
-fn get_numeric_literal<'e>(expr: &'e Expr<'e>) -> Option<&'e Lit> {
+fn get_numeric_literal<'e>(expr: &'e Expr<'e>) -> Option<Lit> {
     match expr.kind {
         ExprKind::Lit(lit) => Some(lit),
         ExprKind::Unary(UnOp::Neg, e) => {
diff --git a/src/tools/clippy/clippy_lints/src/default_numeric_fallback.rs b/src/tools/clippy/clippy_lints/src/default_numeric_fallback.rs
index 784214c..1507f1e 100644
--- a/src/tools/clippy/clippy_lints/src/default_numeric_fallback.rs
+++ b/src/tools/clippy/clippy_lints/src/default_numeric_fallback.rs
@@ -83,7 +83,7 @@ fn new(cx: &'a LateContext<'tcx>, is_parent_const: bool) -> Self {
     }
 
     /// Check whether a passed literal has potential to cause fallback or not.
-    fn check_lit(&self, lit: &Lit, lit_ty: Ty<'tcx>, emit_hir_id: HirId) {
+    fn check_lit(&self, lit: Lit, lit_ty: Ty<'tcx>, emit_hir_id: HirId) {
         if !lit.span.in_external_macro(self.cx.sess().source_map())
             && matches!(self.ty_bounds.last(), Some(ExplicitTyBound(false)))
             && matches!(
@@ -210,7 +210,7 @@ fn visit_expr(&mut self, expr: &'tcx Expr<'_>) {
 
             ExprKind::Lit(lit) => {
                 let ty = self.cx.typeck_results().expr_ty(expr);
-                self.check_lit(lit, ty, expr.hir_id);
+                self.check_lit(*lit, ty, expr.hir_id);
                 return;
             },
 
diff --git a/src/tools/clippy/clippy_lints/src/large_include_file.rs b/src/tools/clippy/clippy_lints/src/large_include_file.rs
index 621a2af..8707612 100644
--- a/src/tools/clippy/clippy_lints/src/large_include_file.rs
+++ b/src/tools/clippy/clippy_lints/src/large_include_file.rs
@@ -57,7 +57,7 @@ fn check_expr(&mut self, cx: &LateContext<'_>, expr: &'_ Expr<'_>) {
         if let ExprKind::Lit(lit) = &expr.kind
             && let len = match &lit.node {
                 // include_bytes
-                LitKind::ByteStr(bstr, _) => bstr.len(),
+                LitKind::ByteStr(bstr, _) => bstr.as_byte_str().len(),
                 // include_str
                 LitKind::Str(sym, _) => sym.as_str().len(),
                 _ => return,
diff --git a/src/tools/clippy/clippy_lints/src/manual_ignore_case_cmp.rs b/src/tools/clippy/clippy_lints/src/manual_ignore_case_cmp.rs
index 57c03fb..f7d9ec1 100644
--- a/src/tools/clippy/clippy_lints/src/manual_ignore_case_cmp.rs
+++ b/src/tools/clippy/clippy_lints/src/manual_ignore_case_cmp.rs
@@ -41,12 +41,12 @@
 
 declare_lint_pass!(ManualIgnoreCaseCmp => [MANUAL_IGNORE_CASE_CMP]);
 
-enum MatchType<'a, 'b> {
+enum MatchType<'a> {
     ToAscii(bool, Ty<'a>),
-    Literal(&'b LitKind),
+    Literal(LitKind),
 }
 
-fn get_ascii_type<'a, 'b>(cx: &LateContext<'a>, kind: rustc_hir::ExprKind<'b>) -> Option<(Span, MatchType<'a, 'b>)> {
+fn get_ascii_type<'a>(cx: &LateContext<'a>, kind: rustc_hir::ExprKind<'_>) -> Option<(Span, MatchType<'a>)> {
     if let MethodCall(path, expr, _, _) = kind {
         let is_lower = match path.ident.name {
             sym::to_ascii_lowercase => true,
@@ -63,7 +63,7 @@ fn get_ascii_type<'a, 'b>(cx: &LateContext<'a>, kind: rustc_hir::ExprKind<'b>) -
             return Some((expr.span, ToAscii(is_lower, ty_raw)));
         }
     } else if let Lit(expr) = kind {
-        return Some((expr.span, Literal(&expr.node)));
+        return Some((expr.span, Literal(expr.node)));
     }
     None
 }
diff --git a/src/tools/clippy/clippy_lints/src/manual_strip.rs b/src/tools/clippy/clippy_lints/src/manual_strip.rs
index 9e911e6..6bf43a1 100644
--- a/src/tools/clippy/clippy_lints/src/manual_strip.rs
+++ b/src/tools/clippy/clippy_lints/src/manual_strip.rs
@@ -184,7 +184,7 @@ fn eq_pattern_length<'tcx>(cx: &LateContext<'tcx>, pattern: &Expr<'_>, expr: &'t
         ..
     }) = expr.kind
     {
-        constant_length(cx, pattern).is_some_and(|length| *n == length)
+        constant_length(cx, pattern).is_some_and(|length| n == length)
     } else {
         len_arg(cx, expr).is_some_and(|arg| eq_expr_value(cx, pattern, arg))
     }
diff --git a/src/tools/clippy/clippy_lints/src/matches/match_like_matches.rs b/src/tools/clippy/clippy_lints/src/matches/match_like_matches.rs
index f14b69d..5816da5 100644
--- a/src/tools/clippy/clippy_lints/src/matches/match_like_matches.rs
+++ b/src/tools/clippy/clippy_lints/src/matches/match_like_matches.rs
@@ -159,7 +159,7 @@ fn find_bool_lit(ex: &ExprKind<'_>) -> Option<bool> {
                 node: LitKind::Bool(b), ..
             }) = exp.kind
             {
-                Some(*b)
+                Some(b)
             } else {
                 None
             }
diff --git a/src/tools/clippy/clippy_lints/src/matches/match_same_arms.rs b/src/tools/clippy/clippy_lints/src/matches/match_same_arms.rs
index dbb29ee..ede68f3 100644
--- a/src/tools/clippy/clippy_lints/src/matches/match_same_arms.rs
+++ b/src/tools/clippy/clippy_lints/src/matches/match_same_arms.rs
@@ -12,7 +12,7 @@
 use rustc_lint::builtin::NON_EXHAUSTIVE_OMITTED_PATTERNS;
 use rustc_lint::{LateContext, LintContext};
 use rustc_middle::ty;
-use rustc_span::{ErrorGuaranteed, Span, Symbol};
+use rustc_span::{ByteSymbol, ErrorGuaranteed, Span, Symbol};
 
 use super::MATCH_SAME_ARMS;
 
@@ -193,7 +193,7 @@ enum NormalizedPat<'a> {
     Or(&'a [Self]),
     Path(Option<DefId>),
     LitStr(Symbol),
-    LitBytes(&'a [u8]),
+    LitBytes(ByteSymbol),
     LitInt(u128),
     LitBool(bool),
     Range(PatRange),
@@ -332,7 +332,9 @@ fn from_pat(cx: &LateContext<'_>, arena: &'a DroplessArena, pat: &'a Pat<'_>) ->
                 // TODO: Handle negative integers. They're currently treated as a wild match.
                 PatExprKind::Lit { lit, negated: false } => match lit.node {
                     LitKind::Str(sym, _) => Self::LitStr(sym),
-                    LitKind::ByteStr(ref bytes, _) | LitKind::CStr(ref bytes, _) => Self::LitBytes(bytes),
+                    LitKind::ByteStr(byte_sym, _) | LitKind::CStr(byte_sym, _) => {
+                        Self::LitBytes(byte_sym)
+                    }
                     LitKind::Byte(val) => Self::LitInt(val.into()),
                     LitKind::Char(val) => Self::LitInt(val.into()),
                     LitKind::Int(val, _) => Self::LitInt(val.get()),
diff --git a/src/tools/clippy/clippy_lints/src/methods/open_options.rs b/src/tools/clippy/clippy_lints/src/methods/open_options.rs
index fd36802..9b5f138 100644
--- a/src/tools/clippy/clippy_lints/src/methods/open_options.rs
+++ b/src/tools/clippy/clippy_lints/src/methods/open_options.rs
@@ -76,7 +76,7 @@ fn get_open_options(
                         ..
                     } = span
                     {
-                        Argument::Set(*lit)
+                        Argument::Set(lit)
                     } else {
                         // The function is called with a literal which is not a boolean literal.
                         // This is theoretically possible, but not very likely.
diff --git a/src/tools/clippy/clippy_lints/src/missing_asserts_for_indexing.rs b/src/tools/clippy/clippy_lints/src/missing_asserts_for_indexing.rs
index c8e3462..cf0c859 100644
--- a/src/tools/clippy/clippy_lints/src/missing_asserts_for_indexing.rs
+++ b/src/tools/clippy/clippy_lints/src/missing_asserts_for_indexing.rs
@@ -104,7 +104,7 @@ fn len_comparison<'hir>(
 ) -> Option<(LengthComparison, usize, &'hir Expr<'hir>)> {
     macro_rules! int_lit_pat {
         ($id:ident) => {
-            ExprKind::Lit(&Spanned {
+            ExprKind::Lit(Spanned {
                 node: LitKind::Int(Pu128($id), _),
                 ..
             })
diff --git a/src/tools/clippy/clippy_lints/src/undocumented_unsafe_blocks.rs b/src/tools/clippy/clippy_lints/src/undocumented_unsafe_blocks.rs
index 9242747..6cc4b58 100644
--- a/src/tools/clippy/clippy_lints/src/undocumented_unsafe_blocks.rs
+++ b/src/tools/clippy/clippy_lints/src/undocumented_unsafe_blocks.rs
@@ -256,7 +256,10 @@ fn check_item(&mut self, cx: &LateContext<'_>, item: &hir::Item<'_>) {
                             cx,
                             UNNECESSARY_SAFETY_COMMENT,
                             span,
-                            format!("{} has unnecessary safety comment", item.kind.descr()),
+                            format!(
+                                "{} has unnecessary safety comment",
+                                cx.tcx.def_descr(item.owner_id.to_def_id()),
+                            ),
                             |diag| {
                                 diag.span_help(help_span, "consider removing the safety comment");
                             },
@@ -274,7 +277,10 @@ fn check_item(&mut self, cx: &LateContext<'_>, item: &hir::Item<'_>) {
                         cx,
                         UNNECESSARY_SAFETY_COMMENT,
                         span,
-                        format!("{} has unnecessary safety comment", item.kind.descr()),
+                        format!(
+                            "{} has unnecessary safety comment",
+                            cx.tcx.def_descr(item.owner_id.to_def_id()),
+                        ),
                         |diag| {
                             diag.span_help(help_span, "consider removing the safety comment");
                         },
diff --git a/src/tools/clippy/clippy_lints/src/utils/author.rs b/src/tools/clippy/clippy_lints/src/utils/author.rs
index 3a08531..ac92ab5 100644
--- a/src/tools/clippy/clippy_lints/src/utils/author.rs
+++ b/src/tools/clippy/clippy_lints/src/utils/author.rs
@@ -324,7 +324,7 @@ fn const_arg(&self, const_arg: &Binding<&ConstArg<'_>>) {
         }
     }
 
-    fn lit(&self, lit: &Binding<&Lit>) {
+    fn lit(&self, lit: &Binding<Lit>) {
         let kind = |kind| chain!(self, "let LitKind::{kind} = {lit}.node");
         macro_rules! kind {
             ($($t:tt)*) => (kind(format_args!($($t)*)));
diff --git a/src/tools/clippy/clippy_utils/src/consts.rs b/src/tools/clippy/clippy_utils/src/consts.rs
index aaa071f..09299c8 100644
--- a/src/tools/clippy/clippy_utils/src/consts.rs
+++ b/src/tools/clippy/clippy_utils/src/consts.rs
@@ -4,8 +4,6 @@
 //! executable MIR bodies, so we have to do this instead.
 #![allow(clippy::float_cmp)]
 
-use std::sync::Arc;
-
 use crate::source::{SpanRangeExt, walk_span_to_context};
 use crate::{clip, is_direct_expn_of, sext, unsext};
 
@@ -38,7 +36,7 @@ pub enum Constant<'tcx> {
     /// A `String` (e.g., "abc").
     Str(String),
     /// A binary string (e.g., `b"abc"`).
-    Binary(Arc<[u8]>),
+    Binary(Vec<u8>),
     /// A single `char` (e.g., `'a'`).
     Char(char),
     /// An integer's bit representation.
@@ -306,7 +304,9 @@ pub fn lit_to_mir_constant<'tcx>(lit: &LitKind, ty: Option<Ty<'tcx>>) -> Constan
     match *lit {
         LitKind::Str(ref is, _) => Constant::Str(is.to_string()),
         LitKind::Byte(b) => Constant::Int(u128::from(b)),
-        LitKind::ByteStr(ref s, _) | LitKind::CStr(ref s, _) => Constant::Binary(Arc::clone(s)),
+        LitKind::ByteStr(ref s, _) | LitKind::CStr(ref s, _) => {
+            Constant::Binary(s.as_byte_str().to_vec())
+        }
         LitKind::Char(c) => Constant::Char(c),
         LitKind::Int(n, _) => Constant::Int(n.get()),
         LitKind::Float(ref is, LitFloatType::Suffixed(fty)) => match fty {
@@ -568,7 +568,9 @@ pub fn eval_is_empty(&self, e: &Expr<'_>) -> Option<bool> {
                 } else {
                     match &lit.node {
                         LitKind::Str(is, _) => Some(is.is_empty()),
-                        LitKind::ByteStr(s, _) | LitKind::CStr(s, _) => Some(s.is_empty()),
+                        LitKind::ByteStr(s, _) | LitKind::CStr(s, _) => {
+                            Some(s.as_byte_str().is_empty())
+                        }
                         _ => None,
                     }
                 }
diff --git a/src/tools/clippy/clippy_utils/src/qualify_min_const_fn.rs b/src/tools/clippy/clippy_utils/src/qualify_min_const_fn.rs
index 8f1ebb8..942c71a 100644
--- a/src/tools/clippy/clippy_utils/src/qualify_min_const_fn.rs
+++ b/src/tools/clippy/clippy_utils/src/qualify_min_const_fn.rs
@@ -175,10 +175,6 @@ fn check_rvalue<'tcx>(
         Rvalue::Cast(CastKind::PointerExposeProvenance, _, _) => {
             Err((span, "casting pointers to ints is unstable in const fn".into()))
         },
-        Rvalue::Cast(CastKind::PointerCoercion(PointerCoercion::DynStar, _), _, _) => {
-            // FIXME(dyn-star)
-            unimplemented!()
-        },
         Rvalue::Cast(CastKind::Transmute, _, _) => Err((
             span,
             "transmute can attempt to turn pointers into integers, so is unstable in const fn".into(),
diff --git a/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.default.stderr b/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.default.stderr
index 8a2f201..bfc14be 100644
--- a/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.default.stderr
+++ b/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.default.stderr
@@ -240,7 +240,7 @@
    |
    = help: consider adding a safety comment on the preceding line
 
-error: constant item has unnecessary safety comment
+error: constant has unnecessary safety comment
   --> tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.rs:508:5
    |
 LL |     const BIG_NUMBER: i32 = 1000000;
diff --git a/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.disabled.stderr b/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.disabled.stderr
index e9c5e5f..20cdff5 100644
--- a/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.disabled.stderr
+++ b/src/tools/clippy/tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.disabled.stderr
@@ -240,7 +240,7 @@
    |
    = help: consider adding a safety comment on the preceding line
 
-error: constant item has unnecessary safety comment
+error: constant has unnecessary safety comment
   --> tests/ui-toml/undocumented_unsafe_blocks/undocumented_unsafe_blocks.rs:508:5
    |
 LL |     const BIG_NUMBER: i32 = 1000000;
diff --git a/src/tools/clippy/tests/ui/unnecessary_safety_comment.stderr b/src/tools/clippy/tests/ui/unnecessary_safety_comment.stderr
index b56e8b3..732e676 100644
--- a/src/tools/clippy/tests/ui/unnecessary_safety_comment.stderr
+++ b/src/tools/clippy/tests/ui/unnecessary_safety_comment.stderr
@@ -1,4 +1,4 @@
-error: constant item has unnecessary safety comment
+error: constant has unnecessary safety comment
   --> tests/ui/unnecessary_safety_comment.rs:6:5
    |
 LL |     const CONST: u32 = 0;
@@ -12,7 +12,7 @@
    = note: `-D clippy::unnecessary-safety-comment` implied by `-D warnings`
    = help: to override `-D warnings` add `#[allow(clippy::unnecessary_safety_comment)]`
 
-error: static item has unnecessary safety comment
+error: static has unnecessary safety comment
   --> tests/ui/unnecessary_safety_comment.rs:10:5
    |
 LL |     static STATIC: u32 = 0;
diff --git a/src/tools/compiletest/Cargo.toml b/src/tools/compiletest/Cargo.toml
index 3b544d8..cdada5a 100644
--- a/src/tools/compiletest/Cargo.toml
+++ b/src/tools/compiletest/Cargo.toml
@@ -6,6 +6,10 @@
 [lib]
 doctest = false
 
+[[bin]]
+name = "compiletest"
+path = "src/bin/main.rs"
+
 [dependencies]
 # tidy-alphabetical-start
 anstyle-svg = "0.1.3"
diff --git a/src/tools/compiletest/src/bin/main.rs b/src/tools/compiletest/src/bin/main.rs
new file mode 100644
index 0000000..1f777e7
--- /dev/null
+++ b/src/tools/compiletest/src/bin/main.rs
@@ -0,0 +1,24 @@
+use std::env;
+use std::io::IsTerminal;
+use std::sync::Arc;
+
+use compiletest::{early_config_check, log_config, parse_config, run_tests};
+
+fn main() {
+    tracing_subscriber::fmt::init();
+
+    // colored checks stdout by default, but for some reason only stderr is a terminal.
+    // compiletest *does* print many things to stdout, but it doesn't really matter.
+    if std::io::stderr().is_terminal()
+        && matches!(std::env::var("NO_COLOR").as_deref(), Err(_) | Ok("0"))
+    {
+        colored::control::set_override(true);
+    }
+
+    let config = Arc::new(parse_config(env::args().collect()));
+
+    early_config_check(&config);
+
+    log_config(&config);
+    run_tests(config);
+}
diff --git a/src/tools/compiletest/src/common.rs b/src/tools/compiletest/src/common.rs
index 9b9d94b..cdce5d9 100644
--- a/src/tools/compiletest/src/common.rs
+++ b/src/tools/compiletest/src/common.rs
@@ -11,6 +11,7 @@
 
 pub use self::Mode::*;
 use crate::executor::{ColorConfig, OutputFormat};
+use crate::fatal;
 use crate::util::{Utf8PathBufExt, add_dylib_path};
 
 macro_rules! string_enum {
@@ -783,11 +784,13 @@ fn rustc_output(config: &Config, args: &[&str], envs: HashMap<String, String>) -
 
     let output = match command.output() {
         Ok(output) => output,
-        Err(e) => panic!("error: failed to run {command:?}: {e}"),
+        Err(e) => {
+            fatal!("failed to run {command:?}: {e}");
+        }
     };
     if !output.status.success() {
-        panic!(
-            "error: failed to run {command:?}\n--- stdout\n{}\n--- stderr\n{}",
+        fatal!(
+            "failed to run {command:?}\n--- stdout\n{}\n--- stderr\n{}",
             String::from_utf8(output.stdout).unwrap(),
             String::from_utf8(output.stderr).unwrap(),
         );
diff --git a/src/tools/compiletest/src/diagnostics.rs b/src/tools/compiletest/src/diagnostics.rs
new file mode 100644
index 0000000..207a6cb
--- /dev/null
+++ b/src/tools/compiletest/src/diagnostics.rs
@@ -0,0 +1,46 @@
+//! Collection of diagnostics helpers for `compiletest` *itself*.
+
+#[macro_export]
+macro_rules! fatal {
+    ($($arg:tt)*) => {
+        let status = ::colored::Colorize::bright_red("FATAL: ");
+        let status = ::colored::Colorize::bold(status);
+        eprint!("{status}");
+        eprintln!($($arg)*);
+        // This intentionally uses a seemingly-redundant panic to include backtrace location.
+        //
+        // FIXME: in the long term, we should handle "logic bug in compiletest itself" vs "fatal
+        // user error" separately.
+        panic!("fatal error");
+    };
+}
+
+#[macro_export]
+macro_rules! error {
+    ($($arg:tt)*) => {
+        let status = ::colored::Colorize::red("ERROR: ");
+        let status = ::colored::Colorize::bold(status);
+        eprint!("{status}");
+        eprintln!($($arg)*);
+    };
+}
+
+#[macro_export]
+macro_rules! warning {
+    ($($arg:tt)*) => {
+        let status = ::colored::Colorize::yellow("WARNING: ");
+        let status = ::colored::Colorize::bold(status);
+        eprint!("{status}");
+        eprintln!($($arg)*);
+    };
+}
+
+#[macro_export]
+macro_rules! help {
+    ($($arg:tt)*) => {
+        let status = ::colored::Colorize::cyan("HELP: ");
+        let status = ::colored::Colorize::bold(status);
+        eprint!("{status}");
+        eprintln!($($arg)*);
+    };
+}
diff --git a/src/tools/compiletest/src/header.rs b/src/tools/compiletest/src/header.rs
index 2b203bb..5636a14 100644
--- a/src/tools/compiletest/src/header.rs
+++ b/src/tools/compiletest/src/header.rs
@@ -15,6 +15,7 @@
 use crate::executor::{CollectedTestDesc, ShouldPanic};
 use crate::header::auxiliary::{AuxProps, parse_and_update_aux};
 use crate::header::needs::CachedNeedsConditions;
+use crate::help;
 use crate::util::static_regex;
 
 pub(crate) mod auxiliary;
@@ -920,9 +921,9 @@ fn iter_header(
             if !is_known_directive {
                 *poisoned = true;
 
-                eprintln!(
-                    "error: detected unknown compiletest test directive `{}` in {}:{}",
-                    directive_line.raw_directive, testfile, line_number,
+                error!(
+                    "{testfile}:{line_number}: detected unknown compiletest test directive `{}`",
+                    directive_line.raw_directive,
                 );
 
                 return;
@@ -931,11 +932,11 @@ fn iter_header(
             if let Some(trailing_directive) = &trailing_directive {
                 *poisoned = true;
 
-                eprintln!(
-                    "error: detected trailing compiletest test directive `{}` in {}:{}\n \
-                      help: put the trailing directive in it's own line: `//@ {}`",
-                    trailing_directive, testfile, line_number, trailing_directive,
+                error!(
+                    "{testfile}:{line_number}: detected trailing compiletest test directive `{}`",
+                    trailing_directive,
                 );
+                help!("put the trailing directive in it's own line: `//@ {}`", trailing_directive);
 
                 return;
             }
@@ -1031,10 +1032,9 @@ fn parse_custom_normalization(&self, raw_directive: &str) -> Option<NormalizeRul
         };
 
         let Some((regex, replacement)) = parse_normalize_rule(raw_value) else {
-            panic!(
-                "couldn't parse custom normalization rule: `{raw_directive}`\n\
-                help: expected syntax is: `{directive_name}: \"REGEX\" -> \"REPLACEMENT\"`"
-            );
+            error!("couldn't parse custom normalization rule: `{raw_directive}`");
+            help!("expected syntax is: `{directive_name}: \"REGEX\" -> \"REPLACEMENT\"`");
+            panic!("invalid normalization rule detected");
         };
         Some(NormalizeRule { kind, regex, replacement })
     }
@@ -1406,7 +1406,7 @@ macro_rules! decision {
                             ignore_message = Some(reason.into());
                         }
                         IgnoreDecision::Error { message } => {
-                            eprintln!("error: {}:{line_number}: {message}", path);
+                            error!("{path}:{line_number}: {message}");
                             *poisoned = true;
                             return;
                         }
diff --git a/src/tools/compiletest/src/lib.rs b/src/tools/compiletest/src/lib.rs
index 0db4d3f..09de3eb 100644
--- a/src/tools/compiletest/src/lib.rs
+++ b/src/tools/compiletest/src/lib.rs
@@ -11,6 +11,7 @@
 pub mod common;
 pub mod compute_diff;
 mod debuggers;
+pub mod diagnostics;
 pub mod errors;
 mod executor;
 pub mod header;
@@ -33,7 +34,7 @@
 use camino::{Utf8Path, Utf8PathBuf};
 use getopts::Options;
 use rayon::iter::{ParallelBridge, ParallelIterator};
-use tracing::*;
+use tracing::debug;
 use walkdir::WalkDir;
 
 use self::header::{EarlyProps, make_test_description};
@@ -51,12 +52,6 @@
 /// some code here that inspects environment variables or even runs executables
 /// (e.g. when discovering debugger versions).
 pub fn parse_config(args: Vec<String>) -> Config {
-    if env::var("RUST_TEST_NOCAPTURE").is_ok() {
-        eprintln!(
-            "WARNING: RUST_TEST_NOCAPTURE is not supported. Use the `--no-capture` flag instead."
-        );
-    }
-
     let mut opts = Options::new();
     opts.reqopt("", "compile-lib-path", "path to host shared libraries", "PATH")
         .reqopt("", "run-lib-path", "path to target shared libraries", "PATH")
@@ -657,10 +652,7 @@ pub(crate) fn collect_and_make_tests(config: Arc<Config>) -> Vec<CollectedTest>
     let common_inputs_stamp = common_inputs_stamp(&config);
     let modified_tests =
         modified_tests(&config, &config.src_test_suite_root).unwrap_or_else(|err| {
-            panic!(
-                "modified_tests got error from dir: {}, error: {}",
-                config.src_test_suite_root, err
-            )
+            fatal!("modified_tests: {}: {err}", config.src_test_suite_root);
         });
     let cache = HeadersCache::load(&config);
 
@@ -1111,3 +1103,20 @@ fn check_for_overlapping_test_paths(found_path_stems: &HashSet<Utf8PathBuf>) {
         );
     }
 }
+
+pub fn early_config_check(config: &Config) {
+    if !config.has_html_tidy && config.mode == Mode::Rustdoc {
+        warning!("`tidy` (html-tidy.org) is not installed; diffs will not be generated");
+    }
+
+    if !config.profiler_runtime && config.mode == Mode::CoverageRun {
+        let actioned = if config.bless { "blessed" } else { "checked" };
+        warning!("profiler runtime is not available, so `.coverage` files won't be {actioned}");
+        help!("try setting `profiler = true` in the `[build]` section of `bootstrap.toml`");
+    }
+
+    // `RUST_TEST_NOCAPTURE` is a libtest env var, but we don't callout to libtest.
+    if env::var("RUST_TEST_NOCAPTURE").is_ok() {
+        warning!("`RUST_TEST_NOCAPTURE` is not supported; use the `--no-capture` flag instead");
+    }
+}
diff --git a/src/tools/compiletest/src/main.rs b/src/tools/compiletest/src/main.rs
deleted file mode 100644
index b9ae583..0000000
--- a/src/tools/compiletest/src/main.rs
+++ /dev/null
@@ -1,36 +0,0 @@
-use std::env;
-use std::io::IsTerminal;
-use std::sync::Arc;
-
-use compiletest::common::Mode;
-use compiletest::{log_config, parse_config, run_tests};
-
-fn main() {
-    tracing_subscriber::fmt::init();
-
-    // colored checks stdout by default, but for some reason only stderr is a terminal.
-    // compiletest *does* print many things to stdout, but it doesn't really matter.
-    if std::io::stderr().is_terminal()
-        && matches!(std::env::var("NO_COLOR").as_deref(), Err(_) | Ok("0"))
-    {
-        colored::control::set_override(true);
-    }
-
-    let config = Arc::new(parse_config(env::args().collect()));
-
-    if !config.has_html_tidy && config.mode == Mode::Rustdoc {
-        eprintln!("warning: `tidy` (html-tidy.org) is not installed; diffs will not be generated");
-    }
-
-    if !config.profiler_runtime && config.mode == Mode::CoverageRun {
-        let actioned = if config.bless { "blessed" } else { "checked" };
-        eprintln!(
-            r#"
-WARNING: profiler runtime is not available, so `.coverage` files won't be {actioned}
-help: try setting `profiler = true` in the `[build]` section of `bootstrap.toml`"#
-        );
-    }
-
-    log_config(&config);
-    run_tests(config);
-}
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs
index 980e898..53b5990 100644
--- a/src/tools/compiletest/src/runtest.rs
+++ b/src/tools/compiletest/src/runtest.rs
@@ -27,7 +27,7 @@
 use crate::header::TestProps;
 use crate::read2::{Truncated, read2_abbreviated};
 use crate::util::{Utf8PathBufExt, add_dylib_path, logv, static_regex};
-use crate::{ColorConfig, json, stamp_file_path};
+use crate::{ColorConfig, help, json, stamp_file_path, warning};
 
 mod debugger;
 
@@ -485,12 +485,15 @@ fn set_revision_flags(&self, cmd: &mut Command) {
                 .windows(2)
                 .any(|args| args == cfg_arg || args[0] == arg || args[1] == arg)
             {
-                panic!(
-                    "error: redundant cfg argument `{normalized_revision}` is already created by the revision"
+                error!(
+                    "redundant cfg argument `{normalized_revision}` is already created by the \
+                    revision"
                 );
+                panic!("redundant cfg argument");
             }
             if self.config.builtin_cfg_names().contains(&normalized_revision) {
-                panic!("error: revision `{normalized_revision}` collides with a builtin cfg");
+                error!("revision `{normalized_revision}` collides with a built-in cfg");
+                panic!("revision collides with built-in cfg");
             }
             cmd.args(cfg_arg);
         }
@@ -2167,9 +2170,10 @@ fn compare_to_default_rustdoc(&mut self, out_dir: &Utf8Path) {
             println!("{}", String::from_utf8_lossy(&output.stdout));
             eprintln!("{}", String::from_utf8_lossy(&output.stderr));
         } else {
-            eprintln!("warning: no pager configured, falling back to unified diff");
-            eprintln!(
-                "help: try configuring a git pager (e.g. `delta`) with `git config --global core.pager delta`"
+            warning!("no pager configured, falling back to unified diff");
+            help!(
+                "try configuring a git pager (e.g. `delta`) with \
+                `git config --global core.pager delta`"
             );
             let mut out = io::stdout();
             let mut diff = BufReader::new(File::open(&diff_filename).unwrap());
diff --git a/src/tools/compiletest/src/runtest/codegen_units.rs b/src/tools/compiletest/src/runtest/codegen_units.rs
index 8dfa8d1..44ddcb1 100644
--- a/src/tools/compiletest/src/runtest/codegen_units.rs
+++ b/src/tools/compiletest/src/runtest/codegen_units.rs
@@ -1,8 +1,8 @@
 use std::collections::HashSet;
 
 use super::{Emit, TestCx, WillExecute};
-use crate::errors;
 use crate::util::static_regex;
+use crate::{errors, fatal};
 
 impl TestCx<'_> {
     pub(super) fn run_codegen_units_test(&self) {
@@ -100,7 +100,7 @@ pub(super) fn run_codegen_units_test(&self) {
         }
 
         if !(missing.is_empty() && unexpected.is_empty() && wrong_cgus.is_empty()) {
-            panic!();
+            fatal!("!(missing.is_empty() && unexpected.is_empty() && wrong_cgus.is_empty())");
         }
 
         #[derive(Clone, Eq, PartialEq)]
diff --git a/src/tools/miri/Cargo.toml b/src/tools/miri/Cargo.toml
index 0b4b8e2..9391a6f 100644
--- a/src/tools/miri/Cargo.toml
+++ b/src/tools/miri/Cargo.toml
@@ -70,7 +70,6 @@
 
 [lints.rust.unexpected_cfgs]
 level = "warn"
-check-cfg = ['cfg(bootstrap)']
 
 # Be aware that this file is inside a workspace when used via the
 # submodule in the rustc repo. That means there are many cargo features
diff --git a/src/tools/miri/cargo-miri/src/phases.rs b/src/tools/miri/cargo-miri/src/phases.rs
index a5e019a..b72b974 100644
--- a/src/tools/miri/cargo-miri/src/phases.rs
+++ b/src/tools/miri/cargo-miri/src/phases.rs
@@ -176,11 +176,6 @@ pub fn phase_cargo_miri(mut args: impl Iterator<Item = String>) {
     // Set `--target-dir` to `miri` inside the original target directory.
     let target_dir = get_target_dir(&metadata);
     cmd.arg("--target-dir").arg(target_dir);
-    // Only when running in x.py (where we are running with beta cargo): set `RUSTC_STAGE`.
-    // Will have to be removed on next bootstrap bump. tag: cfg(bootstrap).
-    if env::var_os("RUSTC_STAGE").is_some() {
-        cmd.arg("-Zdoctest-xcompile");
-    }
 
     // *After* we set all the flags that need setting, forward everything else. Make sure to skip
     // `--target-dir` (which would otherwise be set twice).
diff --git a/src/tools/miri/src/alloc_addresses/mod.rs b/src/tools/miri/src/alloc_addresses/mod.rs
index 4a038fe..1796120 100644
--- a/src/tools/miri/src/alloc_addresses/mod.rs
+++ b/src/tools/miri/src/alloc_addresses/mod.rs
@@ -390,7 +390,7 @@ fn adjust_alloc_root_pointer(
     ) -> InterpResult<'tcx, interpret::Pointer<Provenance>> {
         let this = self.eval_context_ref();
 
-        let (prov, offset) = ptr.into_parts(); // offset is relative (AllocId provenance)
+        let (prov, offset) = ptr.prov_and_relative_offset();
         let alloc_id = prov.alloc_id();
 
         // Get a pointer to the beginning of this allocation.
@@ -447,7 +447,7 @@ fn ptr_get_alloc(
     ) -> Option<(AllocId, Size)> {
         let this = self.eval_context_ref();
 
-        let (tag, addr) = ptr.into_parts(); // addr is absolute (Tag provenance)
+        let (tag, addr) = ptr.into_raw_parts(); // addr is absolute (Miri provenance)
 
         let alloc_id = if let Provenance::Concrete { alloc_id, .. } = tag {
             alloc_id
diff --git a/src/tools/miri/src/bin/miri.rs b/src/tools/miri/src/bin/miri.rs
index 92d2173..56be370 100644
--- a/src/tools/miri/src/bin/miri.rs
+++ b/src/tools/miri/src/bin/miri.rs
@@ -85,7 +85,7 @@ fn entry_fn(tcx: TyCtxt<'_>) -> (DefId, MiriEntryFnType) {
         return (def_id, MiriEntryFnType::Rustc(entry_type));
     }
     // Look for a symbol in the local crate named `miri_start`, and treat that as the entry point.
-    let sym = tcx.exported_symbols(LOCAL_CRATE).iter().find_map(|(sym, _)| {
+    let sym = tcx.exported_non_generic_symbols(LOCAL_CRATE).iter().find_map(|(sym, _)| {
         if sym.symbol_name_for_local_instance(tcx).name == "miri_start" { Some(sym) } else { None }
     });
     if let Some(ExportedSymbol::NonGeneric(id)) = sym {
@@ -250,10 +250,10 @@ fn config(&mut self, config: &mut Config) {
             // Queries overridden here affect the data stored in `rmeta` files of dependencies,
             // which will be used later in non-`MIRI_BE_RUSTC` mode.
             config.override_queries = Some(|_, local_providers| {
-                // `exported_symbols` and `reachable_non_generics` provided by rustc always returns
+                // `exported_non_generic_symbols` and `reachable_non_generics` provided by rustc always returns
                 // an empty result if `tcx.sess.opts.output_types.should_codegen()` is false.
                 // In addition we need to add #[used] symbols to exported_symbols for `lookup_link_section`.
-                local_providers.exported_symbols = |tcx, LocalCrate| {
+                local_providers.exported_non_generic_symbols = |tcx, LocalCrate| {
                     let reachable_set = tcx.with_stable_hashing_context(|hcx| {
                         tcx.reachable_set(()).to_sorted(&hcx, true)
                     });
diff --git a/src/tools/miri/src/concurrency/mod.rs b/src/tools/miri/src/concurrency/mod.rs
index aaa3fc8..17d0f3f 100644
--- a/src/tools/miri/src/concurrency/mod.rs
+++ b/src/tools/miri/src/concurrency/mod.rs
@@ -8,19 +8,8 @@
 mod vector_clock;
 pub mod weak_memory;
 
-// cfg(bootstrap)
-macro_rules! cfg_select_dispatch {
-    ($($tokens:tt)*) => {
-        #[cfg(bootstrap)]
-        cfg_match! { $($tokens)* }
-
-        #[cfg(not(bootstrap))]
-        cfg_select! { $($tokens)* }
-    };
-}
-
 // Import either the real genmc adapter or a dummy module.
-cfg_select_dispatch! {
+cfg_select! {
     feature = "genmc" => {
         mod genmc;
         pub use self::genmc::{GenmcCtx, GenmcConfig};
diff --git a/src/tools/miri/src/helpers.rs b/src/tools/miri/src/helpers.rs
index fb34600..908f39a 100644
--- a/src/tools/miri/src/helpers.rs
+++ b/src/tools/miri/src/helpers.rs
@@ -162,7 +162,7 @@ pub fn iter_exported_symbols<'tcx>(
 
         // We can ignore `_export_info` here: we are a Rust crate, and everything is exported
         // from a Rust crate.
-        for &(symbol, _export_info) in tcx.exported_symbols(cnum) {
+        for &(symbol, _export_info) in tcx.exported_non_generic_symbols(cnum) {
             if let ExportedSymbol::NonGeneric(def_id) = symbol {
                 f(cnum, def_id)?;
             }
@@ -595,10 +595,6 @@ fn visit_value(&mut self, v: &MPlaceTy<'tcx>) -> InterpResult<'tcx> {
                 } else if matches!(v.layout.fields, FieldsShape::Union(..)) {
                     // A (non-frozen) union. We fall back to whatever the type says.
                     (self.unsafe_cell_action)(v)
-                } else if matches!(v.layout.ty.kind(), ty::Dynamic(_, _, ty::DynStar)) {
-                    // This needs to read the vtable pointer to proceed type-driven, but we don't
-                    // want to reentrantly read from memory here.
-                    (self.unsafe_cell_action)(v)
                 } else {
                     // We want to not actually read from memory for this visit. So, before
                     // walking this value, we have to make sure it is not a
diff --git a/src/tools/miri/src/intrinsics/mod.rs b/src/tools/miri/src/intrinsics/mod.rs
index ec77a16..ed1851a 100644
--- a/src/tools/miri/src/intrinsics/mod.rs
+++ b/src/tools/miri/src/intrinsics/mod.rs
@@ -191,7 +191,7 @@ fn emulate_intrinsic_by_name(
                 let [f] = check_intrinsic_arg_count(args)?;
                 let f = this.read_scalar(f)?.to_f32()?;
 
-                let res = fixed_float_value(intrinsic_name, &[f]).unwrap_or_else(||{
+                let res = fixed_float_value(this, intrinsic_name, &[f]).unwrap_or_else(|| {
                     // Using host floats (but it's fine, these operations do not have
                     // guaranteed precision).
                     let host = f.to_host();
@@ -235,7 +235,7 @@ fn emulate_intrinsic_by_name(
                 let [f] = check_intrinsic_arg_count(args)?;
                 let f = this.read_scalar(f)?.to_f64()?;
 
-                let res = fixed_float_value(intrinsic_name, &[f]).unwrap_or_else(||{
+                let res = fixed_float_value(this, intrinsic_name, &[f]).unwrap_or_else(|| {
                     // Using host floats (but it's fine, these operations do not have
                     // guaranteed precision).
                     let host = f.to_host();
@@ -312,7 +312,7 @@ fn emulate_intrinsic_by_name(
                 let f1 = this.read_scalar(f1)?.to_f32()?;
                 let f2 = this.read_scalar(f2)?.to_f32()?;
 
-                let res = fixed_float_value(intrinsic_name, &[f1, f2]).unwrap_or_else(|| {
+                let res = fixed_float_value(this, intrinsic_name, &[f1, f2]).unwrap_or_else(|| {
                     // Using host floats (but it's fine, this operation does not have guaranteed precision).
                     let res = f1.to_host().powf(f2.to_host()).to_soft();
 
@@ -330,7 +330,7 @@ fn emulate_intrinsic_by_name(
                 let f1 = this.read_scalar(f1)?.to_f64()?;
                 let f2 = this.read_scalar(f2)?.to_f64()?;
 
-                let res = fixed_float_value(intrinsic_name, &[f1, f2]).unwrap_or_else(|| {
+                let res = fixed_float_value(this, intrinsic_name, &[f1, f2]).unwrap_or_else(|| {
                     // Using host floats (but it's fine, this operation does not have guaranteed precision).
                     let res = f1.to_host().powf(f2.to_host()).to_soft();
 
@@ -349,7 +349,7 @@ fn emulate_intrinsic_by_name(
                 let f = this.read_scalar(f)?.to_f32()?;
                 let i = this.read_scalar(i)?.to_i32()?;
 
-                let res = fixed_powi_float_value(f, i).unwrap_or_else(|| {
+                let res = fixed_powi_float_value(this, f, i).unwrap_or_else(|| {
                     // Using host floats (but it's fine, this operation does not have guaranteed precision).
                     let res = f.to_host().powi(i).to_soft();
 
@@ -367,7 +367,7 @@ fn emulate_intrinsic_by_name(
                 let f = this.read_scalar(f)?.to_f64()?;
                 let i = this.read_scalar(i)?.to_i32()?;
 
-                let res = fixed_powi_float_value(f, i).unwrap_or_else(|| {
+                let res = fixed_powi_float_value(this, f, i).unwrap_or_else(|| {
                     // Using host floats (but it's fine, this operation does not have guaranteed precision).
                     let res = f.to_host().powi(i).to_soft();
 
@@ -496,52 +496,88 @@ fn apply_random_float_error_to_imm<'tcx>(
 /// - logf32, logf64, log2f32, log2f64, log10f32, log10f64
 /// - powf32, powf64
 ///
+/// # Return
+///
 /// Returns `Some(output)` if the `intrinsic` results in a defined fixed `output` specified in the C standard
 /// (specifically, C23 annex F.10)  when given `args` as arguments. Outputs that are unaffected by a relative error
 /// (such as INF and zero) are not handled here, they are assumed to be handled by the underlying
 /// implementation. Returns `None` if no specific value is guaranteed.
+///
+/// # Note
+///
+/// For `powf*` operations of the form:
+///
+/// - `(SNaN)^(±0)`
+/// - `1^(SNaN)`
+///
+/// The result is implementation-defined:
+/// - musl returns for both `1.0`
+/// - glibc returns for both `NaN`
+///
+/// This discrepancy exists because SNaN handling is not consistently defined across platforms,
+/// and the C standard leaves behavior for SNaNs unspecified.
+///
+/// Miri chooses to adhere to both implementations and returns either one of them non-deterministically.
 fn fixed_float_value<S: Semantics>(
+    ecx: &mut MiriInterpCx<'_>,
     intrinsic_name: &str,
     args: &[IeeeFloat<S>],
 ) -> Option<IeeeFloat<S>> {
     let one = IeeeFloat::<S>::one();
-    match (intrinsic_name, args) {
+    Some(match (intrinsic_name, args) {
         // cos(+- 0) = 1
-        ("cosf32" | "cosf64", [input]) if input.is_zero() => Some(one),
+        ("cosf32" | "cosf64", [input]) if input.is_zero() => one,
 
         // e^0 = 1
-        ("expf32" | "expf64" | "exp2f32" | "exp2f64", [input]) if input.is_zero() => Some(one),
-
-        // 1^y = 1 for any y, even a NaN.
-        ("powf32" | "powf64", [base, _]) if *base == one => Some(one),
+        ("expf32" | "expf64" | "exp2f32" | "exp2f64", [input]) if input.is_zero() => one,
 
         // (-1)^(±INF) = 1
-        ("powf32" | "powf64", [base, exp]) if *base == -one && exp.is_infinite() => Some(one),
+        ("powf32" | "powf64", [base, exp]) if *base == -one && exp.is_infinite() => one,
 
-        // FIXME(#4286): The C ecosystem is inconsistent with handling sNaN's, some return 1 others propogate
-        // the NaN. We should return either 1 or the NaN non-deterministically here.
-        // But for now, just handle them all the same.
+        // 1^y = 1 for any y, even a NaN
+        ("powf32" | "powf64", [base, exp]) if *base == one => {
+            let rng = ecx.machine.rng.get_mut();
+            // SNaN exponents get special treatment: they might return 1, or a NaN.
+            let return_nan = exp.is_signaling() && ecx.machine.float_nondet && rng.random();
+            // Handle both the musl and glibc cases non-deterministically.
+            if return_nan { ecx.generate_nan(args) } else { one }
+        }
+
         // x^(±0) = 1 for any x, even a NaN
-        ("powf32" | "powf64", [_, exp]) if exp.is_zero() => Some(one),
+        ("powf32" | "powf64", [base, exp]) if exp.is_zero() => {
+            let rng = ecx.machine.rng.get_mut();
+            // SNaN bases get special treatment: they might return 1, or a NaN.
+            let return_nan = base.is_signaling() && ecx.machine.float_nondet && rng.random();
+            // Handle both the musl and glibc cases non-deterministically.
+            if return_nan { ecx.generate_nan(args) } else { one }
+        }
 
-        // There are a lot of cases for fixed outputs according to the C Standard, but these are mainly INF or zero
-        // which are not affected by the applied error.
-        _ => None,
-    }
+        // There are a lot of cases for fixed outputs according to the C Standard, but these are
+        // mainly INF or zero which are not affected by the applied error.
+        _ => return None,
+    })
 }
 
-/// Returns `Some(output)` if `powi` (called `pown` in C) results in a fixed value specified in the C standard
-/// (specifically, C23 annex F.10.4.6) when doing `base^exp`. Otherwise, returns `None`.
-fn fixed_powi_float_value<S: Semantics>(base: IeeeFloat<S>, exp: i32) -> Option<IeeeFloat<S>> {
-    match (base.category(), exp) {
-        // x^0 = 1, if x is not a Signaling NaN
-        // FIXME(#4286): The C ecosystem is inconsistent with handling sNaN's, some return 1 others propogate
-        // the NaN. We should return either 1 or the NaN non-deterministically here.
-        // But for now, just handle them all the same.
-        (_, 0) => Some(IeeeFloat::<S>::one()),
+/// Returns `Some(output)` if `powi` (called `pown` in C) results in a fixed value specified in the
+/// C standard (specifically, C23 annex F.10.4.6) when doing `base^exp`. Otherwise, returns `None`.
+fn fixed_powi_float_value<S: Semantics>(
+    ecx: &mut MiriInterpCx<'_>,
+    base: IeeeFloat<S>,
+    exp: i32,
+) -> Option<IeeeFloat<S>> {
+    Some(match exp {
+        0 => {
+            let one = IeeeFloat::<S>::one();
+            let rng = ecx.machine.rng.get_mut();
+            let return_nan = ecx.machine.float_nondet && rng.random() && base.is_signaling();
+            // For SNaN treatment, we are consistent with `powf`above.
+            // (We wouldn't have two, unlike powf all implementations seem to agree for powi,
+            // but for now we are maximally conservative.)
+            if return_nan { ecx.generate_nan(&[base]) } else { one }
+        }
 
-        _ => None,
-    }
+        _ => return None,
+    })
 }
 
 /// Given an floating-point operation and a floating-point value, clamps the result to the output
diff --git a/src/tools/miri/src/lib.rs b/src/tools/miri/src/lib.rs
index 00f26a3..60bfdfb 100644
--- a/src/tools/miri/src/lib.rs
+++ b/src/tools/miri/src/lib.rs
@@ -1,5 +1,4 @@
-#![cfg_attr(bootstrap, feature(cfg_match))]
-#![cfg_attr(not(bootstrap), feature(cfg_select))]
+#![feature(cfg_select)]
 #![feature(rustc_private)]
 #![feature(float_gamma)]
 #![feature(float_erf)]
@@ -10,14 +9,12 @@
 #![feature(variant_count)]
 #![feature(yeet_expr)]
 #![feature(nonzero_ops)]
-#![cfg_attr(bootstrap, feature(nonnull_provenance))]
 #![feature(strict_overflow_ops)]
 #![feature(pointer_is_aligned_to)]
 #![feature(ptr_metadata)]
 #![feature(unqualified_local_imports)]
 #![feature(derive_coerce_pointee)]
 #![feature(arbitrary_self_types)]
-#![cfg_attr(bootstrap, feature(file_lock))]
 // Configure clippy and other lints
 #![allow(
     clippy::collapsible_else_if,
diff --git a/src/tools/miri/src/machine.rs b/src/tools/miri/src/machine.rs
index 3a748c4..17c13a9 100644
--- a/src/tools/miri/src/machine.rs
+++ b/src/tools/miri/src/machine.rs
@@ -285,7 +285,7 @@ fn get_alloc_id(self) -> Option<AllocId> {
     }
 
     fn fmt(ptr: &interpret::Pointer<Self>, f: &mut fmt::Formatter<'_>) -> fmt::Result {
-        let (prov, addr) = ptr.into_parts(); // address is absolute
+        let (prov, addr) = ptr.into_raw_parts(); // offset is absolute address
         write!(f, "{:#x}", addr.bytes())?;
         if f.alternate() {
             write!(f, "{prov:#?}")?;
diff --git a/src/tools/miri/src/provenance_gc.rs b/src/tools/miri/src/provenance_gc.rs
index b3d715d..6adf144 100644
--- a/src/tools/miri/src/provenance_gc.rs
+++ b/src/tools/miri/src/provenance_gc.rs
@@ -68,15 +68,13 @@ fn visit_provenance(&self, visit: &mut VisitWith<'_>) {
 
 impl VisitProvenance for StrictPointer {
     fn visit_provenance(&self, visit: &mut VisitWith<'_>) {
-        let (prov, _offset) = self.into_parts();
-        prov.visit_provenance(visit);
+        self.provenance.visit_provenance(visit);
     }
 }
 
 impl VisitProvenance for Pointer {
     fn visit_provenance(&self, visit: &mut VisitWith<'_>) {
-        let (prov, _offset) = self.into_parts();
-        prov.visit_provenance(visit);
+        self.provenance.visit_provenance(visit);
     }
 }
 
diff --git a/src/tools/miri/src/shims/foreign_items.rs b/src/tools/miri/src/shims/foreign_items.rs
index 416cb1a..97070eb 100644
--- a/src/tools/miri/src/shims/foreign_items.rs
+++ b/src/tools/miri/src/shims/foreign_items.rs
@@ -411,7 +411,7 @@ fn emulate_foreign_item_inner(
                         AlignFromBytesError::TooLarge(_) => Align::MAX,
                     }
                 });
-                let (_, addr) = ptr.into_parts(); // we know the offset is absolute
+                let addr = ptr.addr();
                 // Cannot panic since `align` is a power of 2 and hence non-zero.
                 if addr.bytes().strict_rem(align.bytes()) != 0 {
                     throw_unsup_format!(
diff --git a/src/tools/miri/src/shims/unix/mem.rs b/src/tools/miri/src/shims/unix/mem.rs
index 4bbbbc6..1738de4 100644
--- a/src/tools/miri/src/shims/unix/mem.rs
+++ b/src/tools/miri/src/shims/unix/mem.rs
@@ -49,7 +49,7 @@ fn mmap(
             && matches!(&*this.tcx.sess.target.os, "macos" | "solaris" | "illumos")
             && (flags & map_fixed) != 0
         {
-            return interp_ok(Scalar::from_maybe_pointer(Pointer::from_addr_invalid(addr), this));
+            return interp_ok(Scalar::from_maybe_pointer(Pointer::without_provenance(addr), this));
         }
 
         let prot_read = this.eval_libc_i32("PROT_READ");
diff --git a/src/tools/miri/tests/pass/dyn-star.rs b/src/tools/miri/tests/pass/dyn-star.rs
deleted file mode 100644
index 1ce0dd3..0000000
--- a/src/tools/miri/tests/pass/dyn-star.rs
+++ /dev/null
@@ -1,103 +0,0 @@
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-#![feature(custom_inner_attributes)]
-// rustfmt destroys `dyn* Trait` syntax
-#![rustfmt::skip]
-
-use std::fmt::{Debug, Display};
-
-fn main() {
-    make_dyn_star();
-    method();
-    box_();
-    dispatch_on_pin_mut();
-    dyn_star_to_dyn();
-    dyn_to_dyn_star();
-}
-
-fn dyn_star_to_dyn() {
-    let x: dyn* Debug = &42;
-    let x = Box::new(x) as Box<dyn Debug>;
-    assert_eq!("42", format!("{x:?}"));
-}
-
-fn dyn_to_dyn_star() {
-    let x: Box<dyn Debug> = Box::new(42);
-    let x = &x as dyn* Debug;
-    assert_eq!("42", format!("{x:?}"));
-}
-
-fn make_dyn_star() {
-    fn make_dyn_star_coercion(i: usize) {
-        let _dyn_i: dyn* Debug = i;
-    }
-
-    fn make_dyn_star_explicit(i: usize) {
-        let _dyn_i: dyn* Debug = i as dyn* Debug;
-    }
-
-    make_dyn_star_coercion(42);
-    make_dyn_star_explicit(42);
-}
-
-fn method() {
-    trait Foo {
-        fn get(&self) -> usize;
-    }
-    
-    impl Foo for usize {
-        fn get(&self) -> usize {
-            *self
-        }
-    }
-    
-    fn invoke_dyn_star(i: dyn* Foo) -> usize {
-        i.get()
-    }
-    
-    fn make_and_invoke_dyn_star(i: usize) -> usize {
-        let dyn_i: dyn* Foo = i;
-        invoke_dyn_star(dyn_i)
-    }
-    
-    assert_eq!(make_and_invoke_dyn_star(42), 42);
-}
-
-fn box_() {
-    fn make_dyn_star() -> dyn* Display {
-        Box::new(42) as dyn* Display
-    }
-    
-    let x = make_dyn_star();
-    assert_eq!(format!("{x}"), "42");
-}
-
-fn dispatch_on_pin_mut() {
-    use std::future::Future;
-
-    async fn foo(f: dyn* Future<Output = i32>) {
-        println!("dispatch_on_pin_mut: value: {}", f.await);
-    }
-
-    async fn async_main() {
-        foo(Box::pin(async { 1 })).await
-    }
-
-    // ------------------------------------------------------------------------- //
-    // Implementation Details Below...
-
-    use std::pin::Pin;
-    use std::task::*;
-
-    let mut fut = async_main();
-
-    // Poll loop, just to test the future...
-    let ctx = &mut Context::from_waker(Waker::noop());
-
-    loop {
-        match unsafe { Pin::new_unchecked(&mut fut).poll(ctx) } {
-            Poll::Pending => {}
-            Poll::Ready(()) => break,
-        }
-    }
-}
diff --git a/src/tools/miri/tests/pass/float.rs b/src/tools/miri/tests/pass/float.rs
index 3835791..0fec1fb 100644
--- a/src/tools/miri/tests/pass/float.rs
+++ b/src/tools/miri/tests/pass/float.rs
@@ -1066,17 +1066,6 @@ fn ldexp(a: f64, b: i32) -> f64 {
     assert_eq!((-1f32).powf(f32::NEG_INFINITY), 1.0);
     assert_eq!((-1f64).powf(f64::NEG_INFINITY), 1.0);
 
-    // For pow (powf in rust) the C standard says:
-    // x^0 = 1 for all x even a sNaN
-    // FIXME(#4286): this does not match the behavior of all implementations.
-    assert_eq!(SNAN_F32.powf(0.0), 1.0);
-    assert_eq!(SNAN_F64.powf(0.0), 1.0);
-
-    // For pown (powi in rust) the C standard says:
-    // x^0 = 1 for all x even a sNaN
-    // FIXME(#4286): this does not match the behavior of all implementations.
-    assert_eq!(SNAN_F32.powi(0), 1.0);
-    assert_eq!(SNAN_F64.powi(0), 1.0);
 
     assert_eq!(0f32.powi(10), 0.0);
     assert_eq!(0f64.powi(100), 0.0);
@@ -1358,7 +1347,7 @@ fn test_min_max_nondet() {
     /// Ensure that if we call the closure often enough, we see both `true` and `false.`
     #[track_caller]
     fn ensure_both(f: impl Fn() -> bool) {
-        let rounds = 16;
+        let rounds = 32;
         let first = f();
         for _ in 1..rounds {
             if f() != first {
@@ -1500,4 +1489,18 @@ pub fn test_operations_f128(a: f128, b: f128) {
     test_operations_f32(12., 5.);
     test_operations_f64(19., 11.);
     test_operations_f128(25., 18.);
+
+
+    // SNaN^0 = (1 | NaN)
+    ensure_nondet(|| f32::powf(SNAN_F32, 0.0).is_nan());
+    ensure_nondet(|| f64::powf(SNAN_F64, 0.0).is_nan());
+
+    // 1^SNaN = (1 | NaN)
+    ensure_nondet(|| f32::powf(1.0, SNAN_F32).is_nan());
+    ensure_nondet(|| f64::powf(1.0, SNAN_F64).is_nan());
+
+    // same as powf (keep it consistent):
+    // x^SNaN = (1 | NaN)
+    ensure_nondet(|| f32::powi(SNAN_F32, 0).is_nan());
+    ensure_nondet(|| f64::powi(SNAN_F64, 0).is_nan());
 }
diff --git a/src/tools/miri/tests/pass/float_nan.rs b/src/tools/miri/tests/pass/float_nan.rs
index cadbbd5..3ffdb68 100644
--- a/src/tools/miri/tests/pass/float_nan.rs
+++ b/src/tools/miri/tests/pass/float_nan.rs
@@ -260,6 +260,7 @@ fn test_f32() {
 
     // Intrinsics
     let nan = F32::nan(Neg, Quiet, 0).as_f32();
+    let snan = F32::nan(Neg, Signaling, 1).as_f32();
     check_all_outcomes(
         HashSet::from_iter([F32::nan(Pos, Quiet, 0), F32::nan(Neg, Quiet, 0)]),
         || F32::from(f32::min(nan, nan)),
@@ -313,6 +314,18 @@ fn test_f32() {
         HashSet::from_iter([F32::nan(Pos, Quiet, 0), F32::nan(Neg, Quiet, 0)]),
         || F32::from(nan.ln_gamma().0),
     );
+    check_all_outcomes(
+        HashSet::from_iter([
+            F32::from(1.0),
+            F32::nan(Pos, Quiet, 0),
+            F32::nan(Neg, Quiet, 0),
+            F32::nan(Pos, Quiet, 1),
+            F32::nan(Neg, Quiet, 1),
+            F32::nan(Pos, Signaling, 1),
+            F32::nan(Neg, Signaling, 1),
+        ]),
+        || F32::from(snan.powf(0.0)),
+    );
 }
 
 fn test_f64() {
@@ -376,6 +389,7 @@ fn test_f64() {
 
     // Intrinsics
     let nan = F64::nan(Neg, Quiet, 0).as_f64();
+    let snan = F64::nan(Neg, Signaling, 1).as_f64();
     check_all_outcomes(
         HashSet::from_iter([F64::nan(Pos, Quiet, 0), F64::nan(Neg, Quiet, 0)]),
         || F64::from(f64::min(nan, nan)),
@@ -433,6 +447,18 @@ fn test_f64() {
         HashSet::from_iter([F64::nan(Pos, Quiet, 0), F64::nan(Neg, Quiet, 0)]),
         || F64::from(nan.ln_gamma().0),
     );
+    check_all_outcomes(
+        HashSet::from_iter([
+            F64::from(1.0),
+            F64::nan(Pos, Quiet, 0),
+            F64::nan(Neg, Quiet, 0),
+            F64::nan(Pos, Quiet, 1),
+            F64::nan(Neg, Quiet, 1),
+            F64::nan(Pos, Signaling, 1),
+            F64::nan(Neg, Signaling, 1),
+        ]),
+        || F64::from(snan.powf(0.0)),
+    );
 }
 
 fn test_casts() {
diff --git a/src/tools/opt-dist/src/tests.rs b/src/tools/opt-dist/src/tests.rs
index 53ce772..705a175 100644
--- a/src/tools/opt-dist/src/tests.rs
+++ b/src/tools/opt-dist/src/tests.rs
@@ -72,6 +72,8 @@ pub fn run_tests(env: &Environment) -> anyhow::Result<()> {
 [rust]
 channel = "{channel}"
 verbose-tests = true
+# rust-lld cannot be combined with an external LLVM
+lld = false
 
 [build]
 rustc = "{rustc}"
diff --git a/src/tools/run-make-support/Cargo.toml b/src/tools/run-make-support/Cargo.toml
index 15ed03a..3226f46 100644
--- a/src/tools/run-make-support/Cargo.toml
+++ b/src/tools/run-make-support/Cargo.toml
@@ -4,12 +4,12 @@
 edition = "2021"
 
 [dependencies]
-bstr = "1.6.0"
-object = "0.36.2"
-similar = "2.5.0"
+bstr = "1.12"
+object = "0.37"
+similar = "2.7"
 wasmparser = { version = "0.219", default-features = false, features = ["std"] }
-regex = "1.8" # 1.8 to avoid memchr 2.6.0, as 2.5.0 is pinned in the workspace
-gimli = "0.31.0"
+regex = "1.11"
+gimli = "0.32"
 build_helper = { path = "../../build_helper" }
 serde_json = "1.0"
 libc = "0.2"
diff --git a/src/tools/rust-analyzer/.github/workflows/ci.yaml b/src/tools/rust-analyzer/.github/workflows/ci.yaml
index 79fb7a2..7706524 100644
--- a/src/tools/rust-analyzer/.github/workflows/ci.yaml
+++ b/src/tools/rust-analyzer/.github/workflows/ci.yaml
@@ -17,6 +17,10 @@
   RUST_BACKTRACE: short
   RUSTUP_MAX_RETRIES: 10
 
+defaults:
+  run:
+    shell: bash
+
 jobs:
   changes:
     runs-on: ubuntu-latest
@@ -80,6 +84,7 @@
       CC: deny_c
 
     strategy:
+      fail-fast: false
       matrix:
         os: [ubuntu-latest, windows-latest, macos-latest]
 
@@ -99,7 +104,7 @@
           rustup toolchain install nightly --profile minimal --component rustfmt
       # https://github.com/actions-rust-lang/setup-rust-toolchain/blob/main/rust.json
       - name: Install Rust Problem Matcher
-        if: matrix.os == 'ubuntu-latest'
+        if: matrix.os == 'macos-latest'
         run: echo "::add-matcher::.github/rust.json"
 
       # - name: Cache Dependencies
@@ -116,23 +121,9 @@
         if: matrix.os == 'ubuntu-latest'
         run: cargo codegen --check
 
-      - name: Compile tests
-        run: cargo test --no-run
-
       - name: Run tests
         run: cargo nextest run --no-fail-fast --hide-progress-bar --status-level fail
 
-      - name: Cancel parallel jobs
-        if: failure()
-        run: |
-          # https://docs.github.com/en/rest/actions/workflow-runs?apiVersion=2022-11-28#cancel-a-workflow-run
-          curl -L \
-          -X POST \
-          -H "Accept: application/vnd.github.v3+json" \
-          -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
-          -H "X-GitHub-Api-Version: 2022-11-28" \
-          https://api.github.com/repos/${{ github.repository }}/actions/runs/${{ github.run_id }}/cancel
-
       - name: Run Clippy
         if: matrix.os == 'macos-latest'
         run: cargo clippy --all-targets -- -D clippy::disallowed_macros -D clippy::dbg_macro -D clippy::todo -D clippy::print_stdout -D clippy::print_stderr
@@ -333,3 +324,21 @@
           jq -C <<< '${{ toJson(needs) }}'
           # Check if all jobs that we depend on (in the needs array) were successful (or have been skipped).
           jq --exit-status 'all(.result == "success" or .result == "skipped")' <<< '${{ toJson(needs) }}'
+
+  cancel-if-matrix-failed:
+    needs: rust
+    if: ${{ always() }}
+    runs-on: ubuntu-latest
+    steps:
+      - name: Cancel parallel jobs
+        run: |
+          if jq --exit-status 'all(.result == "success" or .result == "skipped")' <<< '${{ toJson(needs) }}'; then
+            exit 0
+          fi
+          # https://docs.github.com/en/rest/actions/workflow-runs?apiVersion=2022-11-28#cancel-a-workflow-run
+          curl -L \
+          -X POST \
+          -H "Accept: application/vnd.github.v3+json" \
+          -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
+          -H "X-GitHub-Api-Version: 2022-11-28" \
+          https://api.github.com/repos/${{ github.repository }}/actions/runs/${{ github.run_id }}/cancel
diff --git a/src/tools/rust-analyzer/.github/workflows/release.yaml b/src/tools/rust-analyzer/.github/workflows/release.yaml
index a758ecf..5bd9013 100644
--- a/src/tools/rust-analyzer/.github/workflows/release.yaml
+++ b/src/tools/rust-analyzer/.github/workflows/release.yaml
@@ -134,13 +134,13 @@
 
       - name: Run analysis-stats on rust-analyzer
         if: matrix.target == 'x86_64-unknown-linux-gnu'
-        run: target/${{ matrix.target }}/release/rust-analyzer analysis-stats .
+        run: target/${{ matrix.target }}/release/rust-analyzer analysis-stats . -q
 
       - name: Run analysis-stats on rust std library
         if: matrix.target == 'x86_64-unknown-linux-gnu'
         env:
           RUSTC_BOOTSTRAP: 1
-        run: target/${{ matrix.target }}/release/rust-analyzer analysis-stats --with-deps $(rustc --print sysroot)/lib/rustlib/src/rust/library/std
+        run: target/${{ matrix.target }}/release/rust-analyzer analysis-stats --with-deps $(rustc --print sysroot)/lib/rustlib/src/rust/library/std -q
 
       - name: Upload artifacts
         uses: actions/upload-artifact@v4
diff --git a/src/tools/rust-analyzer/Cargo.lock b/src/tools/rust-analyzer/Cargo.lock
index 2c7b464..caa8f28 100644
--- a/src/tools/rust-analyzer/Cargo.lock
+++ b/src/tools/rust-analyzer/Cargo.lock
@@ -1458,7 +1458,7 @@
  "edition",
  "expect-test",
  "ra-ap-rustc_lexer",
- "rustc-literal-escaper 0.0.3",
+ "rustc-literal-escaper 0.0.4",
  "stdx",
  "tracing",
 ]
@@ -1927,9 +1927,9 @@
 
 [[package]]
 name = "rustc-literal-escaper"
-version = "0.0.3"
+version = "0.0.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "78744cd17f5d01c75b709e49807d1363e02a940ccee2e9e72435843fdb0d076e"
+checksum = "ab03008eb631b703dd16978282ae36c73282e7922fe101a4bd072a40ecea7b8b"
 
 [[package]]
 name = "rustc-stable-hash"
@@ -2207,7 +2207,7 @@
  "rayon",
  "rowan",
  "rustc-hash 2.1.1",
- "rustc-literal-escaper 0.0.3",
+ "rustc-literal-escaper 0.0.4",
  "rustc_apfloat",
  "smol_str",
  "stdx",
diff --git a/src/tools/rust-analyzer/Cargo.toml b/src/tools/rust-analyzer/Cargo.toml
index 449c758..0a8e6fe 100644
--- a/src/tools/rust-analyzer/Cargo.toml
+++ b/src/tools/rust-analyzer/Cargo.toml
@@ -143,7 +143,7 @@
 serde_derive = { version = "1.0.219" }
 serde_json = "1.0.140"
 rustc-hash = "2.1.1"
-rustc-literal-escaper = "0.0.3"
+rustc-literal-escaper = "0.0.4"
 smallvec = { version = "1.15.1", features = [
   "const_new",
   "union",
diff --git a/src/tools/rust-analyzer/crates/base-db/Cargo.toml b/src/tools/rust-analyzer/crates/base-db/Cargo.toml
index 3b423a8..ea06fd9 100644
--- a/src/tools/rust-analyzer/crates/base-db/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/base-db/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 la-arena.workspace = true
diff --git a/src/tools/rust-analyzer/crates/cfg/Cargo.toml b/src/tools/rust-analyzer/crates/cfg/Cargo.toml
index d7764a1..ba34966 100644
--- a/src/tools/rust-analyzer/crates/cfg/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/cfg/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 rustc-hash.workspace = true
diff --git a/src/tools/rust-analyzer/crates/hir-def/Cargo.toml b/src/tools/rust-analyzer/crates/hir-def/Cargo.toml
index c6922ec..abb4819 100644
--- a/src/tools/rust-analyzer/crates/hir-def/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/hir-def/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 arrayvec.workspace = true
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/db.rs b/src/tools/rust-analyzer/crates/hir-def/src/db.rs
index 00408e9..c67bb24 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/db.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/db.rs
@@ -25,11 +25,10 @@
     import_map::ImportMap,
     item_tree::{ItemTree, file_item_tree_query},
     lang_item::{self, LangItem},
-    nameres::{assoc::TraitItems, crate_def_map, diagnostics::DefDiagnostics},
+    nameres::crate_def_map,
     signatures::{
         ConstSignature, EnumSignature, FunctionSignature, ImplSignature, StaticSignature,
         StructSignature, TraitAliasSignature, TraitSignature, TypeAliasSignature, UnionSignature,
-        VariantFields,
     },
     tt,
     visibility::{self, Visibility},
@@ -113,24 +112,6 @@ pub trait DefDatabase: InternDatabase + ExpandDatabase + SourceDatabase {
 
     // region:data
 
-    #[salsa::invoke(VariantFields::query)]
-    fn variant_fields_with_source_map(
-        &self,
-        id: VariantId,
-    ) -> (Arc<VariantFields>, Arc<ExpressionStoreSourceMap>);
-
-    #[salsa::transparent]
-    #[salsa::invoke(TraitItems::trait_items_query)]
-    fn trait_items(&self, e: TraitId) -> Arc<TraitItems>;
-
-    #[salsa::invoke(TraitItems::trait_items_with_diagnostics_query)]
-    fn trait_items_with_diagnostics(&self, tr: TraitId) -> (Arc<TraitItems>, DefDiagnostics);
-
-    #[salsa::tracked]
-    fn variant_fields(&self, id: VariantId) -> Arc<VariantFields> {
-        self.variant_fields_with_source_map(id).0
-    }
-
     #[salsa::tracked]
     fn trait_signature(&self, trait_: TraitId) -> Arc<TraitSignature> {
         self.trait_signature_with_source_map(trait_).0
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/expr_store.rs b/src/tools/rust-analyzer/crates/hir-def/src/expr_store.rs
index f617c32..85bd193 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/expr_store.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/expr_store.rs
@@ -9,7 +9,10 @@
 #[cfg(test)]
 mod tests;
 
-use std::ops::{Deref, Index};
+use std::{
+    ops::{Deref, Index},
+    sync::LazyLock,
+};
 
 use cfg::{CfgExpr, CfgOptions};
 use either::Either;
@@ -19,6 +22,7 @@
 use smallvec::SmallVec;
 use span::{Edition, SyntaxContext};
 use syntax::{AstPtr, SyntaxNodePtr, ast};
+use triomphe::Arc;
 use tt::TextRange;
 
 use crate::{
@@ -220,6 +224,12 @@ pub fn finish(self) -> ExpressionStore {
 }
 
 impl ExpressionStore {
+    pub fn empty_singleton() -> Arc<Self> {
+        static EMPTY: LazyLock<Arc<ExpressionStore>> =
+            LazyLock::new(|| Arc::new(ExpressionStoreBuilder::default().finish()));
+        EMPTY.clone()
+    }
+
     /// Returns an iterator over all block expressions in this store that define inner items.
     pub fn blocks<'a>(
         &'a self,
@@ -636,6 +646,12 @@ fn index(&self, index: PathId) -> &Self::Output {
 // FIXME: Change `node_` prefix to something more reasonable.
 // Perhaps `expr_syntax` and `expr_id`?
 impl ExpressionStoreSourceMap {
+    pub fn empty_singleton() -> Arc<Self> {
+        static EMPTY: LazyLock<Arc<ExpressionStoreSourceMap>> =
+            LazyLock::new(|| Arc::new(ExpressionStoreSourceMap::default()));
+        EMPTY.clone()
+    }
+
     pub fn expr_or_pat_syntax(&self, id: ExprOrPatId) -> Result<ExprOrPatSource, SyntheticSyntax> {
         match id {
             ExprOrPatId::ExprId(id) => self.expr_syntax(id),
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/expr_store/lower.rs b/src/tools/rust-analyzer/crates/hir-def/src/expr_store/lower.rs
index efa1374..c0e51b3 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/expr_store/lower.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/expr_store/lower.rs
@@ -2250,7 +2250,7 @@ fn collect_pat(&mut self, pat: ast::Pat, binding_list: &mut BindingList) -> PatI
                         Some(ModuleDefId::ConstId(_)) => (None, Pat::Path(name.into())),
                         Some(ModuleDefId::EnumVariantId(variant))
                         // FIXME: This can cause a cycle if the user is writing invalid code
-                            if self.db.variant_fields(variant.into()).shape != FieldsShape::Record =>
+                            if variant.fields(self.db).shape != FieldsShape::Record =>
                         {
                             (None, Pat::Path(name.into()))
                         }
@@ -2825,14 +2825,7 @@ fn collect_format_args(
         let use_format_args_since_1_89_0 = fmt_args().is_some() && fmt_unsafe_arg().is_none();
 
         let idx = if use_format_args_since_1_89_0 {
-            self.collect_format_args_impl(
-                syntax_ptr,
-                fmt,
-                hygiene,
-                argmap,
-                lit_pieces,
-                format_options,
-            )
+            self.collect_format_args_impl(syntax_ptr, fmt, argmap, lit_pieces, format_options)
         } else {
             self.collect_format_args_before_1_89_0_impl(
                 syntax_ptr,
@@ -2962,7 +2955,6 @@ fn collect_format_args_impl(
         &mut self,
         syntax_ptr: AstPtr<ast::Expr>,
         fmt: FormatArgs,
-        hygiene: HygieneId,
         argmap: FxIndexSet<(usize, ArgumentType)>,
         lit_pieces: ExprId,
         format_options: ExprId,
@@ -2997,8 +2989,11 @@ fn collect_format_args_impl(
             let args =
                 self.alloc_expr_desugared(Expr::Array(Array::ElementList { elements: args }));
             let args_name = Name::new_symbol_root(sym::args);
-            let args_binding =
-                self.alloc_binding(args_name.clone(), BindingAnnotation::Unannotated, hygiene);
+            let args_binding = self.alloc_binding(
+                args_name.clone(),
+                BindingAnnotation::Unannotated,
+                HygieneId::ROOT,
+            );
             let args_pat = self.alloc_pat_desugared(Pat::Bind { id: args_binding, subpat: None });
             self.add_definition_to_binding(args_binding, args_pat);
             // TODO: We don't have `super let` yet.
@@ -3008,13 +3003,16 @@ fn collect_format_args_impl(
                 initializer: Some(args),
                 else_branch: None,
             };
-            (vec![let_stmt], self.alloc_expr_desugared(Expr::Path(Path::from(args_name))))
+            (vec![let_stmt], self.alloc_expr_desugared(Expr::Path(args_name.into())))
         } else {
             // Generate:
             //     super let args = (&arg0, &arg1, &...);
             let args_name = Name::new_symbol_root(sym::args);
-            let args_binding =
-                self.alloc_binding(args_name.clone(), BindingAnnotation::Unannotated, hygiene);
+            let args_binding = self.alloc_binding(
+                args_name.clone(),
+                BindingAnnotation::Unannotated,
+                HygieneId::ROOT,
+            );
             let args_pat = self.alloc_pat_desugared(Pat::Bind { id: args_binding, subpat: None });
             self.add_definition_to_binding(args_binding, args_pat);
             let elements = arguments
@@ -3057,8 +3055,11 @@ fn collect_format_args_impl(
                 .collect();
             let array =
                 self.alloc_expr_desugared(Expr::Array(Array::ElementList { elements: args }));
-            let args_binding =
-                self.alloc_binding(args_name.clone(), BindingAnnotation::Unannotated, hygiene);
+            let args_binding = self.alloc_binding(
+                args_name.clone(),
+                BindingAnnotation::Unannotated,
+                HygieneId::ROOT,
+            );
             let args_pat = self.alloc_pat_desugared(Pat::Bind { id: args_binding, subpat: None });
             self.add_definition_to_binding(args_binding, args_pat);
             let let_stmt2 = Statement::Let {
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/expr_store/pretty.rs b/src/tools/rust-analyzer/crates/hir-def/src/expr_store/pretty.rs
index 56c7655..87bcd33 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/expr_store/pretty.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/expr_store/pretty.rs
@@ -121,7 +121,7 @@ pub fn print_variant_body_hir(db: &dyn DefDatabase, owner: VariantId, edition: E
         VariantId::UnionId(it) => format!("union {}", item_name(db, it, "<missing>")),
     };
 
-    let fields = db.variant_fields(owner);
+    let fields = owner.fields(db);
 
     let mut p = Printer {
         db,
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/hir/generics.rs b/src/tools/rust-analyzer/crates/hir-def/src/hir/generics.rs
index a9a0e36..94e683c 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/hir/generics.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/hir/generics.rs
@@ -331,13 +331,13 @@ pub fn is_empty(&self) -> bool {
     }
 
     #[inline]
-    pub fn no_predicates(&self) -> bool {
+    pub fn has_no_predicates(&self) -> bool {
         self.where_predicates.is_empty()
     }
 
     #[inline]
-    pub fn where_predicates(&self) -> std::slice::Iter<'_, WherePredicate> {
-        self.where_predicates.iter()
+    pub fn where_predicates(&self) -> &[WherePredicate] {
+        &self.where_predicates
     }
 
     /// Iterator of type_or_consts field
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/import_map.rs b/src/tools/rust-analyzer/crates/hir-def/src/import_map.rs
index a6138fb..f31f355 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/import_map.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/import_map.rs
@@ -16,7 +16,7 @@
     AssocItemId, AttrDefId, Complete, FxIndexMap, ModuleDefId, ModuleId, TraitId,
     db::DefDatabase,
     item_scope::{ImportOrExternCrate, ItemInNs},
-    nameres::{DefMap, crate_def_map},
+    nameres::{DefMap, assoc::TraitItems, crate_def_map},
     visibility::Visibility,
 };
 
@@ -221,7 +221,7 @@ fn collect_trait_assoc_items(
         trait_import_info: &ImportInfo,
     ) {
         let _p = tracing::info_span!("collect_trait_assoc_items").entered();
-        for &(ref assoc_item_name, item) in &db.trait_items(tr).items {
+        for &(ref assoc_item_name, item) in &TraitItems::query(db, tr).items {
             let module_def_id = match item {
                 AssocItemId::FunctionId(f) => ModuleDefId::from(f),
                 AssocItemId::ConstId(c) => ModuleDefId::from(c),
@@ -482,7 +482,7 @@ mod tests {
     use expect_test::{Expect, expect};
     use test_fixture::WithFixture;
 
-    use crate::{ItemContainerId, Lookup, test_db::TestDB};
+    use crate::{ItemContainerId, Lookup, nameres::assoc::TraitItems, test_db::TestDB};
 
     use super::*;
 
@@ -580,7 +580,7 @@ fn assoc_item_path(
 
         let trait_info = dependency_imports.import_info_for(ItemInNs::Types(trait_id.into()))?;
 
-        let trait_items = db.trait_items(trait_id);
+        let trait_items = TraitItems::query(db, trait_id);
         let (assoc_item_name, _) = trait_items
             .items
             .iter()
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/lang_item.rs b/src/tools/rust-analyzer/crates/hir-def/src/lang_item.rs
index faff7d0..7503080 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/lang_item.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/lang_item.rs
@@ -9,8 +9,10 @@
 
 use crate::{
     AdtId, AssocItemId, AttrDefId, Crate, EnumId, EnumVariantId, FunctionId, ImplId, ModuleDefId,
-    StaticId, StructId, TraitId, TypeAliasId, UnionId, db::DefDatabase, expr_store::path::Path,
-    nameres::crate_def_map,
+    StaticId, StructId, TraitId, TypeAliasId, UnionId,
+    db::DefDatabase,
+    expr_store::path::Path,
+    nameres::{assoc::TraitItems, crate_def_map},
 };
 
 #[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
@@ -113,14 +115,16 @@ pub fn crate_lang_items(db: &dyn DefDatabase, krate: Crate) -> Option<Box<LangIt
             match def {
                 ModuleDefId::TraitId(trait_) => {
                     lang_items.collect_lang_item(db, trait_, LangItemTarget::Trait);
-                    db.trait_items(trait_).items.iter().for_each(|&(_, assoc_id)| match assoc_id {
-                        AssocItemId::FunctionId(f) => {
-                            lang_items.collect_lang_item(db, f, LangItemTarget::Function);
+                    TraitItems::query(db, trait_).items.iter().for_each(|&(_, assoc_id)| {
+                        match assoc_id {
+                            AssocItemId::FunctionId(f) => {
+                                lang_items.collect_lang_item(db, f, LangItemTarget::Function);
+                            }
+                            AssocItemId::TypeAliasId(alias) => {
+                                lang_items.collect_lang_item(db, alias, LangItemTarget::TypeAlias)
+                            }
+                            AssocItemId::ConstId(_) => {}
                         }
-                        AssocItemId::TypeAliasId(alias) => {
-                            lang_items.collect_lang_item(db, alias, LangItemTarget::TypeAlias)
-                        }
-                        AssocItemId::ConstId(_) => {}
                     });
                 }
                 ModuleDefId::AdtId(AdtId::EnumId(e)) => {
@@ -304,6 +308,8 @@ pub fn ty_rel_path(&self, db: &dyn DefDatabase, start_crate: Crate, seg: Name) -
 language_item_table! {
 //  Variant name,            Name,                     Getter method name,         Target                  Generic requirements;
     Sized,                   sym::sized,               sized_trait,                Target::Trait,          GenericRequirement::Exact(0);
+    MetaSized,               sym::meta_sized,          sized_trait,                Target::Trait,          GenericRequirement::Exact(0);
+    PointeeSized,            sym::pointee_sized,       sized_trait,                Target::Trait,          GenericRequirement::Exact(0);
     Unsize,                  sym::unsize,              unsize_trait,               Target::Trait,          GenericRequirement::Minimum(1);
     /// Trait injected by `#[derive(PartialEq)]`, (i.e. "Partial EQ").
     StructuralPeq,           sym::structural_peq,      structural_peq_trait,       Target::Trait,          GenericRequirement::None;
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/lib.rs b/src/tools/rust-analyzer/crates/hir-def/src/lib.rs
index a562f2d..bdf8b45 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/lib.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/lib.rs
@@ -87,9 +87,12 @@
     attr::Attrs,
     builtin_type::BuiltinType,
     db::DefDatabase,
+    expr_store::ExpressionStoreSourceMap,
     hir::generics::{LocalLifetimeParamId, LocalTypeOrConstParamId},
     nameres::{
-        LocalDefMap, assoc::ImplItems, block_def_map, crate_def_map, crate_local_def_map,
+        LocalDefMap,
+        assoc::{ImplItems, TraitItems},
+        block_def_map, crate_def_map, crate_local_def_map,
         diagnostics::DefDiagnostics,
     },
     signatures::{EnumVariants, InactiveEnumVariantCode, VariantFields},
@@ -252,9 +255,35 @@ fn module(&self, db: &dyn DefDatabase) -> ModuleId {
 type StructLoc = ItemLoc<ast::Struct>;
 impl_intern!(StructId, StructLoc, intern_struct, lookup_intern_struct);
 
+impl StructId {
+    pub fn fields(self, db: &dyn DefDatabase) -> &VariantFields {
+        VariantFields::firewall(db, self.into())
+    }
+
+    pub fn fields_with_source_map(
+        self,
+        db: &dyn DefDatabase,
+    ) -> (Arc<VariantFields>, Arc<ExpressionStoreSourceMap>) {
+        VariantFields::query(db, self.into())
+    }
+}
+
 pub type UnionLoc = ItemLoc<ast::Union>;
 impl_intern!(UnionId, UnionLoc, intern_union, lookup_intern_union);
 
+impl UnionId {
+    pub fn fields(self, db: &dyn DefDatabase) -> &VariantFields {
+        VariantFields::firewall(db, self.into())
+    }
+
+    pub fn fields_with_source_map(
+        self,
+        db: &dyn DefDatabase,
+    ) -> (Arc<VariantFields>, Arc<ExpressionStoreSourceMap>) {
+        VariantFields::query(db, self.into())
+    }
+}
+
 pub type EnumLoc = ItemLoc<ast::Enum>;
 impl_intern!(EnumId, EnumLoc, intern_enum, lookup_intern_enum);
 
@@ -282,6 +311,13 @@ pub fn enum_variants_with_diagnostics(
 pub type TraitLoc = ItemLoc<ast::Trait>;
 impl_intern!(TraitId, TraitLoc, intern_trait, lookup_intern_trait);
 
+impl TraitId {
+    #[inline]
+    pub fn trait_items(self, db: &dyn DefDatabase) -> &TraitItems {
+        TraitItems::query(db, self)
+    }
+}
+
 pub type TraitAliasLoc = ItemLoc<ast::TraitAlias>;
 impl_intern!(TraitAliasId, TraitAliasLoc, intern_trait_alias, lookup_intern_trait_alias);
 
@@ -328,6 +364,20 @@ pub struct EnumVariantLoc {
 }
 impl_intern!(EnumVariantId, EnumVariantLoc, intern_enum_variant, lookup_intern_enum_variant);
 impl_loc!(EnumVariantLoc, id: Variant, parent: EnumId);
+
+impl EnumVariantId {
+    pub fn fields(self, db: &dyn DefDatabase) -> &VariantFields {
+        VariantFields::firewall(db, self.into())
+    }
+
+    pub fn fields_with_source_map(
+        self,
+        db: &dyn DefDatabase,
+    ) -> (Arc<VariantFields>, Arc<ExpressionStoreSourceMap>) {
+        VariantFields::query(db, self.into())
+    }
+}
+
 #[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
 pub struct Macro2Loc {
     pub container: ModuleId,
@@ -1015,8 +1065,15 @@ pub enum VariantId {
 impl_from!(EnumVariantId, StructId, UnionId for VariantId);
 
 impl VariantId {
-    pub fn variant_data(self, db: &dyn DefDatabase) -> Arc<VariantFields> {
-        db.variant_fields(self)
+    pub fn fields(self, db: &dyn DefDatabase) -> &VariantFields {
+        VariantFields::firewall(db, self)
+    }
+
+    pub fn fields_with_source_map(
+        self,
+        db: &dyn DefDatabase,
+    ) -> (Arc<VariantFields>, Arc<ExpressionStoreSourceMap>) {
+        VariantFields::query(db, self)
     }
 
     pub fn file_id(self, db: &dyn DefDatabase) -> HirFileId {
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/nameres/assoc.rs b/src/tools/rust-analyzer/crates/hir-def/src/nameres/assoc.rs
index 7aaa918..07210df 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/nameres/assoc.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/nameres/assoc.rs
@@ -38,16 +38,18 @@ pub struct TraitItems {
     pub macro_calls: ThinVec<(AstId<ast::Item>, MacroCallId)>,
 }
 
+#[salsa::tracked]
 impl TraitItems {
     #[inline]
-    pub(crate) fn trait_items_query(db: &dyn DefDatabase, tr: TraitId) -> Arc<TraitItems> {
-        db.trait_items_with_diagnostics(tr).0
+    pub(crate) fn query(db: &dyn DefDatabase, tr: TraitId) -> &TraitItems {
+        &Self::query_with_diagnostics(db, tr).0
     }
 
-    pub(crate) fn trait_items_with_diagnostics_query(
+    #[salsa::tracked(returns(ref))]
+    pub fn query_with_diagnostics(
         db: &dyn DefDatabase,
         tr: TraitId,
-    ) -> (Arc<TraitItems>, DefDiagnostics) {
+    ) -> (TraitItems, DefDiagnostics) {
         let ItemLoc { container: module_id, id: ast_id } = tr.lookup(db);
 
         let collector =
@@ -55,7 +57,7 @@ pub(crate) fn trait_items_with_diagnostics_query(
         let source = ast_id.with_value(collector.ast_id_map.get(ast_id.value)).to_node(db);
         let (items, macro_calls, diagnostics) = collector.collect(source.assoc_item_list());
 
-        (Arc::new(TraitItems { macro_calls, items }), DefDiagnostics::new(diagnostics))
+        (TraitItems { macro_calls, items }, DefDiagnostics::new(diagnostics))
     }
 
     pub fn associated_types(&self) -> impl Iterator<Item = TypeAliasId> + '_ {
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/nameres/collector.rs b/src/tools/rust-analyzer/crates/hir-def/src/nameres/collector.rs
index 78fdc27..0c3274d 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/nameres/collector.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/nameres/collector.rs
@@ -41,6 +41,7 @@
     macro_call_as_call_id,
     nameres::{
         BuiltinShadowMode, DefMap, LocalDefMap, MacroSubNs, ModuleData, ModuleOrigin, ResolveMode,
+        assoc::TraitItems,
         attr_resolution::{attr_macro_as_call_id, derive_macro_as_call_id},
         crate_def_map,
         diagnostics::DefDiagnostic,
@@ -1020,8 +1021,7 @@ fn record_resolved_import(&mut self, directive: &ImportDirective) {
                         let resolutions = if true {
                             vec![]
                         } else {
-                            self.db
-                                .trait_items(it)
+                            TraitItems::query(self.db, it)
                                 .items
                                 .iter()
                                 .map(|&(ref name, variant)| {
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/nameres/path_resolution.rs b/src/tools/rust-analyzer/crates/hir-def/src/nameres/path_resolution.rs
index e8235b1..4641b22 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/nameres/path_resolution.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/nameres/path_resolution.rs
@@ -24,8 +24,8 @@
     item_scope::{BUILTIN_SCOPE, ImportOrExternCrate},
     item_tree::FieldsShape,
     nameres::{
-        BlockInfo, BuiltinShadowMode, DefMap, LocalDefMap, MacroSubNs, crate_def_map,
-        sub_namespace_match,
+        BlockInfo, BuiltinShadowMode, DefMap, LocalDefMap, MacroSubNs, assoc::TraitItems,
+        crate_def_map, sub_namespace_match,
     },
     per_ns::PerNs,
     visibility::{RawVisibility, Visibility},
@@ -584,8 +584,11 @@ fn resolve_remaining_segments<'a>(
                     // now resulting in a cycle.
                     // To properly implement this, trait item collection needs to be done in def map
                     // collection...
-                    let item =
-                        if true { None } else { db.trait_items(t).assoc_item_by_name(segment) };
+                    let item = if true {
+                        None
+                    } else {
+                        TraitItems::query(db, t).assoc_item_by_name(segment)
+                    };
                     return match item {
                         Some(item) => ResolvePathResult::new(
                             match item {
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/signatures.rs b/src/tools/rust-analyzer/crates/hir-def/src/signatures.rs
index 377a545..1958eb6 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/signatures.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/signatures.rs
@@ -1,6 +1,6 @@
 //! Item signature IR definitions
 
-use std::ops::Not as _;
+use std::{cell::LazyCell, ops::Not as _};
 
 use bitflags::bitflags;
 use cfg::{CfgExpr, CfgOptions};
@@ -731,29 +731,26 @@ pub struct VariantFields {
     pub store: Arc<ExpressionStore>,
     pub shape: FieldsShape,
 }
+
+#[salsa::tracked]
 impl VariantFields {
-    #[inline]
+    #[salsa::tracked(returns(clone))]
     pub(crate) fn query(
         db: &dyn DefDatabase,
         id: VariantId,
     ) -> (Arc<Self>, Arc<ExpressionStoreSourceMap>) {
-        let (shape, (fields, store, source_map)) = match id {
+        let (shape, result) = match id {
             VariantId::EnumVariantId(id) => {
                 let loc = id.lookup(db);
                 let parent = loc.parent.lookup(db);
                 let source = loc.source(db);
                 let shape = adt_shape(source.value.kind());
-                let span_map = db.span_map(source.file_id);
-                let override_visibility = visibility_from_ast(
-                    db,
-                    source.value.parent_enum().visibility(),
-                    &mut |range| span_map.span_for_range(range).ctx,
-                );
+                let enum_vis = Some(source.value.parent_enum().visibility());
                 let fields = lower_field_list(
                     db,
                     parent.container,
                     source.map(|src| src.field_list()),
-                    Some(override_visibility),
+                    enum_vis,
                 );
                 (shape, fields)
             }
@@ -777,10 +774,29 @@ pub(crate) fn query(
                 (FieldsShape::Record, fields)
             }
         };
-
-        (Arc::new(VariantFields { fields, store: Arc::new(store), shape }), Arc::new(source_map))
+        match result {
+            Some((fields, store, source_map)) => (
+                Arc::new(VariantFields { fields, store: Arc::new(store), shape }),
+                Arc::new(source_map),
+            ),
+            None => (
+                Arc::new(VariantFields {
+                    fields: Arena::default(),
+                    store: ExpressionStore::empty_singleton(),
+                    shape,
+                }),
+                ExpressionStoreSourceMap::empty_singleton(),
+            ),
+        }
     }
 
+    #[salsa::tracked(returns(deref))]
+    pub(crate) fn firewall(db: &dyn DefDatabase, id: VariantId) -> Arc<Self> {
+        Self::query(db, id).0
+    }
+}
+
+impl VariantFields {
     pub fn len(&self) -> usize {
         self.fields.len()
     }
@@ -798,31 +814,24 @@ fn lower_field_list(
     db: &dyn DefDatabase,
     module: ModuleId,
     fields: InFile<Option<ast::FieldList>>,
-    override_visibility: Option<RawVisibility>,
-) -> (Arena<FieldData>, ExpressionStore, ExpressionStoreSourceMap) {
+    override_visibility: Option<Option<ast::Visibility>>,
+) -> Option<(Arena<FieldData>, ExpressionStore, ExpressionStoreSourceMap)> {
     let file_id = fields.file_id;
-    match fields.value {
-        Some(ast::FieldList::RecordFieldList(fields)) => lower_fields(
+    match fields.value? {
+        ast::FieldList::RecordFieldList(fields) => lower_fields(
             db,
             module,
             InFile::new(file_id, fields.fields().map(|field| (field.ty(), field))),
             |_, field| as_name_opt(field.name()),
             override_visibility,
         ),
-        Some(ast::FieldList::TupleFieldList(fields)) => lower_fields(
+        ast::FieldList::TupleFieldList(fields) => lower_fields(
             db,
             module,
             InFile::new(file_id, fields.fields().map(|field| (field.ty(), field))),
             |idx, _| Name::new_tuple_field(idx),
             override_visibility,
         ),
-        None => lower_fields(
-            db,
-            module,
-            InFile::new(file_id, std::iter::empty::<(Option<ast::Type>, ast::RecordField)>()),
-            |_, _| Name::missing(),
-            None,
-        ),
     }
 }
 
@@ -831,22 +840,34 @@ fn lower_fields<Field: ast::HasAttrs + ast::HasVisibility>(
     module: ModuleId,
     fields: InFile<impl Iterator<Item = (Option<ast::Type>, Field)>>,
     mut field_name: impl FnMut(usize, &Field) -> Name,
-    override_visibility: Option<RawVisibility>,
-) -> (Arena<FieldData>, ExpressionStore, ExpressionStoreSourceMap) {
-    let mut arena = Arena::new();
+    override_visibility: Option<Option<ast::Visibility>>,
+) -> Option<(Arena<FieldData>, ExpressionStore, ExpressionStoreSourceMap)> {
     let cfg_options = module.krate.cfg_options(db);
     let mut col = ExprCollector::new(db, module, fields.file_id);
+    let override_visibility = override_visibility.map(|vis| {
+        LazyCell::new(|| {
+            let span_map = db.span_map(fields.file_id);
+            visibility_from_ast(db, vis, &mut |range| span_map.span_for_range(range).ctx)
+        })
+    });
+
+    let mut arena = Arena::new();
     let mut idx = 0;
+    let mut has_fields = false;
     for (ty, field) in fields.value {
+        has_fields = true;
         match Attrs::is_cfg_enabled_for(db, &field, col.span_map(), cfg_options) {
             Ok(()) => {
                 let type_ref =
                     col.lower_type_ref_opt(ty, &mut ExprCollector::impl_trait_error_allocator);
-                let visibility = override_visibility.clone().unwrap_or_else(|| {
-                    visibility_from_ast(db, field.visibility(), &mut |range| {
-                        col.span_map().span_for_range(range).ctx
-                    })
-                });
+                let visibility = override_visibility.as_ref().map_or_else(
+                    || {
+                        visibility_from_ast(db, field.visibility(), &mut |range| {
+                            col.span_map().span_for_range(range).ctx
+                        })
+                    },
+                    |it| RawVisibility::clone(it),
+                );
                 let is_unsafe = field
                     .syntax()
                     .children_with_tokens()
@@ -867,9 +888,12 @@ fn lower_fields<Field: ast::HasAttrs + ast::HasVisibility>(
             }
         }
     }
+    if !has_fields {
+        return None;
+    }
     let store = col.store.finish();
     arena.shrink_to_fit();
-    (arena, store, col.source_map)
+    Some((arena, store, col.source_map))
 }
 
 #[derive(Debug, PartialEq, Eq)]
@@ -948,7 +972,7 @@ pub fn is_payload_free(&self, db: &dyn DefDatabase) -> bool {
         self.variants.iter().all(|&(v, _, _)| {
             // The condition check order is slightly modified from rustc
             // to improve performance by early returning with relatively fast checks
-            let variant = &db.variant_fields(v.into());
+            let variant = v.fields(db);
             if !variant.fields().is_empty() {
                 return false;
             }
diff --git a/src/tools/rust-analyzer/crates/hir-def/src/visibility.rs b/src/tools/rust-analyzer/crates/hir-def/src/visibility.rs
index 2514e88..b5eb84c 100644
--- a/src/tools/rust-analyzer/crates/hir-def/src/visibility.rs
+++ b/src/tools/rust-analyzer/crates/hir-def/src/visibility.rs
@@ -273,7 +273,7 @@ pub(crate) fn field_visibilities_query(
     db: &dyn DefDatabase,
     variant_id: VariantId,
 ) -> Arc<ArenaMap<LocalFieldId, Visibility>> {
-    let variant_fields = db.variant_fields(variant_id);
+    let variant_fields = variant_id.fields(db);
     let fields = variant_fields.fields();
     if fields.is_empty() {
         return Arc::default();
diff --git a/src/tools/rust-analyzer/crates/hir-expand/Cargo.toml b/src/tools/rust-analyzer/crates/hir-expand/Cargo.toml
index ed818c5..80a3c08 100644
--- a/src/tools/rust-analyzer/crates/hir-expand/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/hir-expand/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/hir-expand/src/attrs.rs b/src/tools/rust-analyzer/crates/hir-expand/src/attrs.rs
index 94c9771..986f876 100644
--- a/src/tools/rust-analyzer/crates/hir-expand/src/attrs.rs
+++ b/src/tools/rust-analyzer/crates/hir-expand/src/attrs.rs
@@ -433,20 +433,19 @@ fn unescape(s: &str) -> Option<Cow<'_, str>> {
     let mut buf = String::new();
     let mut prev_end = 0;
     let mut has_error = false;
-    unescape::unescape_unicode(s, unescape::Mode::Str, &mut |char_range, unescaped_char| match (
-        unescaped_char,
-        buf.capacity() == 0,
-    ) {
-        (Ok(c), false) => buf.push(c),
-        (Ok(_), true) if char_range.len() == 1 && char_range.start == prev_end => {
-            prev_end = char_range.end
+    unescape::unescape_str(s, |char_range, unescaped_char| {
+        match (unescaped_char, buf.capacity() == 0) {
+            (Ok(c), false) => buf.push(c),
+            (Ok(_), true) if char_range.len() == 1 && char_range.start == prev_end => {
+                prev_end = char_range.end
+            }
+            (Ok(c), true) => {
+                buf.reserve_exact(s.len());
+                buf.push_str(&s[..prev_end]);
+                buf.push(c);
+            }
+            (Err(_), _) => has_error = true,
         }
-        (Ok(c), true) => {
-            buf.reserve_exact(s.len());
-            buf.push_str(&s[..prev_end]);
-            buf.push(c);
-        }
-        (Err(_), _) => has_error = true,
     });
 
     match (has_error, buf.capacity() == 0) {
diff --git a/src/tools/rust-analyzer/crates/hir-expand/src/builtin/fn_macro.rs b/src/tools/rust-analyzer/crates/hir-expand/src/builtin/fn_macro.rs
index 3180b8d..f9abe4f 100644
--- a/src/tools/rust-analyzer/crates/hir-expand/src/builtin/fn_macro.rs
+++ b/src/tools/rust-analyzer/crates/hir-expand/src/builtin/fn_macro.rs
@@ -12,7 +12,7 @@
 use stdx::format_to;
 use syntax::{
     format_smolstr,
-    unescape::{Mode, unescape_byte, unescape_char, unescape_unicode},
+    unescape::{unescape_byte, unescape_char, unescape_str},
 };
 use syntax_bridge::syntax_node_to_token_tree;
 
@@ -430,7 +430,7 @@ fn compile_error_expand(
                 kind: tt::LitKind::Str | tt::LitKind::StrRaw(_),
                 suffix: _,
             })),
-        ] => ExpandError::other(span, Box::from(unescape_str(text).as_str())),
+        ] => ExpandError::other(span, Box::from(unescape_symbol(text).as_str())),
         _ => ExpandError::other(span, "`compile_error!` argument must be a string"),
     };
 
@@ -481,7 +481,7 @@ fn concat_expand(
                         format_to!(text, "{}", it.symbol.as_str())
                     }
                     tt::LitKind::Str => {
-                        text.push_str(unescape_str(&it.symbol).as_str());
+                        text.push_str(unescape_symbol(&it.symbol).as_str());
                         record_span(it.span);
                     }
                     tt::LitKind::StrRaw(_) => {
@@ -691,7 +691,7 @@ fn parse_string(tt: &tt::TopSubtree) -> Result<(Symbol, Span), ExpandError> {
                 span,
                 kind: tt::LitKind::Str,
                 suffix: _,
-            })) => Ok((unescape_str(text), *span)),
+            })) => Ok((unescape_symbol(text), *span)),
             TtElement::Leaf(tt::Leaf::Literal(tt::Literal {
                 symbol: text,
                 span,
@@ -712,7 +712,7 @@ fn parse_string(tt: &tt::TopSubtree) -> Result<(Symbol, Span), ExpandError> {
                             span,
                             kind: tt::LitKind::Str,
                             suffix: _,
-                        })) => Some((unescape_str(text), *span)),
+                        })) => Some((unescape_symbol(text), *span)),
                         TtElement::Leaf(tt::Leaf::Literal(tt::Literal {
                             symbol: text,
                             span,
@@ -897,11 +897,11 @@ fn quote_expand(
     )
 }
 
-fn unescape_str(s: &Symbol) -> Symbol {
+fn unescape_symbol(s: &Symbol) -> Symbol {
     if s.as_str().contains('\\') {
         let s = s.as_str();
         let mut buf = String::with_capacity(s.len());
-        unescape_unicode(s, Mode::Str, &mut |_, c| {
+        unescape_str(s, |_, c| {
             if let Ok(c) = c {
                 buf.push(c)
             }
diff --git a/src/tools/rust-analyzer/crates/hir-ty/Cargo.toml b/src/tools/rust-analyzer/crates/hir-ty/Cargo.toml
index 8b65126..7cc0a26 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/hir-ty/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/autoderef.rs b/src/tools/rust-analyzer/crates/hir-ty/src/autoderef.rs
index 7acc945..cc8f7bf 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/autoderef.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/autoderef.rs
@@ -208,7 +208,7 @@ pub(crate) fn deref_by_trait(
     };
     let trait_id = trait_id()?;
     let target =
-        db.trait_items(trait_id).associated_type_by_name(&Name::new_symbol_root(sym::Target))?;
+        trait_id.trait_items(db).associated_type_by_name(&Name::new_symbol_root(sym::Target))?;
 
     let projection = {
         let b = TyBuilder::subst_for_def(db, trait_id, None);
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/chalk_db.rs b/src/tools/rust-analyzer/crates/hir-ty/src/chalk_db.rs
index 7945442..26b6352 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/chalk_db.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/chalk_db.rs
@@ -315,9 +315,8 @@ fn opaque_ty_data(&self, id: chalk_ir::OpaqueTyId<Interner>) -> Arc<OpaqueTyDatu
             crate::ImplTraitId::AsyncBlockTypeImplTrait(..) => {
                 if let Some((future_trait, future_output)) =
                     LangItem::Future.resolve_trait(self.db, self.krate).and_then(|trait_| {
-                        let alias = self
-                            .db
-                            .trait_items(trait_)
+                        let alias = trait_
+                            .trait_items(self.db)
                             .associated_type_by_name(&Name::new_symbol_root(sym::Output))?;
                         Some((trait_, alias))
                     })
@@ -711,7 +710,7 @@ pub(crate) fn trait_datum_query(
     };
     let where_clauses = convert_where_clauses(db, trait_.into(), &bound_vars);
     let associated_ty_ids =
-        db.trait_items(trait_).associated_types().map(to_assoc_type_id).collect();
+        trait_.trait_items(db).associated_types().map(to_assoc_type_id).collect();
     let trait_datum_bound = rust_ir::TraitDatumBound { where_clauses };
     let well_known = db.lang_attr(trait_.into()).and_then(well_known_trait_from_lang_item);
     let trait_datum = TraitDatum {
@@ -802,7 +801,7 @@ pub(crate) fn adt_datum_query(
 
     // this slows down rust-analyzer by quite a bit unfortunately, so enabling this is currently not worth it
     let _variant_id_to_fields = |id: VariantId| {
-        let variant_data = &id.variant_data(db);
+        let variant_data = &id.fields(db);
         let fields = if variant_data.fields().is_empty() {
             vec![]
         } else {
@@ -879,7 +878,7 @@ fn impl_def_datum(db: &dyn HirDatabase, krate: Crate, impl_id: hir_def::ImplId)
     let polarity = if negative { rust_ir::Polarity::Negative } else { rust_ir::Polarity::Positive };
 
     let impl_datum_bound = rust_ir::ImplDatumBound { trait_ref, where_clauses };
-    let trait_data = db.trait_items(trait_);
+    let trait_data = trait_.trait_items(db);
     let associated_ty_value_ids = impl_id
         .impl_items(db)
         .items
@@ -931,8 +930,9 @@ fn type_alias_associated_ty_value(
         .into_value_and_skipped_binders()
         .0; // we don't return any assoc ty values if the impl'd trait can't be resolved
 
-    let assoc_ty = db
-        .trait_items(trait_ref.hir_trait_id())
+    let assoc_ty = trait_ref
+        .hir_trait_id()
+        .trait_items(db)
         .associated_type_by_name(&type_alias_data.name)
         .expect("assoc ty value should not exist"); // validated when building the impl data as well
     let (ty, binders) = db.ty(type_alias.into()).into_value_and_skipped_binders();
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/decl_check.rs b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/decl_check.rs
index 1873f12..9c0f8f4 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/decl_check.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/decl_check.rs
@@ -307,7 +307,7 @@ fn validate_struct(&mut self, struct_id: StructId) {
 
     /// Check incorrect names for struct fields.
     fn validate_struct_fields(&mut self, struct_id: StructId) {
-        let data = self.db.variant_fields(struct_id.into());
+        let data = struct_id.fields(self.db);
         if data.shape != FieldsShape::Record {
             return;
         };
@@ -468,7 +468,7 @@ fn validate_enum_variants(&mut self, enum_id: EnumId) {
 
     /// Check incorrect names for fields of enum variant.
     fn validate_enum_variant_fields(&mut self, variant_id: EnumVariantId) {
-        let variant_data = self.db.variant_fields(variant_id.into());
+        let variant_data = variant_id.fields(self.db);
         if variant_data.shape != FieldsShape::Record {
             return;
         };
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/expr.rs b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/expr.rs
index df2eb41..5d56957 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/expr.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/expr.rs
@@ -494,7 +494,7 @@ fn new(resolver: &hir_def::resolver::Resolver<'_>, db: &dyn HirDatabase) -> Self
                 Some(next_function_id),
                 match next_function_id.lookup(db).container {
                     ItemContainerId::TraitId(iterator_trait_id) => {
-                        let iterator_trait_items = &db.trait_items(iterator_trait_id).items;
+                        let iterator_trait_items = &iterator_trait_id.trait_items(db).items;
                         iterator_trait_items.iter().find_map(|(name, it)| match it {
                             &AssocItemId::FunctionId(id) if *name == sym::filter_map => Some(id),
                             _ => None,
@@ -558,7 +558,7 @@ pub fn record_literal_missing_fields(
         return None;
     }
 
-    let variant_data = variant_def.variant_data(db);
+    let variant_data = variant_def.fields(db);
 
     let specified_fields: FxHashSet<_> = fields.iter().map(|f| &f.name).collect();
     let missed_fields: Vec<LocalFieldId> = variant_data
@@ -588,7 +588,7 @@ pub fn record_pattern_missing_fields(
         return None;
     }
 
-    let variant_data = variant_def.variant_data(db);
+    let variant_data = variant_def.fields(db);
 
     let specified_fields: FxHashSet<_> = fields.iter().map(|f| &f.name).collect();
     let missed_fields: Vec<LocalFieldId> = variant_data
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check.rs b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check.rs
index 916876d..0bce32a 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check.rs
@@ -169,13 +169,13 @@ fn lower_pattern_unadjusted(&mut self, pat: PatId) -> Pat {
             }
 
             hir_def::hir::Pat::TupleStruct { ref args, ellipsis, .. } if variant.is_some() => {
-                let expected_len = variant.unwrap().variant_data(self.db).fields().len();
+                let expected_len = variant.unwrap().fields(self.db).fields().len();
                 let subpatterns = self.lower_tuple_subpats(args, expected_len, ellipsis);
                 self.lower_variant_or_leaf(pat, ty, subpatterns)
             }
 
             hir_def::hir::Pat::Record { ref args, .. } if variant.is_some() => {
-                let variant_data = variant.unwrap().variant_data(self.db);
+                let variant_data = variant.unwrap().fields(self.db);
                 let subpatterns = args
                     .iter()
                     .map(|field| {
@@ -345,7 +345,7 @@ fn hir_fmt(&self, f: &mut HirFormatter<'_>) -> Result<(), HirDisplayError> {
                         )?,
                     };
 
-                    let variant_data = variant.variant_data(f.db);
+                    let variant_data = variant.fields(f.db);
                     if variant_data.shape == FieldsShape::Record {
                         write!(f, " {{ ")?;
 
@@ -377,7 +377,7 @@ fn hir_fmt(&self, f: &mut HirFormatter<'_>) -> Result<(), HirDisplayError> {
                 }
 
                 let num_fields =
-                    variant.map_or(subpatterns.len(), |v| v.variant_data(f.db).fields().len());
+                    variant.map_or(subpatterns.len(), |v| v.fields(f.db).fields().len());
                 if num_fields != 0 || variant.is_none() {
                     write!(f, "(")?;
                     let subpats = (0..num_fields).map(|i| {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check/pat_analysis.rs b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check/pat_analysis.rs
index 2873a3e..7cf22c6 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check/pat_analysis.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/diagnostics/match_check/pat_analysis.rs
@@ -6,7 +6,7 @@
 use hir_def::{DefWithBodyId, EnumId, EnumVariantId, HasModule, LocalFieldId, ModuleId, VariantId};
 use intern::sym;
 use rustc_pattern_analysis::{
-    Captures, IndexVec, PatCx, PrivateUninhabitedField,
+    IndexVec, PatCx, PrivateUninhabitedField,
     constructor::{Constructor, ConstructorSet, VariantVisibility},
     usefulness::{PlaceValidity, UsefulnessReport, compute_match_usefulness},
 };
@@ -138,15 +138,15 @@ fn variant_id_for_adt(
     }
 
     // This lists the fields of a variant along with their types.
-    fn list_variant_fields<'a>(
-        &'a self,
-        ty: &'a Ty,
+    fn list_variant_fields(
+        &self,
+        ty: &Ty,
         variant: VariantId,
-    ) -> impl Iterator<Item = (LocalFieldId, Ty)> + Captures<'a> + Captures<'db> {
+    ) -> impl Iterator<Item = (LocalFieldId, Ty)> {
         let (_, substs) = ty.as_adt().unwrap();
 
         let field_tys = self.db.field_types(variant);
-        let fields_len = variant.variant_data(self.db).fields().len() as u32;
+        let fields_len = variant.fields(self.db).fields().len() as u32;
 
         (0..fields_len).map(|idx| LocalFieldId::from_raw(idx.into())).map(move |fid| {
             let ty = field_tys[fid].clone().substitute(Interner, substs);
@@ -229,7 +229,7 @@ pub(crate) fn lower_pat(&self, pat: &Pat) -> DeconstructedPat<'db> {
                             }
                         };
                         let variant = Self::variant_id_for_adt(self.db, &ctor, adt).unwrap();
-                        arity = variant.variant_data(self.db).fields().len();
+                        arity = variant.fields(self.db).fields().len();
                     }
                     _ => {
                         never!("pattern has unexpected type: pat: {:?}, ty: {:?}", pat, &pat.ty);
@@ -349,7 +349,7 @@ fn ctor_arity(
                         1
                     } else {
                         let variant = Self::variant_id_for_adt(self.db, ctor, adt).unwrap();
-                        variant.variant_data(self.db).fields().len()
+                        variant.fields(self.db).fields().len()
                     }
                 }
                 _ => {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/display.rs b/src/tools/rust-analyzer/crates/hir-ty/src/display.rs
index 1aa7e0f..507bab2 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/display.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/display.rs
@@ -888,7 +888,7 @@ fn render_const_scalar(
                     write!(f, "{}", data.name.display(f.db, f.edition()))?;
                     let field_types = f.db.field_types(s.into());
                     render_variant_after_name(
-                        &f.db.variant_fields(s.into()),
+                        s.fields(f.db),
                         f,
                         &field_types,
                         f.db.trait_environment(adt.0.into()),
@@ -920,7 +920,7 @@ fn render_const_scalar(
                     )?;
                     let field_types = f.db.field_types(var_id.into());
                     render_variant_after_name(
-                        &f.db.variant_fields(var_id.into()),
+                        var_id.fields(f.db),
                         f,
                         &field_types,
                         f.db.trait_environment(adt.0.into()),
@@ -1394,7 +1394,7 @@ fn hir_fmt(
                         let future_trait =
                             LangItem::Future.resolve_trait(db, body.module(db).krate());
                         let output = future_trait.and_then(|t| {
-                            db.trait_items(t)
+                            t.trait_items(db)
                                 .associated_type_by_name(&Name::new_symbol_root(sym::Output))
                         });
                         write!(f, "impl ")?;
@@ -2178,6 +2178,7 @@ fn hir_fmt(
                         f.write_joined(
                             generic_params
                                 .where_predicates()
+                                .iter()
                                 .filter_map(|it| match it {
                                     WherePredicate::TypeBound { target, bound }
                                     | WherePredicate::ForLifetime { lifetimes: _, target, bound }
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/dyn_compatibility.rs b/src/tools/rust-analyzer/crates/hir-ty/src/dyn_compatibility.rs
index 4809494..30949c8 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/dyn_compatibility.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/dyn_compatibility.rs
@@ -101,7 +101,7 @@ pub fn dyn_compatibility_of_trait_with_callback<F>(
 
     // rustc checks for non-lifetime binders here, but we don't support HRTB yet
 
-    let trait_data = db.trait_items(trait_);
+    let trait_data = trait_.trait_items(db);
     for (_, assoc_item) in &trait_data.items {
         dyn_compatibility_violation_for_assoc_item(db, trait_, *assoc_item, cb)?;
     }
@@ -164,7 +164,7 @@ fn predicates_reference_self(db: &dyn HirDatabase, trait_: TraitId) -> bool {
 
 // Same as the above, `predicates_reference_self`
 fn bounds_reference_self(db: &dyn HirDatabase, trait_: TraitId) -> bool {
-    let trait_data = db.trait_items(trait_);
+    let trait_data = trait_.trait_items(db);
     trait_data
         .items
         .iter()
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/generics.rs b/src/tools/rust-analyzer/crates/hir-ty/src/generics.rs
index a3ed399..f14872e 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/generics.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/generics.rs
@@ -60,7 +60,16 @@ pub(crate) fn store(&self) -> &ExpressionStore {
     }
 
     pub(crate) fn where_predicates(&self) -> impl Iterator<Item = &WherePredicate> {
-        self.params.where_predicates()
+        self.params.where_predicates().iter()
+    }
+
+    pub(crate) fn has_no_predicates(&self) -> bool {
+        self.params.has_no_predicates()
+            && self.parent_generics.as_ref().is_none_or(|g| g.params.has_no_predicates())
+    }
+
+    pub(crate) fn is_empty(&self) -> bool {
+        self.params.is_empty() && self.parent_generics.as_ref().is_none_or(|g| g.params.is_empty())
     }
 
     pub(crate) fn iter_id(&self) -> impl Iterator<Item = GenericParamId> + '_ {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer.rs
index 80478f1..ce53198 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer.rs
@@ -1813,7 +1813,7 @@ fn resolve_lang_item(&self, item: LangItem) -> Option<LangItemTarget> {
     }
 
     fn resolve_output_on(&self, trait_: TraitId) -> Option<TypeAliasId> {
-        self.db.trait_items(trait_).associated_type_by_name(&Name::new_symbol_root(sym::Output))
+        trait_.trait_items(self.db).associated_type_by_name(&Name::new_symbol_root(sym::Output))
     }
 
     fn resolve_lang_trait(&self, lang: LangItem) -> Option<TraitId> {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer/cast.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer/cast.rs
index 8d345de..4e95eca 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer/cast.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer/cast.rs
@@ -382,7 +382,7 @@ fn pointer_kind(ty: &Ty, table: &mut InferenceTable<'_>) -> Result<Option<Pointe
                 return Err(());
             };
 
-            let struct_data = table.db.variant_fields(id.into());
+            let struct_data = id.fields(table.db);
             if let Some((last_field, _)) = struct_data.fields().iter().last() {
                 let last_field_ty =
                     table.db.field_types(id.into())[last_field].clone().substitute(Interner, subst);
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer/closure.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer/closure.rs
index b756bb8..65a273c 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer/closure.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer/closure.rs
@@ -677,7 +677,7 @@ pub fn place_to_name(&self, owner: DefWithBodyId, db: &dyn HirDatabase) -> Strin
             match proj {
                 ProjectionElem::Deref => {}
                 ProjectionElem::Field(Either::Left(f)) => {
-                    let variant_data = f.parent.variant_data(db);
+                    let variant_data = f.parent.fields(db);
                     match variant_data.shape {
                         FieldsShape::Record => {
                             result.push('_');
@@ -720,7 +720,7 @@ pub fn display_place_source_code(&self, owner: DefWithBodyId, db: &dyn HirDataba
                 // In source code autoderef kicks in.
                 ProjectionElem::Deref => {}
                 ProjectionElem::Field(Either::Left(f)) => {
-                    let variant_data = f.parent.variant_data(db);
+                    let variant_data = f.parent.fields(db);
                     match variant_data.shape {
                         FieldsShape::Record => format_to!(
                             result,
@@ -782,7 +782,7 @@ pub fn display_place(&self, owner: DefWithBodyId, db: &dyn HirDatabase) -> Strin
                     if field_need_paren {
                         result = format!("({result})");
                     }
-                    let variant_data = f.parent.variant_data(db);
+                    let variant_data = f.parent.fields(db);
                     let field = match variant_data.shape {
                         FieldsShape::Record => {
                             variant_data.fields()[f.local_id].name.as_str().to_owned()
@@ -1210,9 +1210,8 @@ fn walk_expr_without_adjust(&mut self, tgt_expr: ExprId) {
                         if let Some(deref_trait) =
                             self.resolve_lang_item(LangItem::DerefMut).and_then(|it| it.as_trait())
                         {
-                            if let Some(deref_fn) = self
-                                .db
-                                .trait_items(deref_trait)
+                            if let Some(deref_fn) = deref_trait
+                                .trait_items(self.db)
                                 .method_by_name(&Name::new_symbol_root(sym::deref_mut))
                             {
                                 break 'b deref_fn == f;
@@ -1560,7 +1559,7 @@ fn consume_with_pat(&mut self, mut place: HirPlace, tgt_pat: PatId) {
                             self.consume_place(place)
                         }
                         VariantId::StructId(s) => {
-                            let vd = &*self.db.variant_fields(s.into());
+                            let vd = s.fields(self.db);
                             for field_pat in args.iter() {
                                 let arg = field_pat.pat;
                                 let Some(local_id) = vd.field(&field_pat.name) else {
@@ -1612,7 +1611,7 @@ fn consume_with_pat(&mut self, mut place: HirPlace, tgt_pat: PatId) {
                             self.consume_place(place)
                         }
                         VariantId::StructId(s) => {
-                            let vd = &*self.db.variant_fields(s.into());
+                            let vd = s.fields(self.db);
                             let (al, ar) =
                                 args.split_at(ellipsis.map_or(args.len(), |it| it as usize));
                             let fields = vd.fields().iter();
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer/expr.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer/expr.rs
index 6403127..d40d52c 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer/expr.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer/expr.rs
@@ -542,7 +542,7 @@ fn infer_expr_inner(
                     _ if fields.is_empty() => {}
                     Some(def) => {
                         let field_types = self.db.field_types(def);
-                        let variant_data = def.variant_data(self.db);
+                        let variant_data = def.fields(self.db);
                         let visibilities = self.db.field_visibilities(def);
                         for field in fields.iter() {
                             let field_def = {
@@ -654,9 +654,8 @@ fn infer_expr_inner(
                 match op {
                     UnaryOp::Deref => {
                         if let Some(deref_trait) = self.resolve_lang_trait(LangItem::Deref) {
-                            if let Some(deref_fn) = self
-                                .db
-                                .trait_items(deref_trait)
+                            if let Some(deref_fn) = deref_trait
+                                .trait_items(self.db)
                                 .method_by_name(&Name::new_symbol_root(sym::deref))
                             {
                                 // FIXME: this is wrong in multiple ways, subst is empty, and we emit it even for builtin deref (note that
@@ -813,9 +812,8 @@ fn infer_expr_inner(
                         self.table.new_lifetime_var(),
                     ));
                     self.write_expr_adj(*base, adj.into_boxed_slice());
-                    if let Some(func) = self
-                        .db
-                        .trait_items(index_trait)
+                    if let Some(func) = index_trait
+                        .trait_items(self.db)
                         .method_by_name(&Name::new_symbol_root(sym::index))
                     {
                         let subst = TyBuilder::subst_for_def(self.db, index_trait, None);
@@ -1148,7 +1146,7 @@ pub(crate) fn write_fn_trait_method_resolution(
         let Some(trait_) = fn_x.get_id(self.db, self.table.trait_env.krate) else {
             return;
         };
-        let trait_data = self.db.trait_items(trait_);
+        let trait_data = trait_.trait_items(self.db);
         if let Some(func) = trait_data.method_by_name(&fn_x.method_name()) {
             let subst = TyBuilder::subst_for_def(self.db, trait_, None)
                 .push(callee_ty.clone())
@@ -1316,7 +1314,7 @@ fn infer_overloadable_binop(
 
         let trait_func = lang_items_for_bin_op(op).and_then(|(name, lang_item)| {
             let trait_id = self.resolve_lang_item(lang_item)?.as_trait()?;
-            let func = self.db.trait_items(trait_id).method_by_name(&name)?;
+            let func = trait_id.trait_items(self.db).method_by_name(&name)?;
             Some((trait_id, func))
         });
         let (trait_, func) = match trait_func {
@@ -1568,12 +1566,12 @@ fn lookup_field(
                     });
                 }
                 &TyKind::Adt(AdtId(hir_def::AdtId::StructId(s)), ref parameters) => {
-                    let local_id = self.db.variant_fields(s.into()).field(name)?;
+                    let local_id = s.fields(self.db).field(name)?;
                     let field = FieldId { parent: s.into(), local_id };
                     (field, parameters.clone())
                 }
                 &TyKind::Adt(AdtId(hir_def::AdtId::UnionId(u)), ref parameters) => {
-                    let local_id = self.db.variant_fields(u.into()).field(name)?;
+                    let local_id = u.fields(self.db).field(name)?;
                     let field = FieldId { parent: u.into(), local_id };
                     (field, parameters.clone())
                 }
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer/mutability.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer/mutability.rs
index ac450c0..d2eaf21 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer/mutability.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer/mutability.rs
@@ -129,9 +129,8 @@ fn infer_mut_expr_without_adjust(&mut self, tgt_expr: ExprId, mutability: Mutabi
                         if let Some(index_trait) =
                             LangItem::IndexMut.resolve_trait(self.db, self.table.trait_env.krate)
                         {
-                            if let Some(index_fn) = self
-                                .db
-                                .trait_items(index_trait)
+                            if let Some(index_fn) = index_trait
+                                .trait_items(self.db)
                                 .method_by_name(&Name::new_symbol_root(sym::index_mut))
                             {
                                 *f = index_fn;
@@ -194,9 +193,8 @@ fn infer_mut_expr_without_adjust(&mut self, tgt_expr: ExprId, mutability: Mutabi
                             });
                             if is_mut_ptr {
                                 mutability = Mutability::Not;
-                            } else if let Some(deref_fn) = self
-                                .db
-                                .trait_items(deref_trait)
+                            } else if let Some(deref_fn) = deref_trait
+                                .trait_items(self.db)
                                 .method_by_name(&Name::new_symbol_root(sym::deref_mut))
                             {
                                 *f = deref_fn;
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer/pat.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer/pat.rs
index 4bc3e16..99d3b5c 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer/pat.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer/pat.rs
@@ -38,7 +38,7 @@ pub(super) fn infer_tuple_struct_pat_like(
         decl: Option<DeclContext>,
     ) -> Ty {
         let (ty, def) = self.resolve_variant(id.into(), path, true);
-        let var_data = def.map(|it| it.variant_data(self.db));
+        let var_data = def.map(|it| it.fields(self.db));
         if let Some(variant) = def {
             self.write_variant_resolution(id.into(), variant);
         }
@@ -60,7 +60,7 @@ pub(super) fn infer_tuple_struct_pat_like(
             _ if subs.is_empty() => {}
             Some(def) => {
                 let field_types = self.db.field_types(def);
-                let variant_data = def.variant_data(self.db);
+                let variant_data = def.fields(self.db);
                 let visibilities = self.db.field_visibilities(def);
 
                 let (pre, post) = match ellipsis {
@@ -129,7 +129,7 @@ pub(super) fn infer_record_pat_like(
             _ if subs.len() == 0 => {}
             Some(def) => {
                 let field_types = self.db.field_types(def);
-                let variant_data = def.variant_data(self.db);
+                let variant_data = def.fields(self.db);
                 let visibilities = self.db.field_visibilities(def);
 
                 let substs = ty.as_adt().map(TupleExt::tail);
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer/path.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer/path.rs
index c327c13..bc8648e 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer/path.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer/path.rs
@@ -278,7 +278,7 @@ fn resolve_trait_assoc_item(
     ) -> Option<(ValueNs, Substitution)> {
         let trait_ = trait_ref.hir_trait_id();
         let item =
-            self.db.trait_items(trait_).items.iter().map(|(_name, id)| *id).find_map(|item| {
+            trait_.trait_items(self.db).items.iter().map(|(_name, id)| *id).find_map(|item| {
                 match item {
                     AssocItemId::FunctionId(func) => {
                         if segment.name == &self.db.function_signature(func).name {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/infer/unify.rs b/src/tools/rust-analyzer/crates/hir-ty/src/infer/unify.rs
index 631b571..c0775553 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/infer/unify.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/infer/unify.rs
@@ -859,7 +859,7 @@ fn callable_sig_from_fn_trait(
         ] {
             let krate = self.trait_env.krate;
             let fn_trait = fn_trait_name.get_id(self.db, krate)?;
-            let trait_data = self.db.trait_items(fn_trait);
+            let trait_data = fn_trait.trait_items(self.db);
             let output_assoc_type =
                 trait_data.associated_type_by_name(&Name::new_symbol_root(output_assoc_name))?;
 
@@ -1001,7 +1001,7 @@ fn short_circuit_trivial_tys(ty: &Ty) -> Option<bool> {
             // Must use a loop here and not recursion because otherwise users will conduct completely
             // artificial examples of structs that have themselves as the tail field and complain r-a crashes.
             while let Some((AdtId::StructId(id), subst)) = ty.as_adt() {
-                let struct_data = self.db.variant_fields(id.into());
+                let struct_data = id.fields(self.db);
                 if let Some((last_field, _)) = struct_data.fields().iter().next_back() {
                     let last_field_ty = self.db.field_types(id.into())[last_field]
                         .clone()
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/inhabitedness.rs b/src/tools/rust-analyzer/crates/hir-ty/src/inhabitedness.rs
index 79a99321..b16b6a1 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/inhabitedness.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/inhabitedness.rs
@@ -132,7 +132,7 @@ fn visit_variant(
         variant: VariantId,
         subst: &Substitution,
     ) -> ControlFlow<VisiblyUninhabited> {
-        let variant_data = self.db.variant_fields(variant);
+        let variant_data = variant.fields(self.db);
         let fields = variant_data.fields();
         if fields.is_empty() {
             return CONTINUE_OPAQUELY_INHABITED;
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/layout.rs b/src/tools/rust-analyzer/crates/hir-ty/src/layout.rs
index c58bd1b..3fa2bfb 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/layout.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/layout.rs
@@ -375,7 +375,7 @@ pub(crate) fn layout_of_ty_cycle_result(
 fn struct_tail_erasing_lifetimes(db: &dyn HirDatabase, pointee: Ty) -> Ty {
     match pointee.kind(Interner) {
         &TyKind::Adt(AdtId(hir_def::AdtId::StructId(i)), ref subst) => {
-            let data = db.variant_fields(i.into());
+            let data = i.fields(db);
             let mut it = data.fields().iter().rev();
             match it.next() {
                 Some((f, _)) => {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/layout/adt.rs b/src/tools/rust-analyzer/crates/hir-ty/src/layout/adt.rs
index dff986f..236f316 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/layout/adt.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/layout/adt.rs
@@ -42,7 +42,7 @@ pub fn layout_of_adt_query(
         AdtId::StructId(s) => {
             let sig = db.struct_signature(s);
             let mut r = SmallVec::<[_; 1]>::new();
-            r.push(handle_variant(s.into(), &db.variant_fields(s.into()))?);
+            r.push(handle_variant(s.into(), s.fields(db))?);
             (
                 r,
                 sig.repr.unwrap_or_default(),
@@ -52,7 +52,7 @@ pub fn layout_of_adt_query(
         AdtId::UnionId(id) => {
             let data = db.union_signature(id);
             let mut r = SmallVec::new();
-            r.push(handle_variant(id.into(), &db.variant_fields(id.into()))?);
+            r.push(handle_variant(id.into(), id.fields(db))?);
             (r, data.repr.unwrap_or_default(), false)
         }
         AdtId::EnumId(e) => {
@@ -60,7 +60,7 @@ pub fn layout_of_adt_query(
             let r = variants
                 .variants
                 .iter()
-                .map(|&(v, _, _)| handle_variant(v.into(), &db.variant_fields(v.into())))
+                .map(|&(v, _, _)| handle_variant(v.into(), v.fields(db)))
                 .collect::<Result<SmallVec<_>, _>>()?;
             (r, db.enum_signature(e).repr.unwrap_or_default(), false)
         }
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/lib.rs b/src/tools/rust-analyzer/crates/hir-ty/src/lib.rs
index 148f2a4..e787fd9 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/lib.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/lib.rs
@@ -891,8 +891,8 @@ pub fn callable_sig_from_fn_trait(
 ) -> Option<(FnTrait, CallableSig)> {
     let krate = trait_env.krate;
     let fn_once_trait = FnTrait::FnOnce.get_id(db, krate)?;
-    let output_assoc_type = db
-        .trait_items(fn_once_trait)
+    let output_assoc_type = fn_once_trait
+        .trait_items(db)
         .associated_type_by_name(&Name::new_symbol_root(sym::Output))?;
 
     let mut table = InferenceTable::new(db, trait_env.clone());
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/lower.rs b/src/tools/rust-analyzer/crates/hir-ty/src/lower.rs
index 0a54676..f32b6af 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/lower.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/lower.rs
@@ -581,11 +581,28 @@ pub(crate) fn lower_type_bound<'b>(
         match bound {
             &TypeBound::Path(path, TraitBoundModifier::None) | &TypeBound::ForLifetime(_, path) => {
                 // FIXME Don't silently drop the hrtb lifetimes here
-                if let Some((trait_ref, ctx)) = self.lower_trait_ref_from_path(path, self_ty) {
-                    if !ignore_bindings {
-                        assoc_bounds = ctx.assoc_type_bindings_from_type_bound(trait_ref.clone());
+                if let Some((trait_ref, mut ctx)) =
+                    self.lower_trait_ref_from_path(path, self_ty.clone())
+                {
+                    // FIXME(sized-hierarchy): Remove this bound modifications once we have implemented
+                    // sized-hierarchy correctly.
+                    let meta_sized = LangItem::MetaSized
+                        .resolve_trait(ctx.ty_ctx().db, ctx.ty_ctx().resolver.krate());
+                    let pointee_sized = LangItem::PointeeSized
+                        .resolve_trait(ctx.ty_ctx().db, ctx.ty_ctx().resolver.krate());
+                    if meta_sized.is_some_and(|it| it == trait_ref.hir_trait_id()) {
+                        // Ignore this bound
+                    } else if pointee_sized.is_some_and(|it| it == trait_ref.hir_trait_id()) {
+                        // Regard this as `?Sized` bound
+                        ctx.ty_ctx().unsized_types.insert(self_ty);
+                    } else {
+                        if !ignore_bindings {
+                            assoc_bounds =
+                                ctx.assoc_type_bindings_from_type_bound(trait_ref.clone());
+                        }
+                        clause =
+                            Some(crate::wrap_empty_binders(WhereClause::Implemented(trait_ref)));
                     }
-                    clause = Some(crate::wrap_empty_binders(WhereClause::Implemented(trait_ref)));
                 }
             }
             &TypeBound::Path(path, TraitBoundModifier::Maybe) => {
@@ -711,7 +728,7 @@ fn lower_dyn_trait(&mut self, bounds: &[TypeBound]) -> Ty {
                             .unwrap_or(it),
                         None => it,
                     },
-                    None => static_lifetime(),
+                    None => error_lifetime(),
                 },
             })
             .intern(Interner)
@@ -805,7 +822,7 @@ fn named_associated_type_shorthand_candidates<R>(
 ) -> Option<R> {
     let mut search = |t| {
         all_super_trait_refs(db, t, |t| {
-            let data = db.trait_items(t.hir_trait_id());
+            let data = t.hir_trait_id().trait_items(db);
 
             for (name, assoc_id) in &data.items {
                 if let AssocItemId::TypeAliasId(alias) = assoc_id {
@@ -883,7 +900,12 @@ pub(crate) fn field_types_with_diagnostics_query(
     db: &dyn HirDatabase,
     variant_id: VariantId,
 ) -> (Arc<ArenaMap<LocalFieldId, Binders<Ty>>>, Diagnostics) {
-    let var_data = db.variant_fields(variant_id);
+    let var_data = variant_id.fields(db);
+    let fields = var_data.fields();
+    if fields.is_empty() {
+        return (Arc::new(ArenaMap::default()), None);
+    }
+
     let (resolver, def): (_, GenericDefId) = match variant_id {
         VariantId::StructId(it) => (it.resolver(db), it.into()),
         VariantId::UnionId(it) => (it.resolver(db), it.into()),
@@ -899,7 +921,7 @@ pub(crate) fn field_types_with_diagnostics_query(
         LifetimeElisionKind::AnonymousReportError,
     )
     .with_type_param_mode(ParamLoweringMode::Variable);
-    for (field_id, field_data) in var_data.fields().iter() {
+    for (field_id, field_data) in fields.iter() {
         res.insert(field_id, make_binders(db, &generics, ctx.lower_ty(field_data.type_ref)));
     }
     (Arc::new(res), create_diagnostics(ctx.diagnostics))
@@ -920,6 +942,10 @@ pub(crate) fn generic_predicates_for_param_query(
     assoc_name: Option<Name>,
 ) -> GenericPredicates {
     let generics = generics(db, def);
+    if generics.has_no_predicates() && generics.is_empty() {
+        return GenericPredicates(None);
+    }
+
     let resolver = def.resolver(db);
     let mut ctx = TyLoweringContext::new(
         db,
@@ -936,8 +962,32 @@ pub(crate) fn generic_predicates_for_param_query(
         | WherePredicate::TypeBound { target, bound, .. } => {
             let invalid_target = { ctx.lower_ty_only_param(*target) != Some(param_id) };
             if invalid_target {
-                // If this is filtered out without lowering, `?Sized` is not gathered into `ctx.unsized_types`
-                if let TypeBound::Path(_, TraitBoundModifier::Maybe) = bound {
+                // FIXME(sized-hierarchy): Revisit and adjust this properly once we have implemented
+                // sized-hierarchy correctly.
+                // If this is filtered out without lowering, `?Sized` or `PointeeSized` is not gathered into
+                // `ctx.unsized_types`
+                let lower = || -> bool {
+                    match bound {
+                        TypeBound::Path(_, TraitBoundModifier::Maybe) => true,
+                        TypeBound::Path(path, _) | TypeBound::ForLifetime(_, path) => {
+                            let TypeRef::Path(path) = &ctx.store[path.type_ref()] else {
+                                return false;
+                            };
+                            let Some(pointee_sized) =
+                                LangItem::PointeeSized.resolve_trait(ctx.db, ctx.resolver.krate())
+                            else {
+                                return false;
+                            };
+                            // Lower the path directly with `Resolver` instead of PathLoweringContext`
+                            // to prevent diagnostics duplications.
+                            ctx.resolver.resolve_path_in_type_ns_fully(ctx.db, path).is_some_and(
+                                |it| matches!(it, TypeNs::TraitId(tr) if tr == pointee_sized),
+                            )
+                        }
+                        _ => false,
+                    }
+                }();
+                if lower {
                     ctx.lower_where_predicate(pred, true).for_each(drop);
                 }
                 return false;
@@ -957,7 +1007,7 @@ pub(crate) fn generic_predicates_for_param_query(
                     };
 
                     all_super_traits(db, tr).iter().any(|tr| {
-                        db.trait_items(*tr).items.iter().any(|(name, item)| {
+                        tr.trait_items(db).items.iter().any(|(name, item)| {
                             matches!(item, AssocItemId::TypeAliasId(_)) && name == assoc_name
                         })
                     })
@@ -1025,6 +1075,10 @@ pub(crate) fn trait_environment_query(
     def: GenericDefId,
 ) -> Arc<TraitEnvironment> {
     let generics = generics(db, def);
+    if generics.has_no_predicates() && generics.is_empty() {
+        return TraitEnvironment::empty(def.krate(db));
+    }
+
     let resolver = def.resolver(db);
     let mut ctx = TyLoweringContext::new(
         db,
@@ -1128,6 +1182,10 @@ fn generic_predicates_filtered_by<F>(
     F: Fn(&WherePredicate, GenericDefId) -> bool,
 {
     let generics = generics(db, def);
+    if generics.has_no_predicates() && generics.is_empty() {
+        return (GenericPredicates(None), None);
+    }
+
     let resolver = def.resolver(db);
     let mut ctx = TyLoweringContext::new(
         db,
@@ -1154,7 +1212,7 @@ fn generic_predicates_filtered_by<F>(
         }
     }
 
-    if generics.len() > 0 {
+    if !generics.is_empty() {
         let subst = generics.bound_vars_subst(db, DebruijnIndex::INNERMOST);
         let explicitly_unsized_tys = ctx.unsized_types;
         if let Some(implicitly_sized_predicates) =
@@ -1229,7 +1287,7 @@ pub(crate) fn generic_defaults_with_diagnostics_query(
     def: GenericDefId,
 ) -> (GenericDefaults, Diagnostics) {
     let generic_params = generics(db, def);
-    if generic_params.len() == 0 {
+    if generic_params.is_empty() {
         return (GenericDefaults(None), None);
     }
     let resolver = def.resolver(db);
@@ -1418,7 +1476,7 @@ fn fn_sig_for_struct_constructor(db: &dyn HirDatabase, def: StructId) -> PolyFnS
 
 /// Build the type of a tuple struct constructor.
 fn type_for_struct_constructor(db: &dyn HirDatabase, def: StructId) -> Option<Binders<Ty>> {
-    let struct_data = db.variant_fields(def.into());
+    let struct_data = def.fields(db);
     match struct_data.shape {
         FieldsShape::Record => None,
         FieldsShape::Unit => Some(type_for_adt(db, def.into())),
@@ -1451,7 +1509,7 @@ fn type_for_enum_variant_constructor(
     def: EnumVariantId,
 ) -> Option<Binders<Ty>> {
     let e = def.lookup(db).parent;
-    match db.variant_fields(def.into()).shape {
+    match def.fields(db).shape {
         FieldsShape::Record => None,
         FieldsShape::Unit => Some(type_for_adt(db, e.into())),
         FieldsShape::Tuple => {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/lower/path.rs b/src/tools/rust-analyzer/crates/hir-ty/src/lower/path.rs
index 726eaf8..06686b6 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/lower/path.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/lower/path.rs
@@ -173,7 +173,7 @@ pub(crate) fn lower_partly_resolved_path(
                         self.skip_resolved_segment();
                         let segment = self.current_or_prev_segment;
                         let found =
-                            self.ctx.db.trait_items(trait_).associated_type_by_name(segment.name);
+                            trait_.trait_items(self.ctx.db).associated_type_by_name(segment.name);
 
                         match found {
                             Some(associated_ty) => {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/method_resolution.rs b/src/tools/rust-analyzer/crates/hir-ty/src/method_resolution.rs
index 25f1782..a6150a9 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/method_resolution.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/method_resolution.rs
@@ -1302,7 +1302,7 @@ fn iterate_trait_method_candidates(
         // trait, but if we find out it doesn't, we'll skip the rest of the
         // iteration
         let mut known_implemented = false;
-        for &(_, item) in db.trait_items(t).items.iter() {
+        for &(_, item) in t.trait_items(db).items.iter() {
             // Don't pass a `visible_from_module` down to `is_valid_candidate`,
             // since only inherent methods should be included into visibility checking.
             let visible =
@@ -1429,7 +1429,7 @@ fn iterate_inherent_trait_methods(
     ) -> ControlFlow<()> {
         let db = table.db;
         for t in traits {
-            let data = db.trait_items(t);
+            let data = t.trait_items(db);
             for &(_, item) in data.items.iter() {
                 // We don't pass `visible_from_module` as all trait items should be visible.
                 let visible = match is_valid_trait_method_candidate(
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval.rs
index a8156ec..1ec55a8 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval.rs
@@ -657,12 +657,12 @@ pub fn new(
             cached_ptr_size,
             cached_fn_trait_func: LangItem::Fn
                 .resolve_trait(db, crate_id)
-                .and_then(|x| db.trait_items(x).method_by_name(&Name::new_symbol_root(sym::call))),
+                .and_then(|x| x.trait_items(db).method_by_name(&Name::new_symbol_root(sym::call))),
             cached_fn_mut_trait_func: LangItem::FnMut.resolve_trait(db, crate_id).and_then(|x| {
-                db.trait_items(x).method_by_name(&Name::new_symbol_root(sym::call_mut))
+                x.trait_items(db).method_by_name(&Name::new_symbol_root(sym::call_mut))
             }),
             cached_fn_once_trait_func: LangItem::FnOnce.resolve_trait(db, crate_id).and_then(|x| {
-                db.trait_items(x).method_by_name(&Name::new_symbol_root(sym::call_once))
+                x.trait_items(db).method_by_name(&Name::new_symbol_root(sym::call_once))
             }),
         })
     }
@@ -1749,8 +1749,7 @@ fn unsizing_ptr_from_addr(
                         AdtId::UnionId(_) => not_supported!("unsizing unions"),
                         AdtId::EnumId(_) => not_supported!("unsizing enums"),
                     };
-                    let Some((last_field, _)) =
-                        self.db.variant_fields(id.into()).fields().iter().next_back()
+                    let Some((last_field, _)) = id.fields(self.db).fields().iter().next_back()
                     else {
                         not_supported!("unsizing struct without field");
                     };
@@ -2232,7 +2231,7 @@ fn rec(
                 }
                 chalk_ir::TyKind::Adt(adt, subst) => match adt.0 {
                     AdtId::StructId(s) => {
-                        let data = this.db.variant_fields(s.into());
+                        let data = s.fields(this.db);
                         let layout = this.layout(ty)?;
                         let field_types = this.db.field_types(s.into());
                         for (f, _) in data.fields().iter() {
@@ -2261,7 +2260,7 @@ fn rec(
                             bytes,
                             e,
                         ) {
-                            let data = &this.db.variant_fields(v.into());
+                            let data = v.fields(this.db);
                             let field_types = this.db.field_types(v.into());
                             for (f, _) in data.fields().iter() {
                                 let offset =
@@ -2808,7 +2807,7 @@ fn run_drop_glue_deep(
     ) -> Result<()> {
         let Some(drop_fn) = (|| {
             let drop_trait = LangItem::Drop.resolve_trait(self.db, self.crate_id)?;
-            self.db.trait_items(drop_trait).method_by_name(&Name::new_symbol_root(sym::drop))
+            drop_trait.trait_items(self.db).method_by_name(&Name::new_symbol_root(sym::drop))
         })() else {
             // in some tests we don't have drop trait in minicore, and
             // we can ignore drop in them.
@@ -2838,7 +2837,7 @@ fn run_drop_glue_deep(
                             return Ok(());
                         }
                         let layout = self.layout_adt(id.0, subst.clone())?;
-                        let variant_fields = self.db.variant_fields(s.into());
+                        let variant_fields = s.fields(self.db);
                         match variant_fields.shape {
                             FieldsShape::Record | FieldsShape::Tuple => {
                                 let field_types = self.db.field_types(s.into());
@@ -2918,7 +2917,7 @@ pub fn render_const_using_debug_impl(
         not_supported!("core::fmt::Debug not found");
     };
     let Some(debug_fmt_fn) =
-        db.trait_items(debug_trait).method_by_name(&Name::new_symbol_root(sym::fmt))
+        debug_trait.trait_items(db).method_by_name(&Name::new_symbol_root(sym::fmt))
     else {
         not_supported!("core::fmt::Debug::fmt not found");
     };
@@ -3045,7 +3044,10 @@ fn from_bytes(bytes: &[u8], is_signed: bool) -> Self {
             (8, true) => Self::I64(i64::from_le_bytes(bytes.try_into().unwrap())),
             (16, false) => Self::U128(u128::from_le_bytes(bytes.try_into().unwrap())),
             (16, true) => Self::I128(i128::from_le_bytes(bytes.try_into().unwrap())),
-            _ => panic!("invalid integer size"),
+            (len, is_signed) => {
+                never!("invalid integer size: {len}, signed: {is_signed}");
+                Self::I32(0)
+            }
         }
     }
 
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim.rs
index 6ebde01..e9665d5 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim.rs
@@ -1257,9 +1257,8 @@ fn exec_intrinsic(
                     args.push(IntervalAndTy::new(addr, field, self, locals)?);
                 }
                 if let Some(target) = LangItem::FnOnce.resolve_trait(self.db, self.crate_id) {
-                    if let Some(def) = self
-                        .db
-                        .trait_items(target)
+                    if let Some(def) = target
+                        .trait_items(self.db)
                         .method_by_name(&Name::new_symbol_root(sym::call_once))
                     {
                         self.exec_fn_trait(
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim/simd.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim/simd.rs
index 984648c..bc331a2 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim/simd.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/shim/simd.rs
@@ -31,7 +31,7 @@ fn detect_simd_ty(&self, ty: &Ty) -> Result<(usize, Ty)> {
                     Some(len) => len,
                     _ => {
                         if let AdtId::StructId(id) = id.0 {
-                            let struct_data = self.db.variant_fields(id.into());
+                            let struct_data = id.fields(self.db);
                             let fields = struct_data.fields();
                             let Some((first_field, _)) = fields.iter().next() else {
                                 not_supported!("simd type with no field");
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/tests.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/tests.rs
index 3abbbe4..c1f8696 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/tests.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/eval/tests.rs
@@ -984,3 +984,17 @@ fn main<'a, T: Foo + Bar + Baz>(
         |e| matches!(e, MirEvalError::MirLowerError(_, MirLowerError::GenericArgNotProvided(..))),
     );
 }
+
+#[test]
+fn format_args_pass() {
+    check_pass(
+        r#"
+//- minicore: fmt
+fn main() {
+    let x1 = format_args!("");
+    let x2 = format_args!("{}", x1);
+    let x3 = format_args!("{} {}", x1, x2);
+}
+"#,
+    );
+}
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower.rs
index 71e038b..845d6b8 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower.rs
@@ -503,7 +503,7 @@ fn lower_expr_to_place_without_adjust(
                         Ok(Some(current))
                     }
                     ValueNs::EnumVariantId(variant_id) => {
-                        let variant_fields = &self.db.variant_fields(variant_id.into());
+                        let variant_fields = variant_id.fields(self.db);
                         if variant_fields.shape == FieldsShape::Unit {
                             let ty = self.infer.type_of_expr[expr_id].clone();
                             current = self.lower_enum_variant(
@@ -856,7 +856,7 @@ fn lower_expr_to_place_without_adjust(
                     TyKind::Adt(_, s) => s.clone(),
                     _ => not_supported!("Non ADT record literal"),
                 };
-                let variant_fields = self.db.variant_fields(variant_id);
+                let variant_fields = variant_id.fields(self.db);
                 match variant_id {
                     VariantId::EnumVariantId(_) | VariantId::StructId(_) => {
                         let mut operands = vec![None; variant_fields.fields().len()];
@@ -1176,8 +1176,7 @@ fn lower_expr_to_place_without_adjust(
                     place,
                     Rvalue::Aggregate(
                         AggregateKind::Adt(st.into(), subst.clone()),
-                        self.db
-                            .variant_fields(st.into())
+                        st.fields(self.db)
                             .fields()
                             .iter()
                             .map(|it| {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/as_place.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/as_place.rs
index ad66469..e7bffea 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/as_place.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/as_place.rs
@@ -193,9 +193,8 @@ pub(super) fn lower_expr_as_place_without_adjust(
                                 if let Some(deref_trait) =
                                     self.resolve_lang_item(LangItem::DerefMut)?.as_trait()
                                 {
-                                    if let Some(deref_fn) = self
-                                        .db
-                                        .trait_items(deref_trait)
+                                    if let Some(deref_fn) = deref_trait
+                                        .trait_items(self.db)
                                         .method_by_name(&Name::new_symbol_root(sym::deref_mut))
                                     {
                                         break 'b deref_fn == f;
@@ -347,9 +346,8 @@ fn lower_overloaded_deref(
             .resolve_lang_item(trait_lang_item)?
             .as_trait()
             .ok_or(MirLowerError::LangItemNotFound(trait_lang_item))?;
-        let deref_fn = self
-            .db
-            .trait_items(deref_trait)
+        let deref_fn = deref_trait
+            .trait_items(self.db)
             .method_by_name(&trait_method_name)
             .ok_or(MirLowerError::LangItemNotFound(trait_lang_item))?;
         let deref_fn_op = Operand::const_zst(
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/pattern_matching.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/pattern_matching.rs
index b3c1f6f..61c0685 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/pattern_matching.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/lower/pattern_matching.rs
@@ -609,7 +609,7 @@ fn pattern_matching_variant(
                 }
                 self.pattern_matching_variant_fields(
                     shape,
-                    &self.db.variant_fields(v.into()),
+                    v.fields(self.db),
                     variant,
                     current,
                     current_else,
@@ -619,7 +619,7 @@ fn pattern_matching_variant(
             }
             VariantId::StructId(s) => self.pattern_matching_variant_fields(
                 shape,
-                &self.db.variant_fields(s.into()),
+                s.fields(self.db),
                 variant,
                 current,
                 current_else,
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/mir/pretty.rs b/src/tools/rust-analyzer/crates/hir-ty/src/mir/pretty.rs
index 8764e48..78a69cf 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/mir/pretty.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/mir/pretty.rs
@@ -326,7 +326,7 @@ fn f(this: &mut MirPrettyCtx<'_>, local: LocalId, projections: &[PlaceElem]) {
                     w!(this, ")");
                 }
                 ProjectionElem::Field(Either::Left(field)) => {
-                    let variant_fields = this.db.variant_fields(field.parent);
+                    let variant_fields = field.parent.fields(this.db);
                     let name = &variant_fields.fields()[field.local_id].name;
                     match field.parent {
                         hir_def::VariantId::EnumVariantId(e) => {
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests.rs
index 9ca6ee4..79754bc 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests.rs
@@ -486,7 +486,7 @@ fn visit_scope(
                     });
                 }
                 ModuleDefId::TraitId(it) => {
-                    let trait_data = db.trait_items(it);
+                    let trait_data = it.trait_items(db);
                     for &(_, item) in trait_data.items.iter() {
                         match item {
                             AssocItemId::FunctionId(it) => cb(it.into()),
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests/coercion.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests/coercion.rs
index ddc5b71..3894b4b 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests/coercion.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests/coercion.rs
@@ -561,7 +561,7 @@ trait Foo {}
 fn test(f: impl Foo, g: &(impl Foo + ?Sized)) {
     let _: &dyn Foo = &f;
     let _: &dyn Foo = g;
-                    //^ expected &'? (dyn Foo + 'static), got &'? impl Foo + ?Sized
+                    //^ expected &'? (dyn Foo + '?), got &'? impl Foo + ?Sized
 }
         "#,
     );
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests/display_source_code.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests/display_source_code.rs
index a986b54..6e3faa0 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests/display_source_code.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests/display_source_code.rs
@@ -67,11 +67,11 @@ trait B: A {}
 
 fn test<'a>(
     _: &(dyn A<Assoc = ()> + Send),
-  //^ &(dyn A<Assoc = ()> + Send + 'static)
+  //^ &(dyn A<Assoc = ()> + Send)
     _: &'a (dyn Send + A<Assoc = ()>),
-  //^ &'a (dyn A<Assoc = ()> + Send + 'static)
+  //^ &'a (dyn A<Assoc = ()> + Send)
     _: &dyn B<Assoc = ()>,
-  //^ &(dyn B<Assoc = ()> + 'static)
+  //^ &(dyn B<Assoc = ()>)
 ) {}
         "#,
     );
@@ -85,7 +85,7 @@ fn render_dyn_for_ty() {
 trait Foo<'a> {}
 
 fn foo(foo: &dyn for<'a> Foo<'a>) {}
-    // ^^^ &(dyn Foo<'?> + 'static)
+    // ^^^ &dyn Foo<'?>
 "#,
     );
 }
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests/incremental.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests/incremental.rs
index 905fd8a..0377ce9 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests/incremental.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests/incremental.rs
@@ -567,7 +567,7 @@ fn main() {
                 "ast_id_map_shim",
                 "parse_shim",
                 "real_span_map_shim",
-                "trait_items_with_diagnostics_shim",
+                "query_with_diagnostics_",
                 "body_shim",
                 "body_with_source_map_shim",
                 "attrs_shim",
@@ -596,8 +596,8 @@ fn main() {
                 "struct_signature_with_source_map_shim",
                 "generic_predicates_shim",
                 "value_ty_shim",
-                "variant_fields_shim",
-                "variant_fields_with_source_map_shim",
+                "firewall_",
+                "query_",
                 "lang_item",
                 "inherent_impls_in_crate_shim",
                 "impl_signature_shim",
@@ -674,7 +674,7 @@ fn main() {
                 "file_item_tree_query",
                 "real_span_map_shim",
                 "crate_local_def_map",
-                "trait_items_with_diagnostics_shim",
+                "query_with_diagnostics_",
                 "body_with_source_map_shim",
                 "attrs_shim",
                 "body_shim",
@@ -695,11 +695,9 @@ fn main() {
                 "return_type_impl_traits_shim",
                 "infer_shim",
                 "function_signature_with_source_map_shim",
-                "trait_environment_shim",
                 "expr_scopes_shim",
                 "struct_signature_with_source_map_shim",
-                "generic_predicates_shim",
-                "variant_fields_with_source_map_shim",
+                "query_",
                 "inherent_impls_in_crate_shim",
                 "impl_signature_with_source_map_shim",
                 "impl_signature_shim",
@@ -709,7 +707,6 @@ fn main() {
                 "impl_trait_with_diagnostics_shim",
                 "impl_self_ty_with_diagnostics_shim",
                 "generic_predicates_shim",
-                "generic_predicates_shim",
             ]
         "#]],
     );
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests/method_resolution.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests/method_resolution.rs
index 94826ac..c58ca6c 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests/method_resolution.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests/method_resolution.rs
@@ -1153,9 +1153,9 @@ fn test(d: &dyn Trait) {
             51..55 'self': &'? Self
             64..69 '{ 0 }': u32
             66..67 '0': u32
-            176..177 'd': &'? (dyn Trait + 'static)
+            176..177 'd': &'? (dyn Trait + '?)
             191..207 '{     ...o(); }': ()
-            197..198 'd': &'? (dyn Trait + 'static)
+            197..198 'd': &'? (dyn Trait + '?)
             197..204 'd.foo()': u32
         "#]],
     );
@@ -2019,10 +2019,10 @@ impl dyn Error + Send {
     /// Attempts to downcast the box to a concrete type.
     pub fn downcast<T: Error + 'static>(self: Box<Self>) -> Result<Box<T>, Box<dyn Error + Send>> {
         let err: Box<dyn Error> = self;
-                               // ^^^^ expected Box<dyn Error + 'static>, got Box<dyn Error + Send + 'static>
+                               // ^^^^ expected Box<dyn Error + '?>, got Box<dyn Error + Send + '?>
                                // FIXME, type mismatch should not occur
         <dyn Error>::downcast(err).map_err(|_| loop {})
-      //^^^^^^^^^^^^^^^^^^^^^ type: fn downcast<{unknown}>(Box<dyn Error + 'static>) -> Result<Box<{unknown}>, Box<dyn Error + 'static>>
+      //^^^^^^^^^^^^^^^^^^^^^ type: fn downcast<{unknown}>(Box<dyn Error + '?>) -> Result<Box<{unknown}>, Box<dyn Error + '?>>
     }
 }
 "#,
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests/regression.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests/regression.rs
index ff8adee..238753e 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests/regression.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests/regression.rs
@@ -629,7 +629,7 @@ fn internal_into_boxed(self) -> Self::Output {
             488..522 '{     ...     }': ()
             498..502 'self': SelectStatement<F, S, D, W, O, LOf, {unknown}, {unknown}>
             498..508 'self.order': O
-            498..515 'self.o...into()': dyn QueryFragment<DB> + 'static
+            498..515 'self.o...into()': dyn QueryFragment<DB> + '?
         "#]],
     );
 }
@@ -773,7 +773,7 @@ pub trait Service<Request> {
         "#,
         expect![[r#"
             379..383 'self': &'? mut PeerSet<D>
-            401..424 '{     ...     }': dyn Future<Output = ()> + 'static
+            401..424 '{     ...     }': dyn Future<Output = ()> + '?
             411..418 'loop {}': !
             416..418 '{}': ()
             575..579 'self': &'? mut Self
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests/simple.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests/simple.rs
index cf51671..43e8f37 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests/simple.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests/simple.rs
@@ -2741,11 +2741,11 @@ impl B for Astruct {}
             715..744 '#[rust...1i32])': Box<[i32; 1], Global>
             737..743 '[1i32]': [i32; 1]
             738..742 '1i32': i32
-            755..756 'v': Vec<Box<dyn B + 'static, Global>, Global>
-            776..793 '<[_]> ...to_vec': fn into_vec<Box<dyn B + 'static, Global>, Global>(Box<[Box<dyn B + 'static, Global>], Global>) -> Vec<Box<dyn B + 'static, Global>, Global>
-            776..850 '<[_]> ...ct)]))': Vec<Box<dyn B + 'static, Global>, Global>
-            794..849 '#[rust...uct)])': Box<[Box<dyn B + 'static, Global>; 1], Global>
-            816..848 '[#[rus...ruct)]': [Box<dyn B + 'static, Global>; 1]
+            755..756 'v': Vec<Box<dyn B + '?, Global>, Global>
+            776..793 '<[_]> ...to_vec': fn into_vec<Box<dyn B + '?, Global>, Global>(Box<[Box<dyn B + '?, Global>], Global>) -> Vec<Box<dyn B + '?, Global>, Global>
+            776..850 '<[_]> ...ct)]))': Vec<Box<dyn B + '?, Global>, Global>
+            794..849 '#[rust...uct)])': Box<[Box<dyn B + '?, Global>; 1], Global>
+            816..848 '[#[rus...ruct)]': [Box<dyn B + '?, Global>; 1]
             817..847 '#[rust...truct)': Box<Astruct, Global>
             839..846 'Astruct': Astruct
         "#]],
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/tests/traits.rs b/src/tools/rust-analyzer/crates/hir-ty/src/tests/traits.rs
index e5d1fbe..56e31a1 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/tests/traits.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/tests/traits.rs
@@ -1475,26 +1475,26 @@ fn test(x: Box<dyn Trait<u64>>, y: &dyn Trait<u64>) {
         expect![[r#"
             29..33 'self': &'? Self
             54..58 'self': &'? Self
-            198..200 '{}': Box<dyn Trait<u64> + 'static>
-            210..211 'x': Box<dyn Trait<u64> + 'static>
-            234..235 'y': &'? (dyn Trait<u64> + 'static)
+            198..200 '{}': Box<dyn Trait<u64> + '?>
+            210..211 'x': Box<dyn Trait<u64> + '?>
+            234..235 'y': &'? (dyn Trait<u64> + '?)
             254..371 '{     ...2(); }': ()
-            260..261 'x': Box<dyn Trait<u64> + 'static>
-            267..268 'y': &'? (dyn Trait<u64> + 'static)
-            278..279 'z': Box<dyn Trait<u64> + 'static>
-            282..285 'bar': fn bar() -> Box<dyn Trait<u64> + 'static>
-            282..287 'bar()': Box<dyn Trait<u64> + 'static>
-            293..294 'x': Box<dyn Trait<u64> + 'static>
+            260..261 'x': Box<dyn Trait<u64> + '?>
+            267..268 'y': &'? (dyn Trait<u64> + '?)
+            278..279 'z': Box<dyn Trait<u64> + '?>
+            282..285 'bar': fn bar() -> Box<dyn Trait<u64> + '?>
+            282..287 'bar()': Box<dyn Trait<u64> + '?>
+            293..294 'x': Box<dyn Trait<u64> + '?>
             293..300 'x.foo()': u64
-            306..307 'y': &'? (dyn Trait<u64> + 'static)
+            306..307 'y': &'? (dyn Trait<u64> + '?)
             306..313 'y.foo()': u64
-            319..320 'z': Box<dyn Trait<u64> + 'static>
+            319..320 'z': Box<dyn Trait<u64> + '?>
             319..326 'z.foo()': u64
-            332..333 'x': Box<dyn Trait<u64> + 'static>
+            332..333 'x': Box<dyn Trait<u64> + '?>
             332..340 'x.foo2()': i64
-            346..347 'y': &'? (dyn Trait<u64> + 'static)
+            346..347 'y': &'? (dyn Trait<u64> + '?)
             346..354 'y.foo2()': i64
-            360..361 'z': Box<dyn Trait<u64> + 'static>
+            360..361 'z': Box<dyn Trait<u64> + '?>
             360..368 'z.foo2()': i64
         "#]],
     );
@@ -1523,14 +1523,14 @@ fn test(s: S<u32, i32>) {
         expect![[r#"
             32..36 'self': &'? Self
             102..106 'self': &'? S<T, U>
-            128..139 '{ loop {} }': &'? (dyn Trait<T, U> + 'static)
+            128..139 '{ loop {} }': &'? (dyn Trait<T, U> + '?)
             130..137 'loop {}': !
             135..137 '{}': ()
             175..179 'self': &'? Self
             251..252 's': S<u32, i32>
             267..289 '{     ...z(); }': ()
             273..274 's': S<u32, i32>
-            273..280 's.bar()': &'? (dyn Trait<u32, i32> + 'static)
+            273..280 's.bar()': &'? (dyn Trait<u32, i32> + '?)
             273..286 's.bar().baz()': (u32, i32)
         "#]],
     );
@@ -1556,20 +1556,20 @@ fn test(x: Trait, y: &Trait) -> u64 {
 }"#,
         expect![[r#"
             26..30 'self': &'? Self
-            60..62 '{}': dyn Trait + 'static
-            72..73 'x': dyn Trait + 'static
-            82..83 'y': &'? (dyn Trait + 'static)
+            60..62 '{}': dyn Trait + '?
+            72..73 'x': dyn Trait + '?
+            82..83 'y': &'? (dyn Trait + '?)
             100..175 '{     ...o(); }': u64
-            106..107 'x': dyn Trait + 'static
-            113..114 'y': &'? (dyn Trait + 'static)
-            124..125 'z': dyn Trait + 'static
-            128..131 'bar': fn bar() -> dyn Trait + 'static
-            128..133 'bar()': dyn Trait + 'static
-            139..140 'x': dyn Trait + 'static
+            106..107 'x': dyn Trait + '?
+            113..114 'y': &'? (dyn Trait + '?)
+            124..125 'z': dyn Trait + '?
+            128..131 'bar': fn bar() -> dyn Trait + '?
+            128..133 'bar()': dyn Trait + '?
+            139..140 'x': dyn Trait + '?
             139..146 'x.foo()': u64
-            152..153 'y': &'? (dyn Trait + 'static)
+            152..153 'y': &'? (dyn Trait + '?)
             152..159 'y.foo()': u64
-            165..166 'z': dyn Trait + 'static
+            165..166 'z': dyn Trait + '?
             165..172 'z.foo()': u64
         "#]],
     );
@@ -1589,10 +1589,10 @@ fn main() {
         expect![[r#"
             31..35 'self': &'? S
             37..39 '{}': ()
-            47..48 '_': &'? (dyn Fn(S) + 'static)
+            47..48 '_': &'? (dyn Fn(S) + '?)
             58..60 '{}': ()
             71..105 '{     ...()); }': ()
-            77..78 'f': fn f(&'? (dyn Fn(S) + 'static))
+            77..78 'f': fn f(&'? (dyn Fn(S) + '?))
             77..102 'f(&|nu...foo())': ()
             79..101 '&|numb....foo()': &'? impl Fn(S)
             80..101 '|numbe....foo()': impl Fn(S)
@@ -2927,13 +2927,13 @@ fn test(x: &dyn Foo) {
     foo(x);
 }"#,
         expect![[r#"
-            21..22 'x': &'? (dyn Foo + 'static)
+            21..22 'x': &'? (dyn Foo + '?)
             34..36 '{}': ()
-            46..47 'x': &'? (dyn Foo + 'static)
+            46..47 'x': &'? (dyn Foo + '?)
             59..74 '{     foo(x); }': ()
-            65..68 'foo': fn foo(&'? (dyn Foo + 'static))
+            65..68 'foo': fn foo(&'? (dyn Foo + '?))
             65..71 'foo(x)': ()
-            69..70 'x': &'? (dyn Foo + 'static)
+            69..70 'x': &'? (dyn Foo + '?)
         "#]],
     );
 }
@@ -3210,13 +3210,13 @@ fn foo() {
             218..324 '{     ...&s); }': ()
             228..229 's': Option<i32>
             232..236 'None': Option<i32>
-            246..247 'f': Box<dyn FnOnce(&'? Option<i32>) + 'static>
-            281..310 'Box { ... {}) }': Box<dyn FnOnce(&'? Option<i32>) + 'static>
+            246..247 'f': Box<dyn FnOnce(&'? Option<i32>) + '?>
+            281..310 'Box { ... {}) }': Box<dyn FnOnce(&'? Option<i32>) + '?>
             294..308 '&mut (|ps| {})': &'? mut impl FnOnce(&'? Option<i32>)
             300..307 '|ps| {}': impl FnOnce(&'? Option<i32>)
             301..303 'ps': &'? Option<i32>
             305..307 '{}': ()
-            316..317 'f': Box<dyn FnOnce(&'? Option<i32>) + 'static>
+            316..317 'f': Box<dyn FnOnce(&'? Option<i32>) + '?>
             316..321 'f(&s)': ()
             318..320 '&s': &'? Option<i32>
             319..320 's': Option<i32>
@@ -4252,9 +4252,9 @@ fn f<'a>(v: &dyn Trait<Assoc<i32> = &'a i32>) {
     "#,
         expect![[r#"
             90..94 'self': &'? Self
-            127..128 'v': &'? (dyn Trait<Assoc<i32> = &'a i32> + 'static)
+            127..128 'v': &'? (dyn Trait<Assoc<i32> = &'a i32> + '?)
             164..195 '{     ...f(); }': ()
-            170..171 'v': &'? (dyn Trait<Assoc<i32> = &'a i32> + 'static)
+            170..171 'v': &'? (dyn Trait<Assoc<i32> = &'a i32> + '?)
             170..184 'v.get::<i32>()': &'? i32
             170..192 'v.get:...eref()': &'? i32
         "#]],
diff --git a/src/tools/rust-analyzer/crates/hir-ty/src/utils.rs b/src/tools/rust-analyzer/crates/hir-ty/src/utils.rs
index 4c8e635..d07c1aa 100644
--- a/src/tools/rust-analyzer/crates/hir-ty/src/utils.rs
+++ b/src/tools/rust-analyzer/crates/hir-ty/src/utils.rs
@@ -1,7 +1,7 @@
 //! Helper functions for working with def, which don't need to be a separate
 //! query, but can't be computed directly from `*Data` (ie, which need a `db`).
 
-use std::iter;
+use std::{cell::LazyCell, iter};
 
 use base_db::Crate;
 use chalk_ir::{
@@ -161,11 +161,12 @@ fn next(&mut self) -> Option<Self::Item> {
 }
 
 fn direct_super_traits_cb(db: &dyn DefDatabase, trait_: TraitId, cb: impl FnMut(TraitId)) {
-    let resolver = trait_.resolver(db);
+    let resolver = LazyCell::new(|| trait_.resolver(db));
     let (generic_params, store) = db.generic_params_and_store(trait_.into());
     let trait_self = generic_params.trait_self_param();
     generic_params
         .where_predicates()
+        .iter()
         .filter_map(|pred| match pred {
             WherePredicate::ForLifetime { target, bound, .. }
             | WherePredicate::TypeBound { target, bound } => {
@@ -218,7 +219,7 @@ pub(super) fn associated_type_by_name_including_super_traits(
     name: &Name,
 ) -> Option<(TraitRef, TypeAliasId)> {
     all_super_trait_refs(db, trait_ref, |t| {
-        let assoc_type = db.trait_items(t.hir_trait_id()).associated_type_by_name(name)?;
+        let assoc_type = t.hir_trait_id().trait_items(db).associated_type_by_name(name)?;
         Some((t, assoc_type))
     })
 }
diff --git a/src/tools/rust-analyzer/crates/hir/Cargo.toml b/src/tools/rust-analyzer/crates/hir/Cargo.toml
index 2af3c2e..c68ff70 100644
--- a/src/tools/rust-analyzer/crates/hir/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/hir/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 rustc-hash.workspace = true
diff --git a/src/tools/rust-analyzer/crates/hir/src/attrs.rs b/src/tools/rust-analyzer/crates/hir/src/attrs.rs
index 0bce69a..c8645b6 100644
--- a/src/tools/rust-analyzer/crates/hir/src/attrs.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/attrs.rs
@@ -207,7 +207,7 @@ fn resolve_assoc_or_field(
             // Doc paths in this context may only resolve to an item of this trait
             // (i.e. no items of its supertraits), so we need to handle them here
             // independently of others.
-            return db.trait_items(id).items.iter().find(|it| it.0 == name).map(|(_, assoc_id)| {
+            return id.trait_items(db).items.iter().find(|it| it.0 == name).map(|(_, assoc_id)| {
                 let def = match *assoc_id {
                     AssocItemId::FunctionId(it) => ModuleDef::Function(it.into()),
                     AssocItemId::ConstId(it) => ModuleDef::Const(it.into()),
diff --git a/src/tools/rust-analyzer/crates/hir/src/diagnostics.rs b/src/tools/rust-analyzer/crates/hir/src/diagnostics.rs
index 074bde9..aba2e03 100644
--- a/src/tools/rust-analyzer/crates/hir/src/diagnostics.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/diagnostics.rs
@@ -490,7 +490,7 @@ pub(crate) fn body_validation_diagnostic(
     ) -> Option<AnyDiagnostic<'db>> {
         match diagnostic {
             BodyValidationDiagnostic::RecordMissingFields { record, variant, missed_fields } => {
-                let variant_data = variant.variant_data(db);
+                let variant_data = variant.fields(db);
                 let missed_fields = missed_fields
                     .into_iter()
                     .map(|idx| variant_data.fields()[idx].name.clone())
diff --git a/src/tools/rust-analyzer/crates/hir/src/display.rs b/src/tools/rust-analyzer/crates/hir/src/display.rs
index 112558b..2960ebe 100644
--- a/src/tools/rust-analyzer/crates/hir/src/display.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/display.rs
@@ -404,7 +404,7 @@ fn hir_fmt(&self, f: &mut HirFormatter<'_>) -> Result<(), HirDisplayError> {
 impl HirDisplay for Variant {
     fn hir_fmt(&self, f: &mut HirFormatter<'_>) -> Result<(), HirDisplayError> {
         write!(f, "{}", self.name(f.db).display(f.db, f.edition()))?;
-        let data = f.db.variant_fields(self.id.into());
+        let data = self.id.fields(f.db);
         match data.shape {
             FieldsShape::Unit => {}
             FieldsShape::Tuple => {
@@ -633,7 +633,7 @@ fn has_disaplayable_predicates(
     params: &GenericParams,
     store: &ExpressionStore,
 ) -> bool {
-    params.where_predicates().any(|pred| {
+    params.where_predicates().iter().any(|pred| {
         !matches!(
             pred,
             WherePredicate::TypeBound { target, .. }
@@ -668,7 +668,7 @@ fn write_where_predicates(
         _ => false,
     };
 
-    let mut iter = params.where_predicates().peekable();
+    let mut iter = params.where_predicates().iter().peekable();
     while let Some(pred) = iter.next() {
         if matches!(pred, TypeBound { target, .. } if is_unnamed_type_target(*target)) {
             continue;
diff --git a/src/tools/rust-analyzer/crates/hir/src/lib.rs b/src/tools/rust-analyzer/crates/hir/src/lib.rs
index 3b39707..e8a1816 100644
--- a/src/tools/rust-analyzer/crates/hir/src/lib.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/lib.rs
@@ -54,7 +54,7 @@
     },
     item_tree::ImportAlias,
     layout::{self, ReprOptions, TargetDataLayout},
-    nameres::{self, diagnostics::DefDiagnostic},
+    nameres::{self, assoc::TraitItems, diagnostics::DefDiagnostic},
     per_ns::PerNs,
     resolver::{HasResolver, Resolver},
     signatures::{ImplFlags, StaticFlags, TraitFlags, VariantFields},
@@ -649,7 +649,7 @@ pub fn diagnostics<'db>(
                     acc.extend(def.diagnostics(db, style_lints))
                 }
                 ModuleDef::Trait(t) => {
-                    for diag in db.trait_items_with_diagnostics(t.id).1.iter() {
+                    for diag in TraitItems::query_with_diagnostics(db, t.id).1.iter() {
                         emit_def_diagnostic(db, acc, diag, edition);
                     }
 
@@ -668,25 +668,25 @@ pub fn diagnostics<'db>(
                         Adt::Struct(s) => {
                             let source_map = db.struct_signature_with_source_map(s.id).1;
                             expr_store_diagnostics(db, acc, &source_map);
-                            let source_map = db.variant_fields_with_source_map(s.id.into()).1;
-                            expr_store_diagnostics(db, acc, &source_map);
+                            let source_map = &s.id.fields_with_source_map(db).1;
+                            expr_store_diagnostics(db, acc, source_map);
                             push_ty_diagnostics(
                                 db,
                                 acc,
                                 db.field_types_with_diagnostics(s.id.into()).1,
-                                &source_map,
+                                source_map,
                             );
                         }
                         Adt::Union(u) => {
                             let source_map = db.union_signature_with_source_map(u.id).1;
                             expr_store_diagnostics(db, acc, &source_map);
-                            let source_map = db.variant_fields_with_source_map(u.id.into()).1;
-                            expr_store_diagnostics(db, acc, &source_map);
+                            let source_map = &u.id.fields_with_source_map(db).1;
+                            expr_store_diagnostics(db, acc, source_map);
                             push_ty_diagnostics(
                                 db,
                                 acc,
                                 db.field_types_with_diagnostics(u.id.into()).1,
-                                &source_map,
+                                source_map,
                             );
                         }
                         Adt::Enum(e) => {
@@ -711,14 +711,14 @@ pub fn diagnostics<'db>(
                                 }
                             }
                             for &(v, _, _) in &variants.variants {
-                                let source_map = db.variant_fields_with_source_map(v.into()).1;
+                                let source_map = &v.fields_with_source_map(db).1;
                                 push_ty_diagnostics(
                                     db,
                                     acc,
                                     db.field_types_with_diagnostics(v.into()).1,
-                                    &source_map,
+                                    source_map,
                                 );
-                                expr_store_diagnostics(db, acc, &source_map);
+                                expr_store_diagnostics(db, acc, source_map);
                             }
                         }
                     }
@@ -822,7 +822,7 @@ pub fn diagnostics<'db>(
 
             // Negative impls can't have items, don't emit missing items diagnostic for them
             if let (false, Some(trait_)) = (impl_is_negative, trait_) {
-                let items = &db.trait_items(trait_.into()).items;
+                let items = &trait_.id.trait_items(db).items;
                 let required_items = items.iter().filter(|&(_, assoc)| match *assoc {
                     AssocItemId::FunctionId(it) => !db.function_signature(it).has_body(),
                     AssocItemId::ConstId(id) => !db.const_signature(id).has_body(),
@@ -1311,7 +1311,7 @@ fn syntax(&self) -> &SyntaxNode {
 
 impl Field {
     pub fn name(&self, db: &dyn HirDatabase) -> Name {
-        db.variant_fields(self.parent.into()).fields()[self.id].name.clone()
+        VariantId::from(self.parent).fields(db).fields()[self.id].name.clone()
     }
 
     pub fn index(&self) -> usize {
@@ -1380,7 +1380,7 @@ pub fn parent_def(&self, _db: &dyn HirDatabase) -> VariantDef {
 
 impl HasVisibility for Field {
     fn visibility(&self, db: &dyn HirDatabase) -> Visibility {
-        let variant_data = db.variant_fields(self.parent.into());
+        let variant_data = VariantId::from(self.parent).fields(db);
         let visibility = &variant_data.fields()[self.id].visibility;
         let parent_id: hir_def::VariantId = self.parent.into();
         // FIXME: RawVisibility::Public doesn't need to construct a resolver
@@ -1403,7 +1403,8 @@ pub fn name(self, db: &dyn HirDatabase) -> Name {
     }
 
     pub fn fields(self, db: &dyn HirDatabase) -> Vec<Field> {
-        db.variant_fields(self.id.into())
+        self.id
+            .fields(db)
             .fields()
             .iter()
             .map(|(id, _)| Field { parent: self.into(), id })
@@ -1434,8 +1435,8 @@ pub fn kind(self, db: &dyn HirDatabase) -> StructKind {
         }
     }
 
-    fn variant_fields(self, db: &dyn HirDatabase) -> Arc<VariantFields> {
-        db.variant_fields(self.id.into())
+    fn variant_fields(self, db: &dyn HirDatabase) -> &VariantFields {
+        self.id.fields(db)
     }
 
     pub fn is_unstable(self, db: &dyn HirDatabase) -> bool {
@@ -1478,7 +1479,7 @@ pub fn constructor_ty(self, db: &dyn HirDatabase) -> Type<'_> {
     }
 
     pub fn kind(self, db: &dyn HirDatabase) -> StructKind {
-        match db.variant_fields(self.id.into()).shape {
+        match self.id.fields(db).shape {
             hir_def::item_tree::FieldsShape::Record => StructKind::Record,
             hir_def::item_tree::FieldsShape::Tuple => StructKind::Tuple,
             hir_def::item_tree::FieldsShape::Unit => StructKind::Unit,
@@ -1486,7 +1487,8 @@ pub fn kind(self, db: &dyn HirDatabase) -> StructKind {
     }
 
     pub fn fields(self, db: &dyn HirDatabase) -> Vec<Field> {
-        db.variant_fields(self.id.into())
+        self.id
+            .fields(db)
             .fields()
             .iter()
             .map(|(id, _)| Field { parent: self.into(), id })
@@ -1626,7 +1628,8 @@ pub fn name(self, db: &dyn HirDatabase) -> Name {
     }
 
     pub fn fields(self, db: &dyn HirDatabase) -> Vec<Field> {
-        db.variant_fields(self.id.into())
+        self.id
+            .fields(db)
             .fields()
             .iter()
             .map(|(id, _)| Field { parent: self.into(), id })
@@ -1634,7 +1637,7 @@ pub fn fields(self, db: &dyn HirDatabase) -> Vec<Field> {
     }
 
     pub fn kind(self, db: &dyn HirDatabase) -> StructKind {
-        match db.variant_fields(self.id.into()).shape {
+        match self.id.fields(db).shape {
             hir_def::item_tree::FieldsShape::Record => StructKind::Record,
             hir_def::item_tree::FieldsShape::Tuple => StructKind::Tuple,
             hir_def::item_tree::FieldsShape::Unit => StructKind::Unit,
@@ -1727,10 +1730,10 @@ pub fn ty(self, db: &dyn HirDatabase) -> Type<'_> {
     pub fn ty_with_args<'db>(
         self,
         db: &'db dyn HirDatabase,
-        args: impl Iterator<Item = Type<'db>>,
+        args: impl IntoIterator<Item = Type<'db>>,
     ) -> Type<'db> {
         let id = AdtId::from(self);
-        let mut it = args.map(|t| t.ty);
+        let mut it = args.into_iter().map(|t| t.ty);
         let ty = TyBuilder::def_ty(db, id.into(), None)
             .fill(|x| {
                 let r = it.next().unwrap_or_else(|| TyKind::Error.intern(Interner));
@@ -2883,7 +2886,7 @@ pub fn all_supertraits(self, db: &dyn HirDatabase) -> Vec<Trait> {
     }
 
     pub fn function(self, db: &dyn HirDatabase, name: impl PartialEq<Name>) -> Option<Function> {
-        db.trait_items(self.id).items.iter().find(|(n, _)| name == *n).and_then(|&(_, it)| match it
+        self.id.trait_items(db).items.iter().find(|(n, _)| name == *n).and_then(|&(_, it)| match it
         {
             AssocItemId::FunctionId(id) => Some(Function { id }),
             _ => None,
@@ -2891,7 +2894,7 @@ pub fn function(self, db: &dyn HirDatabase, name: impl PartialEq<Name>) -> Optio
     }
 
     pub fn items(self, db: &dyn HirDatabase) -> Vec<AssocItem> {
-        db.trait_items(self.id).items.iter().map(|(_name, it)| (*it).into()).collect()
+        self.id.trait_items(db).items.iter().map(|(_name, it)| (*it).into()).collect()
     }
 
     pub fn items_with_supertraits(self, db: &dyn HirDatabase) -> Vec<AssocItem> {
@@ -2939,7 +2942,7 @@ pub fn dyn_compatibility_all_violations(
     }
 
     fn all_macro_calls(&self, db: &dyn HirDatabase) -> Box<[(AstId<ast::Item>, MacroCallId)]> {
-        db.trait_items(self.id).macro_calls.to_vec().into_boxed_slice()
+        self.id.trait_items(db).macro_calls.to_vec().into_boxed_slice()
     }
 
     /// `#[rust_analyzer::completions(...)]` mode.
@@ -3043,10 +3046,17 @@ pub struct BuiltinType {
 }
 
 impl BuiltinType {
+    // Constructors are added on demand, feel free to add more.
     pub fn str() -> BuiltinType {
         BuiltinType { inner: hir_def::builtin_type::BuiltinType::Str }
     }
 
+    pub fn i32() -> BuiltinType {
+        BuiltinType {
+            inner: hir_def::builtin_type::BuiltinType::Int(hir_ty::primitive::BuiltinInt::I32),
+        }
+    }
+
     pub fn ty<'db>(self, db: &'db dyn HirDatabase) -> Type<'db> {
         let core = Crate::core(db).map(|core| core.id).unwrap_or_else(|| db.all_crates()[0]);
         Type::new_for_crate(core, TyBuilder::builtin(self.inner))
@@ -3667,7 +3677,7 @@ pub fn diagnostics<'db>(self, db: &'db dyn HirDatabase, acc: &mut Vec<AnyDiagnos
 
         let generics = db.generic_params(def);
 
-        if generics.is_empty() && generics.no_predicates() {
+        if generics.is_empty() && generics.has_no_predicates() {
             return;
         }
 
@@ -5000,7 +5010,7 @@ pub fn into_future_output(&self, db: &'db dyn HirDatabase) -> Option<Type<'db>>
         }
 
         let output_assoc_type =
-            db.trait_items(trait_).associated_type_by_name(&Name::new_symbol_root(sym::Output))?;
+            trait_.trait_items(db).associated_type_by_name(&Name::new_symbol_root(sym::Output))?;
         self.normalize_trait_assoc_type(db, &[], output_assoc_type.into())
     }
 
@@ -5013,8 +5023,8 @@ pub fn future_output(self, db: &'db dyn HirDatabase) -> Option<Type<'db>> {
     /// This does **not** resolve `IntoIterator`, only `Iterator`.
     pub fn iterator_item(self, db: &'db dyn HirDatabase) -> Option<Type<'db>> {
         let iterator_trait = LangItem::Iterator.resolve_trait(db, self.env.krate)?;
-        let iterator_item = db
-            .trait_items(iterator_trait)
+        let iterator_item = iterator_trait
+            .trait_items(db)
             .associated_type_by_name(&Name::new_symbol_root(sym::Item))?;
         self.normalize_trait_assoc_type(db, &[], iterator_item.into())
     }
@@ -5044,8 +5054,8 @@ pub fn into_iterator_iter(self, db: &'db dyn HirDatabase) -> Option<Type<'db>> {
             return None;
         }
 
-        let into_iter_assoc_type = db
-            .trait_items(trait_)
+        let into_iter_assoc_type = trait_
+            .trait_items(db)
             .associated_type_by_name(&Name::new_symbol_root(sym::IntoIter))?;
         self.normalize_trait_assoc_type(db, &[], into_iter_assoc_type.into())
     }
diff --git a/src/tools/rust-analyzer/crates/hir/src/semantics.rs b/src/tools/rust-analyzer/crates/hir/src/semantics.rs
index d969758..247bb69 100644
--- a/src/tools/rust-analyzer/crates/hir/src/semantics.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/semantics.rs
@@ -2199,6 +2199,10 @@ pub struct SemanticsScope<'db> {
 }
 
 impl<'db> SemanticsScope<'db> {
+    pub fn file_id(&self) -> HirFileId {
+        self.file_id
+    }
+
     pub fn module(&self) -> Module {
         Module { id: self.resolver.module() }
     }
diff --git a/src/tools/rust-analyzer/crates/hir/src/semantics/child_by_source.rs b/src/tools/rust-analyzer/crates/hir/src/semantics/child_by_source.rs
index fedd823..e7db93d 100644
--- a/src/tools/rust-analyzer/crates/hir/src/semantics/child_by_source.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/semantics/child_by_source.rs
@@ -35,7 +35,7 @@ fn child_by_source(&self, db: &dyn DefDatabase, file_id: HirFileId) -> DynMap {
 
 impl ChildBySource for TraitId {
     fn child_by_source_to(&self, db: &dyn DefDatabase, res: &mut DynMap, file_id: HirFileId) {
-        let data = db.trait_items(*self);
+        let data = self.trait_items(db);
 
         data.macro_calls().filter(|(ast_id, _)| ast_id.file_id == file_id).for_each(
             |(ast_id, call_id)| {
@@ -191,7 +191,7 @@ fn child_by_source_to(&self, db: &dyn DefDatabase, res: &mut DynMap, _: HirFileI
                 Either::Right(source) => res[keys::RECORD_FIELD].insert(AstPtr::new(&source), id),
             }
         }
-        let (_, sm) = db.variant_fields_with_source_map(*self);
+        let (_, sm) = self.fields_with_source_map(db);
         sm.expansions().for_each(|(ast, &exp_id)| res[keys::MACRO_CALL].insert(ast.value, exp_id));
     }
 }
diff --git a/src/tools/rust-analyzer/crates/hir/src/source_analyzer.rs b/src/tools/rust-analyzer/crates/hir/src/source_analyzer.rs
index 48543ca..f18ca7c 100644
--- a/src/tools/rust-analyzer/crates/hir/src/source_analyzer.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/source_analyzer.rs
@@ -156,14 +156,14 @@ pub(crate) fn new_variant_body(
         InFile { file_id, .. }: InFile<&SyntaxNode>,
         _offset: Option<TextSize>,
     ) -> SourceAnalyzer<'db> {
-        let (fields, source_map) = db.variant_fields_with_source_map(def);
+        let (fields, source_map) = def.fields_with_source_map(db);
         let resolver = def.resolver(db);
         SourceAnalyzer {
             resolver,
             body_or_sig: Some(BodyOrSig::VariantFields {
                 def,
                 store: fields.store.clone(),
-                source_map,
+                source_map: source_map.clone(),
             }),
             file_id,
         }
@@ -713,7 +713,7 @@ pub(crate) fn resolve_record_field(
         };
         let (adt, subst) = self.infer()?.type_of_expr_or_pat(expr_id)?.as_adt()?;
         let variant = self.infer()?.variant_resolution_for_expr_or_pat(expr_id)?;
-        let variant_data = variant.variant_data(db);
+        let variant_data = variant.fields(db);
         let field = FieldId { parent: variant, local_id: variant_data.field(&local_name)? };
         let field_ty =
             db.field_types(variant).get(field.local_id)?.clone().substitute(Interner, subst);
@@ -734,7 +734,7 @@ pub(crate) fn resolve_record_pat_field(
         let record_pat = ast::RecordPat::cast(field.syntax().parent().and_then(|p| p.parent())?)?;
         let pat_id = self.pat_id(&record_pat.into())?;
         let variant = self.infer()?.variant_resolution_for_pat(pat_id.as_pat()?)?;
-        let variant_data = variant.variant_data(db);
+        let variant_data = variant.fields(db);
         let field = FieldId { parent: variant, local_id: variant_data.field(&field_name)? };
         let (adt, subst) = self.infer()?.type_of_pat.get(pat_id.as_pat()?)?.as_adt()?;
         let field_ty =
@@ -803,8 +803,8 @@ pub(crate) fn resolve_offset_of_field(
                 };
                 container = Either::Right(db.normalize_projection(projection, trait_env.clone()));
             }
-            let handle_variants = |variant, subst: &Substitution, container: &mut _| {
-                let fields = db.variant_fields(variant);
+            let handle_variants = |variant: VariantId, subst: &Substitution, container: &mut _| {
+                let fields = variant.fields(db);
                 let field = fields.field(&field_name.as_name())?;
                 let field_types = db.field_types(variant);
                 *container = Either::Right(field_types[field].clone().substitute(Interner, subst));
@@ -1423,7 +1423,7 @@ fn lang_trait_fn(
         method_name: &Name,
     ) -> Option<(TraitId, FunctionId)> {
         let trait_id = lang_trait.resolve_trait(db, self.resolver.krate())?;
-        let fn_id = db.trait_items(trait_id).method_by_name(method_name)?;
+        let fn_id = trait_id.trait_items(db).method_by_name(method_name)?;
         Some((trait_id, fn_id))
     }
 
@@ -1580,7 +1580,7 @@ fn resolve_hir_path_(
         // within the trait's associated types.
         if let (Some(unresolved), &TypeNs::TraitId(trait_id)) = (&unresolved, &ty) {
             if let Some(type_alias_id) =
-                db.trait_items(trait_id).associated_type_by_name(unresolved.name)
+                trait_id.trait_items(db).associated_type_by_name(unresolved.name)
             {
                 return Some(PathResolution::Def(ModuleDefId::from(type_alias_id).into()));
             }
@@ -1731,7 +1731,7 @@ fn resolve_hir_path_qualifier(
         // within the trait's associated types.
         if let (Some(unresolved), &TypeNs::TraitId(trait_id)) = (&unresolved, &ty) {
             if let Some(type_alias_id) =
-                db.trait_items(trait_id).associated_type_by_name(unresolved.name)
+                trait_id.trait_items(db).associated_type_by_name(unresolved.name)
             {
                 return Some(PathResolution::Def(ModuleDefId::from(type_alias_id).into()));
             }
diff --git a/src/tools/rust-analyzer/crates/hir/src/symbols.rs b/src/tools/rust-analyzer/crates/hir/src/symbols.rs
index 64f2a91..7566508 100644
--- a/src/tools/rust-analyzer/crates/hir/src/symbols.rs
+++ b/src/tools/rust-analyzer/crates/hir/src/symbols.rs
@@ -334,7 +334,7 @@ fn collect_from_impl(&mut self, impl_id: ImplId) {
     fn collect_from_trait(&mut self, trait_id: TraitId, trait_do_not_complete: Complete) {
         let trait_data = self.db.trait_signature(trait_id);
         self.with_container_name(Some(trait_data.name.as_str().into()), |s| {
-            for &(ref name, assoc_item_id) in &self.db.trait_items(trait_id).items {
+            for &(ref name, assoc_item_id) in &trait_id.trait_items(self.db).items {
                 s.push_assoc_item(assoc_item_id, name, Some(trait_do_not_complete));
             }
         });
diff --git a/src/tools/rust-analyzer/crates/ide-assists/Cargo.toml b/src/tools/rust-analyzer/crates/ide-assists/Cargo.toml
index 53af980..385b0e1 100644
--- a/src/tools/rust-analyzer/crates/ide-assists/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/ide-assists/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_is_method.rs b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_is_method.rs
index 3e6d0be..517906b 100644
--- a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_is_method.rs
+++ b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_is_method.rs
@@ -1,3 +1,5 @@
+use std::slice;
+
 use ide_db::assists::GroupLabel;
 use stdx::to_lower_snake_case;
 use syntax::ast::HasVisibility;
@@ -52,7 +54,7 @@ pub(crate) fn generate_enum_is_method(acc: &mut Assists, ctx: &AssistContext<'_>
     let fn_name = format!("is_{}", &to_lower_snake_case(&variant_name.text()));
 
     // Return early if we've found an existing new fn
-    let impl_def = find_struct_impl(ctx, &parent_enum, &[fn_name.clone()])?;
+    let impl_def = find_struct_impl(ctx, &parent_enum, slice::from_ref(&fn_name))?;
 
     let target = variant.syntax().text_range();
     acc.add_group(
diff --git a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_projection_method.rs b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_projection_method.rs
index 3974bcf..e4b0f83 100644
--- a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_projection_method.rs
+++ b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/generate_enum_projection_method.rs
@@ -1,3 +1,5 @@
+use std::slice;
+
 use ide_db::assists::GroupLabel;
 use itertools::Itertools;
 use stdx::to_lower_snake_case;
@@ -148,7 +150,7 @@ fn generate_enum_projection_method(
     let fn_name = format!("{fn_name_prefix}_{}", &to_lower_snake_case(&variant_name.text()));
 
     // Return early if we've found an existing new fn
-    let impl_def = find_struct_impl(ctx, &parent_enum, &[fn_name.clone()])?;
+    let impl_def = find_struct_impl(ctx, &parent_enum, slice::from_ref(&fn_name))?;
 
     let target = variant.syntax().text_range();
     acc.add_group(
diff --git a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/term_search.rs b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/term_search.rs
index 019ddaf..6527d37 100644
--- a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/term_search.rs
+++ b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/term_search.rs
@@ -100,9 +100,7 @@ fn test_complete_local() {
     fn test_complete_todo_with_msg() {
         check_assist(
             term_search,
-            // FIXME: Since we are lacking of `super let`, term search fails due to borrowck failure.
-            // Should implement super let and remove `fmt_before_1_89_0`
-            r#"//- minicore: todo, unimplemented, fmt_before_1_89_0
+            r#"//- minicore: todo, unimplemented
 fn f() { let a: u128 = 1; let b: u128 = todo$0!("asd") }"#,
             r#"fn f() { let a: u128 = 1; let b: u128 = a }"#,
         )
@@ -112,10 +110,8 @@ fn test_complete_todo_with_msg() {
     fn test_complete_unimplemented_with_msg() {
         check_assist(
             term_search,
-            // FIXME: Since we are lacking of `super let`, term search fails due to borrowck failure.
-            // Should implement super let and remove `fmt_before_1_89_0`
-            r#"//- minicore: todo, unimplemented, fmt_before_1_89_0
-fn f() { let a: u128 = 1; let b: u128 = todo$0!("asd") }"#,
+            r#"//- minicore: todo, unimplemented
+fn f() { let a: u128 = 1; let b: u128 = unimplemented$0!("asd") }"#,
             r#"fn f() { let a: u128 = 1; let b: u128 = a }"#,
         )
     }
@@ -124,10 +120,8 @@ fn test_complete_unimplemented_with_msg() {
     fn test_complete_unimplemented() {
         check_assist(
             term_search,
-            // FIXME: Since we are lacking of `super let`, term search fails due to borrowck failure.
-            // Should implement super let and remove `fmt_before_1_89_0`
-            r#"//- minicore: todo, unimplemented, fmt_before_1_89_0
-fn f() { let a: u128 = 1; let b: u128 = todo$0!("asd") }"#,
+            r#"//- minicore: todo, unimplemented
+fn f() { let a: u128 = 1; let b: u128 = unimplemented$0!() }"#,
             r#"fn f() { let a: u128 = 1; let b: u128 = a }"#,
         )
     }
diff --git a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/wrap_return_type.rs b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/wrap_return_type.rs
index 9ea7871..d7189aa 100644
--- a/src/tools/rust-analyzer/crates/ide-assists/src/handlers/wrap_return_type.rs
+++ b/src/tools/rust-analyzer/crates/ide-assists/src/handlers/wrap_return_type.rs
@@ -56,7 +56,8 @@ pub(crate) fn wrap_return_type(acc: &mut Assists, ctx: &AssistContext<'_>) -> Op
     };
 
     let type_ref = &ret_type.ty()?;
-    let ty = ctx.sema.resolve_type(type_ref)?.as_adt();
+    let ty = ctx.sema.resolve_type(type_ref)?;
+    let ty_adt = ty.as_adt();
     let famous_defs = FamousDefs(&ctx.sema, ctx.sema.scope(type_ref.syntax())?.krate());
 
     for kind in WrapperKind::ALL {
@@ -64,7 +65,7 @@ pub(crate) fn wrap_return_type(acc: &mut Assists, ctx: &AssistContext<'_>) -> Op
             continue;
         };
 
-        if matches!(ty, Some(hir::Adt::Enum(ret_type)) if ret_type == core_wrapper) {
+        if matches!(ty_adt, Some(hir::Adt::Enum(ret_type)) if ret_type == core_wrapper) {
             // The return type is already wrapped
             cov_mark::hit!(wrap_return_type_simple_return_type_already_wrapped);
             continue;
@@ -78,10 +79,23 @@ pub(crate) fn wrap_return_type(acc: &mut Assists, ctx: &AssistContext<'_>) -> Op
             |builder| {
                 let mut editor = builder.make_editor(&parent);
                 let make = SyntaxFactory::with_mappings();
-                let alias = wrapper_alias(ctx, &make, &core_wrapper, type_ref, kind.symbol());
-                let new_return_ty = alias.unwrap_or_else(|| match kind {
-                    WrapperKind::Option => make.ty_option(type_ref.clone()),
-                    WrapperKind::Result => make.ty_result(type_ref.clone(), make.ty_infer().into()),
+                let alias = wrapper_alias(ctx, &make, core_wrapper, type_ref, &ty, kind.symbol());
+                let (ast_new_return_ty, semantic_new_return_ty) = alias.unwrap_or_else(|| {
+                    let (ast_ty, ty_constructor) = match kind {
+                        WrapperKind::Option => {
+                            (make.ty_option(type_ref.clone()), famous_defs.core_option_Option())
+                        }
+                        WrapperKind::Result => (
+                            make.ty_result(type_ref.clone(), make.ty_infer().into()),
+                            famous_defs.core_result_Result(),
+                        ),
+                    };
+                    let semantic_ty = ty_constructor
+                        .map(|ty_constructor| {
+                            hir::Adt::from(ty_constructor).ty_with_args(ctx.db(), [ty.clone()])
+                        })
+                        .unwrap_or_else(|| ty.clone());
+                    (ast_ty, semantic_ty)
                 });
 
                 let mut exprs_to_wrap = Vec::new();
@@ -96,6 +110,17 @@ pub(crate) fn wrap_return_type(acc: &mut Assists, ctx: &AssistContext<'_>) -> Op
                 for_each_tail_expr(&body_expr, tail_cb);
 
                 for ret_expr_arg in exprs_to_wrap {
+                    if let Some(ty) = ctx.sema.type_of_expr(&ret_expr_arg) {
+                        if ty.adjusted().could_unify_with(ctx.db(), &semantic_new_return_ty) {
+                            // The type is already correct, don't wrap it.
+                            // We deliberately don't use `could_unify_with_deeply()`, because as long as the outer
+                            // enum matches it's okay for us, as we don't trigger the assist if the return type
+                            // is already `Option`/`Result`, so mismatched exact type is more likely a mistake
+                            // than something intended.
+                            continue;
+                        }
+                    }
+
                     let happy_wrapped = make.expr_call(
                         make.expr_path(make.ident_path(kind.happy_ident())),
                         make.arg_list(iter::once(ret_expr_arg.clone())),
@@ -103,12 +128,12 @@ pub(crate) fn wrap_return_type(acc: &mut Assists, ctx: &AssistContext<'_>) -> Op
                     editor.replace(ret_expr_arg.syntax(), happy_wrapped.syntax());
                 }
 
-                editor.replace(type_ref.syntax(), new_return_ty.syntax());
+                editor.replace(type_ref.syntax(), ast_new_return_ty.syntax());
 
                 if let WrapperKind::Result = kind {
                     // Add a placeholder snippet at the first generic argument that doesn't equal the return type.
                     // This is normally the error type, but that may not be the case when we inserted a type alias.
-                    let args = new_return_ty
+                    let args = ast_new_return_ty
                         .path()
                         .unwrap()
                         .segment()
@@ -188,27 +213,28 @@ fn symbol(&self) -> hir::Symbol {
 }
 
 // Try to find an wrapper type alias in the current scope (shadowing the default).
-fn wrapper_alias(
-    ctx: &AssistContext<'_>,
+fn wrapper_alias<'db>(
+    ctx: &AssistContext<'db>,
     make: &SyntaxFactory,
-    core_wrapper: &hir::Enum,
-    ret_type: &ast::Type,
+    core_wrapper: hir::Enum,
+    ast_ret_type: &ast::Type,
+    semantic_ret_type: &hir::Type<'db>,
     wrapper: hir::Symbol,
-) -> Option<ast::PathType> {
+) -> Option<(ast::PathType, hir::Type<'db>)> {
     let wrapper_path = hir::ModPath::from_segments(
         hir::PathKind::Plain,
         iter::once(hir::Name::new_symbol_root(wrapper)),
     );
 
-    ctx.sema.resolve_mod_path(ret_type.syntax(), &wrapper_path).and_then(|def| {
+    ctx.sema.resolve_mod_path(ast_ret_type.syntax(), &wrapper_path).and_then(|def| {
         def.filter_map(|def| match def.into_module_def() {
             hir::ModuleDef::TypeAlias(alias) => {
                 let enum_ty = alias.ty(ctx.db()).as_adt()?.as_enum()?;
-                (&enum_ty == core_wrapper).then_some(alias)
+                (enum_ty == core_wrapper).then_some((alias, enum_ty))
             }
             _ => None,
         })
-        .find_map(|alias| {
+        .find_map(|(alias, enum_ty)| {
             let mut inserted_ret_type = false;
             let generic_args =
                 alias.source(ctx.db())?.value.generic_param_list()?.generic_params().map(|param| {
@@ -216,7 +242,7 @@ fn wrapper_alias(
                         // Replace the very first type parameter with the function's return type.
                         ast::GenericParam::TypeParam(_) if !inserted_ret_type => {
                             inserted_ret_type = true;
-                            make.type_arg(ret_type.clone()).into()
+                            make.type_arg(ast_ret_type.clone()).into()
                         }
                         ast::GenericParam::LifetimeParam(_) => {
                             make.lifetime_arg(make.lifetime("'_")).into()
@@ -231,7 +257,10 @@ fn wrapper_alias(
                 make.path_segment_generics(make.name_ref(name.as_str()), generic_arg_list),
             );
 
-            Some(make.ty_path(path))
+            let new_ty =
+                hir::Adt::from(enum_ty).ty_with_args(ctx.db(), [semantic_ret_type.clone()]);
+
+            Some((make.ty_path(path), new_ty))
         })
     })
 }
@@ -605,29 +634,39 @@ fn wrap_return_type_in_option_simple_with_await() {
         check_assist_by_label(
             wrap_return_type,
             r#"
-//- minicore: option
+//- minicore: option, future
+struct F(i32);
+impl core::future::Future for F {
+    type Output = i32;
+    fn poll(self: core::pin::Pin<&mut Self>, cx: &mut core::task::Context<'_>) -> core::task::Poll<Self::Output> { 0 }
+}
 async fn foo() -> i$032 {
     if true {
         if false {
-            1.await
+            F(1).await
         } else {
-            2.await
+            F(2).await
         }
     } else {
-        24i32.await
+        F(24i32).await
     }
 }
 "#,
             r#"
+struct F(i32);
+impl core::future::Future for F {
+    type Output = i32;
+    fn poll(self: core::pin::Pin<&mut Self>, cx: &mut core::task::Context<'_>) -> core::task::Poll<Self::Output> { 0 }
+}
 async fn foo() -> Option<i32> {
     if true {
         if false {
-            Some(1.await)
+            Some(F(1).await)
         } else {
-            Some(2.await)
+            Some(F(2).await)
         }
     } else {
-        Some(24i32.await)
+        Some(F(24i32).await)
     }
 }
 "#,
@@ -1666,29 +1705,39 @@ fn wrap_return_type_in_result_simple_with_await() {
         check_assist_by_label(
             wrap_return_type,
             r#"
-//- minicore: result
+//- minicore: result, future
+struct F(i32);
+impl core::future::Future for F {
+    type Output = i32;
+    fn poll(self: core::pin::Pin<&mut Self>, cx: &mut core::task::Context<'_>) -> core::task::Poll<Self::Output> { 0 }
+}
 async fn foo() -> i$032 {
     if true {
         if false {
-            1.await
+            F(1).await
         } else {
-            2.await
+            F(2).await
         }
     } else {
-        24i32.await
+        F(24i32).await
     }
 }
 "#,
             r#"
+struct F(i32);
+impl core::future::Future for F {
+    type Output = i32;
+    fn poll(self: core::pin::Pin<&mut Self>, cx: &mut core::task::Context<'_>) -> core::task::Poll<Self::Output> { 0 }
+}
 async fn foo() -> Result<i32, ${0:_}> {
     if true {
         if false {
-            Ok(1.await)
+            Ok(F(1).await)
         } else {
-            Ok(2.await)
+            Ok(F(2).await)
         }
     } else {
-        Ok(24i32.await)
+        Ok(F(24i32).await)
     }
 }
 "#,
@@ -2460,4 +2509,54 @@ fn foo() -> Result<i32, ${0:_}> {
             WrapperKind::Result.label(),
         );
     }
+
+    #[test]
+    fn already_wrapped() {
+        check_assist_by_label(
+            wrap_return_type,
+            r#"
+//- minicore: option
+fn foo() -> i32$0 {
+    if false {
+        0
+    } else {
+        Some(1)
+    }
+}
+            "#,
+            r#"
+fn foo() -> Option<i32> {
+    if false {
+        Some(0)
+    } else {
+        Some(1)
+    }
+}
+            "#,
+            WrapperKind::Option.label(),
+        );
+        check_assist_by_label(
+            wrap_return_type,
+            r#"
+//- minicore: result
+fn foo() -> i32$0 {
+    if false {
+        0
+    } else {
+        Ok(1)
+    }
+}
+            "#,
+            r#"
+fn foo() -> Result<i32, ${0:_}> {
+    if false {
+        Ok(0)
+    } else {
+        Ok(1)
+    }
+}
+            "#,
+            WrapperKind::Result.label(),
+        );
+    }
 }
diff --git a/src/tools/rust-analyzer/crates/ide-completion/Cargo.toml b/src/tools/rust-analyzer/crates/ide-completion/Cargo.toml
index 94c01e3..9bad21f 100644
--- a/src/tools/rust-analyzer/crates/ide-completion/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/ide-completion/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/ide-completion/src/completions/fn_param.rs b/src/tools/rust-analyzer/crates/ide-completion/src/completions/fn_param.rs
index 6d1e973..809e71c 100644
--- a/src/tools/rust-analyzer/crates/ide-completion/src/completions/fn_param.rs
+++ b/src/tools/rust-analyzer/crates/ide-completion/src/completions/fn_param.rs
@@ -195,5 +195,5 @@ fn comma_wrapper(ctx: &CompletionContext<'_>) -> Option<(impl Fn(&str) -> String
         matches!(prev_token_kind, SyntaxKind::COMMA | SyntaxKind::L_PAREN | SyntaxKind::PIPE);
     let leading = if has_leading_comma { "" } else { ", " };
 
-    Some((move |label: &_| (format!("{leading}{label}{trailing}")), param.text_range()))
+    Some((move |label: &_| format!("{leading}{label}{trailing}"), param.text_range()))
 }
diff --git a/src/tools/rust-analyzer/crates/ide-completion/src/context/analysis.rs b/src/tools/rust-analyzer/crates/ide-completion/src/context/analysis.rs
index 6e3a76f..ea5fb39 100644
--- a/src/tools/rust-analyzer/crates/ide-completion/src/context/analysis.rs
+++ b/src/tools/rust-analyzer/crates/ide-completion/src/context/analysis.rs
@@ -4,6 +4,7 @@
 use hir::{ExpandResult, InFile, Semantics, Type, TypeInfo, Variant};
 use ide_db::{RootDatabase, active_parameter::ActiveParameter};
 use itertools::Either;
+use stdx::always;
 use syntax::{
     AstNode, AstToken, Direction, NodeOrToken, SyntaxElement, SyntaxKind, SyntaxNode, SyntaxToken,
     T, TextRange, TextSize,
@@ -869,8 +870,15 @@ fn classify_name_ref<'db>(
                     return None;
                 }
 
+                let mut receiver_ty = receiver.as_ref().and_then(|it| sema.type_of_expr(it));
+                if receiver_is_ambiguous_float_literal {
+                    // `123.|` is parsed as a float but should actually be an integer.
+                    always!(receiver_ty.as_ref().is_none_or(|receiver_ty| receiver_ty.original.is_float()));
+                    receiver_ty = Some(TypeInfo { original: hir::BuiltinType::i32().ty(sema.db), adjusted: None });
+                }
+
                 let kind = NameRefKind::DotAccess(DotAccess {
-                    receiver_ty: receiver.as_ref().and_then(|it| sema.type_of_expr(it)),
+                    receiver_ty,
                     kind: DotAccessKind::Field { receiver_is_ambiguous_float_literal },
                     receiver,
                     ctx: DotAccessExprCtx { in_block_expr: is_in_block(field.syntax()), in_breakable: is_in_breakable(field.syntax()) }
diff --git a/src/tools/rust-analyzer/crates/ide-completion/src/tests/expression.rs b/src/tools/rust-analyzer/crates/ide-completion/src/tests/expression.rs
index b2d18b7..33f729f 100644
--- a/src/tools/rust-analyzer/crates/ide-completion/src/tests/expression.rs
+++ b/src/tools/rust-analyzer/crates/ide-completion/src/tests/expression.rs
@@ -2241,3 +2241,37 @@ fn main() {
     "#,
     );
 }
+
+#[test]
+fn ambiguous_float_literal() {
+    check(
+        r#"
+#![rustc_coherence_is_core]
+
+impl i32 {
+    pub fn int_method(self) {}
+}
+impl f64 {
+    pub fn float_method(self) {}
+}
+
+fn foo() {
+    1.$0
+}
+    "#,
+        expect![[r#"
+            me int_method() fn(self)
+            sn box    Box::new(expr)
+            sn call   function(expr)
+            sn const        const {}
+            sn dbg        dbg!(expr)
+            sn dbgr      dbg!(&expr)
+            sn deref           *expr
+            sn match   match expr {}
+            sn ref             &expr
+            sn refm        &mut expr
+            sn return    return expr
+            sn unsafe      unsafe {}
+        "#]],
+    );
+}
diff --git a/src/tools/rust-analyzer/crates/ide-completion/src/tests/item_list.rs b/src/tools/rust-analyzer/crates/ide-completion/src/tests/item_list.rs
index fcdf10c..179d669 100644
--- a/src/tools/rust-analyzer/crates/ide-completion/src/tests/item_list.rs
+++ b/src/tools/rust-analyzer/crates/ide-completion/src/tests/item_list.rs
@@ -550,3 +550,30 @@ fn inside_extern_blocks() {
         "#]],
     )
 }
+
+#[test]
+fn tokens_from_macro() {
+    check_edit(
+        "fn as_ref",
+        r#"
+//- proc_macros: identity
+//- minicore: as_ref
+struct Foo;
+
+#[proc_macros::identity]
+impl<'a> AsRef<&'a i32> for Foo {
+    $0
+}
+    "#,
+        r#"
+struct Foo;
+
+#[proc_macros::identity]
+impl<'a> AsRef<&'a i32> for Foo {
+    fn as_ref(&self) -> &&'a i32 {
+    $0
+}
+}
+    "#,
+    );
+}
diff --git a/src/tools/rust-analyzer/crates/ide-completion/src/tests/type_pos.rs b/src/tools/rust-analyzer/crates/ide-completion/src/tests/type_pos.rs
index 125e11e..c7e2d05 100644
--- a/src/tools/rust-analyzer/crates/ide-completion/src/tests/type_pos.rs
+++ b/src/tools/rust-analyzer/crates/ide-completion/src/tests/type_pos.rs
@@ -429,18 +429,18 @@ trait Tr<T> {
 impl Tr<$0
     "#,
         expect![[r#"
-            en Enum                        Enum
-            ma makro!(…)     macro_rules! makro
+            en Enum                    Enum
+            ma makro!(…) macro_rules! makro
             md module
-            sp Self dyn Tr<{unknown}> + 'static
-            st Record                    Record
-            st S                              S
-            st Tuple                      Tuple
-            st Unit                        Unit
+            sp Self       dyn Tr<{unknown}>
+            st Record                Record
+            st S                          S
+            st Tuple                  Tuple
+            st Unit                    Unit
             tt Tr
             tt Trait
-            un Union                      Union
-            bt u32                          u32
+            un Union                  Union
+            bt u32                      u32
             kw crate::
             kw self::
         "#]],
diff --git a/src/tools/rust-analyzer/crates/ide-db/Cargo.toml b/src/tools/rust-analyzer/crates/ide-db/Cargo.toml
index acde1d6..e065adb 100644
--- a/src/tools/rust-analyzer/crates/ide-db/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/ide-db/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/ide-db/src/path_transform.rs b/src/tools/rust-analyzer/crates/ide-db/src/path_transform.rs
index 232648a..0ab880b 100644
--- a/src/tools/rust-analyzer/crates/ide-db/src/path_transform.rs
+++ b/src/tools/rust-analyzer/crates/ide-db/src/path_transform.rs
@@ -2,7 +2,10 @@
 
 use crate::helpers::mod_path_to_ast;
 use either::Either;
-use hir::{AsAssocItem, HirDisplay, ImportPathConfig, ModuleDef, SemanticsScope};
+use hir::{
+    AsAssocItem, HirDisplay, HirFileId, ImportPathConfig, ModuleDef, SemanticsScope,
+    prettify_macro_expansion,
+};
 use itertools::Itertools;
 use rustc_hash::FxHashMap;
 use span::Edition;
@@ -136,6 +139,25 @@ pub fn apply_all<'b>(&self, nodes: impl IntoIterator<Item = &'b SyntaxNode>) {
         }
     }
 
+    fn prettify_target_node(&self, node: SyntaxNode) -> SyntaxNode {
+        match self.target_scope.file_id() {
+            HirFileId::FileId(_) => node,
+            HirFileId::MacroFile(file_id) => {
+                let db = self.target_scope.db;
+                prettify_macro_expansion(
+                    db,
+                    node,
+                    &db.expansion_span_map(file_id),
+                    self.target_scope.module().krate().into(),
+                )
+            }
+        }
+    }
+
+    fn prettify_target_ast<N: AstNode>(&self, node: N) -> N {
+        N::cast(self.prettify_target_node(node.syntax().clone())).unwrap()
+    }
+
     fn build_ctx(&self) -> Ctx<'a> {
         let db = self.source_scope.db;
         let target_module = self.target_scope.module();
@@ -163,7 +185,7 @@ fn build_ctx(&self) -> Ctx<'a> {
             .for_each(|(k, v)| match (k.split(db), v) {
                 (Either::Right(k), Some(TypeOrConst::Either(v))) => {
                     if let Some(ty) = v.ty() {
-                        type_substs.insert(k, ty);
+                        type_substs.insert(k, self.prettify_target_ast(ty));
                     }
                 }
                 (Either::Right(k), None) => {
@@ -178,7 +200,7 @@ fn build_ctx(&self) -> Ctx<'a> {
                 }
                 (Either::Left(k), Some(TypeOrConst::Either(v))) => {
                     if let Some(ty) = v.ty() {
-                        const_substs.insert(k, ty.syntax().clone());
+                        const_substs.insert(k, self.prettify_target_node(ty.syntax().clone()));
                     }
                 }
                 (Either::Left(k), Some(TypeOrConst::Const(v))) => {
@@ -189,7 +211,7 @@ fn build_ctx(&self) -> Ctx<'a> {
                         // and sometimes require slight modifications; see
                         // https://doc.rust-lang.org/reference/statements.html#expression-statements
                         // (default values in curly brackets can cause the same problem)
-                        const_substs.insert(k, expr.syntax().clone());
+                        const_substs.insert(k, self.prettify_target_node(expr.syntax().clone()));
                     }
                 }
                 (Either::Left(k), None) => {
@@ -204,6 +226,7 @@ fn build_ctx(&self) -> Ctx<'a> {
                 }
                 _ => (), // ignore mismatching params
             });
+        // No need to prettify lifetimes, there's nothing to prettify.
         let lifetime_substs: FxHashMap<_, _> = self
             .generic_def
             .into_iter()
diff --git a/src/tools/rust-analyzer/crates/ide-diagnostics/Cargo.toml b/src/tools/rust-analyzer/crates/ide-diagnostics/Cargo.toml
index 96be51e..6f1e669 100644
--- a/src/tools/rust-analyzer/crates/ide-diagnostics/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/ide-diagnostics/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/type_mismatch.rs b/src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/type_mismatch.rs
index e2957fc..ac54ac0 100644
--- a/src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/type_mismatch.rs
+++ b/src/tools/rust-analyzer/crates/ide-diagnostics/src/handlers/type_mismatch.rs
@@ -1171,7 +1171,7 @@ trait B {}
 
 fn test(a: &dyn A) -> &dyn B {
     a
-  //^ error: expected &(dyn B + 'static), found &(dyn A + 'static)
+  //^ error: expected &dyn B, found &dyn A
 }
 "#,
         );
diff --git a/src/tools/rust-analyzer/crates/ide-ssr/Cargo.toml b/src/tools/rust-analyzer/crates/ide-ssr/Cargo.toml
index 1212fa9..0620bd2 100644
--- a/src/tools/rust-analyzer/crates/ide-ssr/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/ide-ssr/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/ide/Cargo.toml b/src/tools/rust-analyzer/crates/ide/Cargo.toml
index 2f8ed88..06d2776 100644
--- a/src/tools/rust-analyzer/crates/ide/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/ide/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/ide/src/folding_ranges.rs b/src/tools/rust-analyzer/crates/ide/src/folding_ranges.rs
index 194e8c9..9bd8504 100755
--- a/src/tools/rust-analyzer/crates/ide/src/folding_ranges.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/folding_ranges.rs
@@ -2,7 +2,7 @@
 use syntax::{
     Direction, NodeOrToken, SourceFile,
     SyntaxKind::{self, *},
-    TextRange, TextSize,
+    SyntaxNode, TextRange, TextSize,
     ast::{self, AstNode, AstToken},
     match_ast,
 };
@@ -16,16 +16,21 @@
 pub enum FoldKind {
     Comment,
     Imports,
-    Mods,
+    Region,
     Block,
     ArgList,
-    Region,
-    Consts,
-    Statics,
     Array,
     WhereClause,
     ReturnType,
     MatchArm,
+    // region: item runs
+    Modules,
+    Consts,
+    Statics,
+    TypeAliases,
+    TraitAliases,
+    ExternCrates,
+    // endregion: item runs
 }
 
 #[derive(Debug)]
@@ -41,10 +46,7 @@ pub struct Fold {
 pub(crate) fn folding_ranges(file: &SourceFile) -> Vec<Fold> {
     let mut res = vec![];
     let mut visited_comments = FxHashSet::default();
-    let mut visited_imports = FxHashSet::default();
-    let mut visited_mods = FxHashSet::default();
-    let mut visited_consts = FxHashSet::default();
-    let mut visited_statics = FxHashSet::default();
+    let mut visited_nodes = FxHashSet::default();
 
     // regions can be nested, here is a LIFO buffer
     let mut region_starts: Vec<TextSize> = vec![];
@@ -93,30 +95,40 @@ pub(crate) fn folding_ranges(file: &SourceFile) -> Vec<Fold> {
                             if module.item_list().is_none() {
                                 if let Some(range) = contiguous_range_for_item_group(
                                     module,
-                                    &mut visited_mods,
+                                    &mut visited_nodes,
                                 ) {
-                                    res.push(Fold { range, kind: FoldKind::Mods })
+                                    res.push(Fold { range, kind: FoldKind::Modules })
                                 }
                             }
                         },
                         ast::Use(use_) => {
-                            if let Some(range) = contiguous_range_for_item_group(use_, &mut visited_imports) {
+                            if let Some(range) = contiguous_range_for_item_group(use_, &mut visited_nodes) {
                                 res.push(Fold { range, kind: FoldKind::Imports })
                             }
                         },
                         ast::Const(konst) => {
-                            if let Some(range) = contiguous_range_for_item_group(konst, &mut visited_consts) {
+                            if let Some(range) = contiguous_range_for_item_group(konst, &mut visited_nodes) {
                                 res.push(Fold { range, kind: FoldKind::Consts })
                             }
                         },
                         ast::Static(statik) => {
-                            if let Some(range) = contiguous_range_for_item_group(statik, &mut visited_statics) {
+                            if let Some(range) = contiguous_range_for_item_group(statik, &mut visited_nodes) {
                                 res.push(Fold { range, kind: FoldKind::Statics })
                             }
                         },
-                        ast::WhereClause(where_clause) => {
-                            if let Some(range) = fold_range_for_where_clause(where_clause) {
-                                res.push(Fold { range, kind: FoldKind::WhereClause })
+                        ast::TypeAlias(alias) => {
+                            if let Some(range) = contiguous_range_for_item_group(alias, &mut visited_nodes) {
+                                res.push(Fold { range, kind: FoldKind::TypeAliases })
+                            }
+                        },
+                        ast::TraitAlias(alias) => {
+                            if let Some(range) = contiguous_range_for_item_group(alias, &mut visited_nodes) {
+                                res.push(Fold { range, kind: FoldKind::TraitAliases })
+                            }
+                        },
+                        ast::ExternCrate(extern_crate) => {
+                            if let Some(range) = contiguous_range_for_item_group(extern_crate, &mut visited_nodes) {
+                                res.push(Fold { range, kind: FoldKind::ExternCrates })
                             }
                         },
                         ast::MatchArm(match_arm) => {
@@ -137,9 +149,10 @@ pub(crate) fn folding_ranges(file: &SourceFile) -> Vec<Fold> {
 fn fold_kind(kind: SyntaxKind) -> Option<FoldKind> {
     match kind {
         COMMENT => Some(FoldKind::Comment),
-        ARG_LIST | PARAM_LIST => Some(FoldKind::ArgList),
+        ARG_LIST | PARAM_LIST | GENERIC_ARG_LIST | GENERIC_PARAM_LIST => Some(FoldKind::ArgList),
         ARRAY_EXPR => Some(FoldKind::Array),
         RET_TYPE => Some(FoldKind::ReturnType),
+        WHERE_CLAUSE => Some(FoldKind::WhereClause),
         ASSOC_ITEM_LIST
         | RECORD_FIELD_LIST
         | RECORD_PAT_FIELD_LIST
@@ -155,11 +168,14 @@ fn fold_kind(kind: SyntaxKind) -> Option<FoldKind> {
     }
 }
 
-fn contiguous_range_for_item_group<N>(first: N, visited: &mut FxHashSet<N>) -> Option<TextRange>
+fn contiguous_range_for_item_group<N>(
+    first: N,
+    visited: &mut FxHashSet<SyntaxNode>,
+) -> Option<TextRange>
 where
     N: ast::HasVisibility + Clone + Hash + Eq,
 {
-    if !visited.insert(first.clone()) {
+    if !visited.insert(first.syntax().clone()) {
         return None;
     }
 
@@ -183,7 +199,7 @@ fn contiguous_range_for_item_group<N>(first: N, visited: &mut FxHashSet<N>) -> O
         if let Some(next) = N::cast(node) {
             let next_vis = next.visibility();
             if eq_visibility(next_vis.clone(), last_vis) {
-                visited.insert(next.clone());
+                visited.insert(next.syntax().clone());
                 last_vis = next_vis;
                 last = next;
                 continue;
@@ -259,18 +275,6 @@ fn contiguous_range_for_comment(
     }
 }
 
-fn fold_range_for_where_clause(where_clause: ast::WhereClause) -> Option<TextRange> {
-    let first_where_pred = where_clause.predicates().next();
-    let last_where_pred = where_clause.predicates().last();
-
-    if first_where_pred != last_where_pred {
-        let start = where_clause.where_token()?.text_range().end();
-        let end = where_clause.syntax().text_range().end();
-        return Some(TextRange::new(start, end));
-    }
-    None
-}
-
 fn fold_range_for_multiline_match_arm(match_arm: ast::MatchArm) -> Option<TextRange> {
     if fold_kind(match_arm.expr()?.syntax().kind()).is_some() {
         None
@@ -307,16 +311,19 @@ fn check(#[rust_analyzer::rust_fixture] ra_fixture: &str) {
             let kind = match fold.kind {
                 FoldKind::Comment => "comment",
                 FoldKind::Imports => "imports",
-                FoldKind::Mods => "mods",
+                FoldKind::Modules => "mods",
                 FoldKind::Block => "block",
                 FoldKind::ArgList => "arglist",
                 FoldKind::Region => "region",
                 FoldKind::Consts => "consts",
                 FoldKind::Statics => "statics",
+                FoldKind::TypeAliases => "typealiases",
                 FoldKind::Array => "array",
                 FoldKind::WhereClause => "whereclause",
                 FoldKind::ReturnType => "returntype",
                 FoldKind::MatchArm => "matcharm",
+                FoldKind::TraitAliases => "traitaliases",
+                FoldKind::ExternCrates => "externcrates",
             };
             assert_eq!(kind, &attr.unwrap());
         }
@@ -594,19 +601,18 @@ fn fold_consecutive_static() {
 
     #[test]
     fn fold_where_clause() {
-        // fold multi-line and don't fold single line.
         check(
             r#"
 fn foo()
-where<fold whereclause>
+<fold whereclause>where
     A: Foo,
     B: Foo,
     C: Foo,
     D: Foo,</fold> {}
 
 fn bar()
-where
-    A: Bar, {}
+<fold whereclause>where
+    A: Bar,</fold> {}
 "#,
         )
     }
@@ -624,4 +630,16 @@ fn bar() -> (bool, bool) { (true, true) }
 "#,
         )
     }
+
+    #[test]
+    fn fold_generics() {
+        check(
+            r#"
+type Foo<T, U> = foo<fold arglist><
+    T,
+    U,
+></fold>;
+"#,
+        )
+    }
 }
diff --git a/src/tools/rust-analyzer/crates/ide/src/goto_definition.rs b/src/tools/rust-analyzer/crates/ide/src/goto_definition.rs
index 574803f..fd465f3 100644
--- a/src/tools/rust-analyzer/crates/ide/src/goto_definition.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/goto_definition.rs
@@ -291,13 +291,14 @@ fn handle_control_flow_keywords(
     token: &SyntaxToken,
 ) -> Option<Vec<NavigationTarget>> {
     match token.kind() {
-        // For `fn` / `loop` / `while` / `for` / `async`, return the keyword it self,
+        // For `fn` / `loop` / `while` / `for` / `async` / `match`, return the keyword it self,
         // so that VSCode will find the references when using `ctrl + click`
         T![fn] | T![async] | T![try] | T![return] => nav_for_exit_points(sema, token),
         T![loop] | T![while] | T![break] | T![continue] => nav_for_break_points(sema, token),
         T![for] if token.parent().and_then(ast::ForExpr::cast).is_some() => {
             nav_for_break_points(sema, token)
         }
+        T![match] | T![=>] | T![if] => nav_for_branch_exit_points(sema, token),
         _ => None,
     }
 }
@@ -407,6 +408,91 @@ fn nav_for_exit_points(
     Some(navs)
 }
 
+pub(crate) fn find_branch_root(
+    sema: &Semantics<'_, RootDatabase>,
+    token: &SyntaxToken,
+) -> Vec<SyntaxNode> {
+    let find_nodes = |node_filter: fn(SyntaxNode) -> Option<SyntaxNode>| {
+        sema.descend_into_macros(token.clone())
+            .into_iter()
+            .filter_map(|token| node_filter(token.parent()?))
+            .collect_vec()
+    };
+
+    match token.kind() {
+        T![match] => find_nodes(|node| Some(ast::MatchExpr::cast(node)?.syntax().clone())),
+        T![=>] => find_nodes(|node| Some(ast::MatchArm::cast(node)?.syntax().clone())),
+        T![if] => find_nodes(|node| {
+            let if_expr = ast::IfExpr::cast(node)?;
+
+            let root_if = iter::successors(Some(if_expr.clone()), |if_expr| {
+                let parent_if = if_expr.syntax().parent().and_then(ast::IfExpr::cast)?;
+                let ast::ElseBranch::IfExpr(else_branch) = parent_if.else_branch()? else {
+                    return None;
+                };
+
+                (else_branch.syntax() == if_expr.syntax()).then_some(parent_if)
+            })
+            .last()?;
+
+            Some(root_if.syntax().clone())
+        }),
+        _ => vec![],
+    }
+}
+
+fn nav_for_branch_exit_points(
+    sema: &Semantics<'_, RootDatabase>,
+    token: &SyntaxToken,
+) -> Option<Vec<NavigationTarget>> {
+    let db = sema.db;
+
+    let navs = match token.kind() {
+        T![match] => find_branch_root(sema, token)
+            .into_iter()
+            .filter_map(|node| {
+                let file_id = sema.hir_file_for(&node);
+                let match_expr = ast::MatchExpr::cast(node)?;
+                let focus_range = match_expr.match_token()?.text_range();
+                let match_expr_in_file = InFile::new(file_id, match_expr.into());
+                Some(expr_to_nav(db, match_expr_in_file, Some(focus_range)))
+            })
+            .flatten()
+            .collect_vec(),
+
+        T![=>] => find_branch_root(sema, token)
+            .into_iter()
+            .filter_map(|node| {
+                let match_arm = ast::MatchArm::cast(node)?;
+                let match_expr = sema
+                    .ancestors_with_macros(match_arm.syntax().clone())
+                    .find_map(ast::MatchExpr::cast)?;
+                let file_id = sema.hir_file_for(match_expr.syntax());
+                let focus_range = match_arm.fat_arrow_token()?.text_range();
+                let match_expr_in_file = InFile::new(file_id, match_expr.into());
+                Some(expr_to_nav(db, match_expr_in_file, Some(focus_range)))
+            })
+            .flatten()
+            .collect_vec(),
+
+        T![if] => find_branch_root(sema, token)
+            .into_iter()
+            .filter_map(|node| {
+                let file_id = sema.hir_file_for(&node);
+                let if_expr = ast::IfExpr::cast(node)?;
+                let focus_range = if_expr.if_token()?.text_range();
+                let if_expr_in_file = InFile::new(file_id, if_expr.into());
+                Some(expr_to_nav(db, if_expr_in_file, Some(focus_range)))
+            })
+            .flatten()
+            .collect_vec(),
+
+        _ => return Some(Vec::new()),
+    };
+
+    Some(navs)
+}
+
 pub(crate) fn find_loops(
     sema: &Semantics<'_, RootDatabase>,
     token: &SyntaxToken,
@@ -3614,4 +3700,155 @@ fn foo() {
         "#,
         );
     }
+
+    #[test]
+    fn goto_def_for_match_keyword() {
+        check(
+            r#"
+fn main() {
+    match$0 0 {
+ // ^^^^^
+        0 => {},
+        _ => {},
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_match_arm_fat_arrow() {
+        check(
+            r#"
+fn main() {
+    match 0 {
+        0 =>$0 {},
+       // ^^
+        _ => {},
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_if_keyword() {
+        check(
+            r#"
+fn main() {
+    if$0 true {
+ // ^^
+        ()
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_match_nested_in_if() {
+        check(
+            r#"
+fn main() {
+    if true {
+        match$0 0 {
+     // ^^^^^
+            0 => {},
+            _ => {},
+        }
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_multiple_match_expressions() {
+        check(
+            r#"
+fn main() {
+    match 0 {
+        0 => {},
+        _ => {},
+    };
+
+    match$0 1 {
+ // ^^^^^
+        1 => {},
+        _ => {},
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_nested_match_expressions() {
+        check(
+            r#"
+fn main() {
+    match 0 {
+        0 => match$0 1 {
+          // ^^^^^
+            1 => {},
+            _ => {},
+        },
+        _ => {},
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_if_else_chains() {
+        check(
+            r#"
+fn main() {
+    if true {
+ // ^^
+        ()
+    } else if$0 false {
+        ()
+    } else {
+        ()
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_match_with_guards() {
+        check(
+            r#"
+fn main() {
+    match 42 {
+        x if x > 0 =>$0 {},
+                // ^^
+        _ => {},
+    }
+}
+"#,
+        );
+    }
+
+    #[test]
+    fn goto_def_for_match_with_macro_arm() {
+        check(
+            r#"
+macro_rules! arm {
+    () => { 0 => {} };
+}
+
+fn main() {
+    match$0 0 {
+ // ^^^^^
+        arm!(),
+        _ => {},
+    }
+}
+"#,
+        );
+    }
 }
diff --git a/src/tools/rust-analyzer/crates/ide/src/goto_type_definition.rs b/src/tools/rust-analyzer/crates/ide/src/goto_type_definition.rs
index 86d72fe..b80e81d 100644
--- a/src/tools/rust-analyzer/crates/ide/src/goto_type_definition.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/goto_type_definition.rs
@@ -70,11 +70,10 @@ pub(crate) fn goto_type_definition(
     }
 
     let range = token.text_range();
-    sema.descend_into_macros_no_opaque(token,false)
+    sema.descend_into_macros_no_opaque(token, false)
         .into_iter()
         .filter_map(|token| {
-            sema
-                .token_ancestors_with_macros(token.value)
+            sema.token_ancestors_with_macros(token.value)
                 // When `token` is within a macro call, we can't determine its type. Don't continue
                 // this traversal because otherwise we'll end up returning the type of *that* macro
                 // call, which is not what we want in general.
@@ -103,7 +102,6 @@ pub(crate) fn goto_type_definition(
                             _ => return None,
                         }
                     };
-
                     Some(ty)
                 })
         })
diff --git a/src/tools/rust-analyzer/crates/ide/src/highlight_related.rs b/src/tools/rust-analyzer/crates/ide/src/highlight_related.rs
index aa94792..356bd69 100644
--- a/src/tools/rust-analyzer/crates/ide/src/highlight_related.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/highlight_related.rs
@@ -37,8 +37,11 @@ pub struct HighlightRelatedConfig {
     pub break_points: bool,
     pub closure_captures: bool,
     pub yield_points: bool,
+    pub branch_exit_points: bool,
 }
 
+type HighlightMap = FxHashMap<EditionedFileId, FxHashSet<HighlightedRange>>;
+
 // Feature: Highlight Related
 //
 // Highlights constructs related to the thing under the cursor:
@@ -64,7 +67,7 @@ pub(crate) fn highlight_related(
 
     let token = pick_best_token(syntax.token_at_offset(offset), |kind| match kind {
         T![?] => 4, // prefer `?` when the cursor is sandwiched like in `await$0?`
-        T![->] => 4,
+        T![->] | T![=>] => 4,
         kind if kind.is_keyword(file_id.edition(sema.db)) => 3,
         IDENT | INT_NUMBER => 2,
         T![|] => 1,
@@ -78,6 +81,9 @@ pub(crate) fn highlight_related(
         T![fn] | T![return] | T![->] if config.exit_points => {
             highlight_exit_points(sema, token).remove(&file_id)
         }
+        T![match] | T![=>] | T![if] if config.branch_exit_points => {
+            highlight_branch_exit_points(sema, token).remove(&file_id)
+        }
         T![await] | T![async] if config.yield_points => {
             highlight_yield_points(sema, token).remove(&file_id)
         }
@@ -300,11 +306,93 @@ fn highlight_references(
     if res.is_empty() { None } else { Some(res.into_iter().collect()) }
 }
 
+pub(crate) fn highlight_branch_exit_points(
+    sema: &Semantics<'_, RootDatabase>,
+    token: SyntaxToken,
+) -> FxHashMap<EditionedFileId, Vec<HighlightedRange>> {
+    let mut highlights: HighlightMap = FxHashMap::default();
+
+    let push_to_highlights = |file_id, range, highlights: &mut HighlightMap| {
+        if let Some(FileRange { file_id, range }) = original_frange(sema.db, file_id, range) {
+            let hrange = HighlightedRange { category: ReferenceCategory::empty(), range };
+            highlights.entry(file_id).or_default().insert(hrange);
+        }
+    };
+
+    let push_tail_expr = |tail: Option<ast::Expr>, highlights: &mut HighlightMap| {
+        let Some(tail) = tail else {
+            return;
+        };
+
+        for_each_tail_expr(&tail, &mut |tail| {
+            let file_id = sema.hir_file_for(tail.syntax());
+            let range = tail.syntax().text_range();
+            push_to_highlights(file_id, Some(range), highlights);
+        });
+    };
+
+    let nodes = goto_definition::find_branch_root(sema, &token).into_iter();
+    match token.kind() {
+        T![match] => {
+            for match_expr in nodes.filter_map(ast::MatchExpr::cast) {
+                let file_id = sema.hir_file_for(match_expr.syntax());
+                let range = match_expr.match_token().map(|token| token.text_range());
+                push_to_highlights(file_id, range, &mut highlights);
+
+                let Some(arm_list) = match_expr.match_arm_list() else {
+                    continue;
+                };
+                for arm in arm_list.arms() {
+                    push_tail_expr(arm.expr(), &mut highlights);
+                }
+            }
+        }
+        T![=>] => {
+            for arm in nodes.filter_map(ast::MatchArm::cast) {
+                let file_id = sema.hir_file_for(arm.syntax());
+                let range = arm.fat_arrow_token().map(|token| token.text_range());
+                push_to_highlights(file_id, range, &mut highlights);
+
+                push_tail_expr(arm.expr(), &mut highlights);
+            }
+        }
+        T![if] => {
+            for mut if_to_process in nodes.map(ast::IfExpr::cast) {
+                while let Some(cur_if) = if_to_process.take() {
+                    let file_id = sema.hir_file_for(cur_if.syntax());
+
+                    let if_kw_range = cur_if.if_token().map(|token| token.text_range());
+                    push_to_highlights(file_id, if_kw_range, &mut highlights);
+
+                    if let Some(then_block) = cur_if.then_branch() {
+                        push_tail_expr(Some(then_block.into()), &mut highlights);
+                    }
+
+                    match cur_if.else_branch() {
+                        Some(ast::ElseBranch::Block(else_block)) => {
+                            push_tail_expr(Some(else_block.into()), &mut highlights);
+                            if_to_process = None;
+                        }
+                        Some(ast::ElseBranch::IfExpr(nested_if)) => if_to_process = Some(nested_if),
+                        None => if_to_process = None,
+                    }
+                }
+            }
+        }
+        _ => {}
+    }
+
+    highlights
+        .into_iter()
+        .map(|(file_id, ranges)| (file_id, ranges.into_iter().collect()))
+        .collect()
+}
+
 fn hl_exit_points(
     sema: &Semantics<'_, RootDatabase>,
     def_token: Option<SyntaxToken>,
     body: ast::Expr,
-) -> Option<FxHashMap<EditionedFileId, FxHashSet<HighlightedRange>>> {
+) -> Option<HighlightMap> {
     let mut highlights: FxHashMap<EditionedFileId, FxHashSet<_>> = FxHashMap::default();
 
     let mut push_to_highlights = |file_id, range| {
@@ -411,7 +499,7 @@ pub(crate) fn hl(
         loop_token: Option<SyntaxToken>,
         label: Option<ast::Label>,
         expr: ast::Expr,
-    ) -> Option<FxHashMap<EditionedFileId, FxHashSet<HighlightedRange>>> {
+    ) -> Option<HighlightMap> {
         let mut highlights: FxHashMap<EditionedFileId, FxHashSet<_>> = FxHashMap::default();
 
         let mut push_to_highlights = |file_id, range| {
@@ -504,7 +592,7 @@ fn hl(
         sema: &Semantics<'_, RootDatabase>,
         async_token: Option<SyntaxToken>,
         body: Option<ast::Expr>,
-    ) -> Option<FxHashMap<EditionedFileId, FxHashSet<HighlightedRange>>> {
+    ) -> Option<HighlightMap> {
         let mut highlights: FxHashMap<EditionedFileId, FxHashSet<_>> = FxHashMap::default();
 
         let mut push_to_highlights = |file_id, range| {
@@ -597,10 +685,7 @@ fn original_frange(
     InFile::new(file_id, text_range?).original_node_file_range_opt(db).map(|(frange, _)| frange)
 }
 
-fn merge_map(
-    res: &mut FxHashMap<EditionedFileId, FxHashSet<HighlightedRange>>,
-    new: Option<FxHashMap<EditionedFileId, FxHashSet<HighlightedRange>>>,
-) {
+fn merge_map(res: &mut HighlightMap, new: Option<HighlightMap>) {
     let Some(new) = new else {
         return;
     };
@@ -750,6 +835,7 @@ mod tests {
         references: true,
         closure_captures: true,
         yield_points: true,
+        branch_exit_points: true,
     };
 
     #[track_caller]
@@ -2135,6 +2221,62 @@ fn f() {
     }
 
     #[test]
+    fn nested_match() {
+        check(
+            r#"
+fn main() {
+    match$0 0 {
+ // ^^^^^
+        0 => match 1 {
+            1 => 2,
+              // ^
+            _ => 3,
+              // ^
+        },
+        _ => 4,
+          // ^
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn single_arm_highlight() {
+        check(
+            r#"
+fn main() {
+    match 0 {
+        0 =>$0 {
+       // ^^
+            let x = 1;
+            x
+         // ^
+        }
+        _ => 2,
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn no_branches_when_disabled() {
+        let config = HighlightRelatedConfig { branch_exit_points: false, ..ENABLED_CONFIG };
+        check_with_config(
+            r#"
+fn main() {
+    match$0 0 {
+        0 => 1,
+        _ => 2,
+    }
+}
+"#,
+            config,
+        );
+    }
+
+    #[test]
     fn asm() {
         check(
             r#"
@@ -2165,6 +2307,200 @@ pub unsafe fn bootstrap() -> ! {
     }
 
     #[test]
+    fn complex_arms_highlight() {
+        check(
+            r#"
+fn calculate(n: i32) -> i32 { n * 2 }
+
+fn main() {
+    match$0 Some(1) {
+ // ^^^^^
+        Some(x) => match x {
+            0 => { let y = x; y },
+                           // ^
+            1 => calculate(x),
+               //^^^^^^^^^^^^
+            _ => (|| 6)(),
+              // ^^^^^^^^
+        },
+        None => loop {
+            break 5;
+         // ^^^^^^^
+        },
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn match_in_macro_highlight() {
+        check(
+            r#"
+macro_rules! M {
+    ($e:expr) => { $e };
+}
+
+fn main() {
+    M!{
+        match$0 Some(1) {
+     // ^^^^^
+            Some(x) => x,
+                    // ^
+            None => 0,
+                 // ^
+        }
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn match_in_macro_highlight_2() {
+        check(
+            r#"
+macro_rules! match_ast {
+    (match $node:ident { $($tt:tt)* }) => { $crate::match_ast!(match ($node) { $($tt)* }) };
+
+    (match ($node:expr) {
+        $( $( $path:ident )::+ ($it:pat) => $res:expr, )*
+        _ => $catch_all:expr $(,)?
+    }) => {{
+        $( if let Some($it) = $($path::)+cast($node.clone()) { $res } else )*
+        { $catch_all }
+    }};
+}
+
+fn main() {
+    match_ast! {
+        match$0 Some(1) {
+            Some(x) => x,
+        }
+    }
+}
+            "#,
+        );
+    }
+
+    #[test]
+    fn nested_if_else() {
+        check(
+            r#"
+fn main() {
+    if$0 true {
+ // ^^
+        if false {
+            1
+         // ^
+        } else {
+            2
+         // ^
+        }
+    } else {
+        3
+     // ^
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn if_else_if_highlight() {
+        check(
+            r#"
+fn main() {
+    if$0 true {
+ // ^^
+        1
+     // ^
+    } else if false {
+        // ^^
+        2
+     // ^
+    } else {
+        3
+     // ^
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn complex_if_branches() {
+        check(
+            r#"
+fn calculate(n: i32) -> i32 { n * 2 }
+
+fn main() {
+    if$0 true {
+ // ^^
+        let x = 5;
+        calculate(x)
+     // ^^^^^^^^^^^^
+    } else if false {
+        // ^^
+        (|| 10)()
+     // ^^^^^^^^^
+    } else {
+        loop {
+            break 15;
+         // ^^^^^^^^
+        }
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn if_in_macro_highlight() {
+        check(
+            r#"
+macro_rules! M {
+    ($e:expr) => { $e };
+}
+
+fn main() {
+    M!{
+        if$0 true {
+     // ^^
+            5
+         // ^
+        } else {
+            10
+         // ^^
+        }
+    }
+}
+"#,
+        )
+    }
+
+    #[test]
+    fn match_in_macro() {
+        // We should not highlight the outer `match` expression.
+        check(
+            r#"
+macro_rules! M {
+    (match) => { 1 };
+}
+
+fn main() {
+    match Some(1) {
+        Some(x) => x,
+        None => {
+            M!(match$0)
+        }
+    }
+}
+            "#,
+        )
+    }
+
+    #[test]
     fn labeled_block_tail_expr() {
         check(
             r#"
diff --git a/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bind_pat.rs b/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bind_pat.rs
index 36fdd90..7293493 100644
--- a/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bind_pat.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bind_pat.rs
@@ -380,9 +380,9 @@ fn main() {
     let foo = foo3();
      // ^^^ impl Fn(f64, f64) -> u32
     let foo = foo4();
-     // ^^^ &'static (dyn Fn(f64, f64) -> u32 + 'static)
+     // ^^^ &'static dyn Fn(f64, f64) -> u32
     let foo = foo5();
-     // ^^^ &'static (dyn Fn(&(dyn Fn(f64, f64) -> u32 + 'static), f64) -> u32 + 'static)
+     // ^^^ &'static dyn Fn(&dyn Fn(f64, f64) -> u32, f64) -> u32
     let foo = foo6();
      // ^^^ impl Fn(f64, f64) -> u32
     let foo = foo7();
@@ -413,7 +413,7 @@ fn main() {
     let foo = foo3();
      // ^^^ impl Fn(f64, f64) -> u32
     let foo = foo4();
-     // ^^^ &'static (dyn Fn(f64, f64) -> u32 + 'static)
+     // ^^^ &'static dyn Fn(f64, f64) -> u32
     let foo = foo5();
     let foo = foo6();
     let foo = foo7();
diff --git a/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bounds.rs b/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bounds.rs
index b9a98f8..f0003da 100644
--- a/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bounds.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/inlay_hints/bounds.rs
@@ -143,7 +143,7 @@ fn foo<T>() {}
                                             file_id: FileId(
                                                 1,
                                             ),
-                                            range: 135..140,
+                                            range: 446..451,
                                         },
                                     ),
                                 ),
diff --git a/src/tools/rust-analyzer/crates/ide/src/inlay_hints/closing_brace.rs b/src/tools/rust-analyzer/crates/ide/src/inlay_hints/closing_brace.rs
index ca3a982..d2216e6 100644
--- a/src/tools/rust-analyzer/crates/ide/src/inlay_hints/closing_brace.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/inlay_hints/closing_brace.rs
@@ -193,7 +193,7 @@ impl Tr for () {
 //^ impl Tr for ()
 impl dyn Tr {
   }
-//^ impl dyn Tr + 'static
+//^ impl dyn Tr
 
 static S0: () = 0;
 static S1: () = {};
diff --git a/src/tools/rust-analyzer/crates/ide/src/references.rs b/src/tools/rust-analyzer/crates/ide/src/references.rs
index c6a323d..fe874bc 100644
--- a/src/tools/rust-analyzer/crates/ide/src/references.rs
+++ b/src/tools/rust-analyzer/crates/ide/src/references.rs
@@ -21,6 +21,7 @@
 use ide_db::{
     FileId, RootDatabase,
     defs::{Definition, NameClass, NameRefClass},
+    helpers::pick_best_token,
     search::{ReferenceCategory, SearchScope, UsageSearchResult},
 };
 use itertools::Itertools;
@@ -397,7 +398,11 @@ fn handle_control_flow_keywords(
         .attach_first_edition(file_id)
         .map(|it| it.edition(sema.db))
         .unwrap_or(Edition::CURRENT);
-    let token = file.syntax().token_at_offset(offset).find(|t| t.kind().is_keyword(edition))?;
+    let token = pick_best_token(file.syntax().token_at_offset(offset), |kind| match kind {
+        _ if kind.is_keyword(edition) => 4,
+        T![=>] => 3,
+        _ => 1,
+    })?;
 
     let references = match token.kind() {
         T![fn] | T![return] | T![try] => highlight_related::highlight_exit_points(sema, token),
@@ -408,6 +413,7 @@ fn handle_control_flow_keywords(
         T![for] if token.parent().and_then(ast::ForExpr::cast).is_some() => {
             highlight_related::highlight_break_points(sema, token)
         }
+        T![if] | T![=>] | T![match] => highlight_related::highlight_branch_exit_points(sema, token),
         _ => return None,
     }
     .into_iter()
@@ -1344,6 +1350,159 @@ fn foo(self$0) {
         );
     }
 
+    #[test]
+    fn test_highlight_if_branches() {
+        check(
+            r#"
+fn main() {
+    let x = if$0 true {
+        1
+    } else if false {
+        2
+    } else {
+        3
+    };
+
+    println!("x: {}", x);
+}
+"#,
+            expect![[r#"
+                FileId(0) 24..26
+                FileId(0) 42..43
+                FileId(0) 55..57
+                FileId(0) 74..75
+                FileId(0) 97..98
+            "#]],
+        );
+    }
+
+    #[test]
+    fn test_highlight_match_branches() {
+        check(
+            r#"
+fn main() {
+    $0match Some(42) {
+        Some(x) if x > 0 => println!("positive"),
+        Some(0) => println!("zero"),
+        Some(_) => println!("negative"),
+        None => println!("none"),
+    };
+}
+"#,
+            expect![[r#"
+                FileId(0) 16..21
+                FileId(0) 61..81
+                FileId(0) 102..118
+                FileId(0) 139..159
+                FileId(0) 177..193
+            "#]],
+        );
+    }
+
+    #[test]
+    fn test_highlight_match_arm_arrow() {
+        check(
+            r#"
+fn main() {
+    match Some(42) {
+        Some(x) if x > 0 $0=> println!("positive"),
+        Some(0) => println!("zero"),
+        Some(_) => println!("negative"),
+        None => println!("none"),
+    }
+}
+"#,
+            expect![[r#"
+                FileId(0) 58..60
+                FileId(0) 61..81
+            "#]],
+        );
+    }
+
+    #[test]
+    fn test_highlight_nested_branches() {
+        check(
+            r#"
+fn main() {
+    let x = $0if true {
+        if false {
+            1
+        } else {
+            match Some(42) {
+                Some(_) => 2,
+                None => 3,
+            }
+        }
+    } else {
+        4
+    };
+
+    println!("x: {}", x);
+}
+"#,
+            expect![[r#"
+                FileId(0) 24..26
+                FileId(0) 65..66
+                FileId(0) 140..141
+                FileId(0) 167..168
+                FileId(0) 215..216
+            "#]],
+        );
+    }
+
+    #[test]
+    fn test_highlight_match_with_complex_guards() {
+        check(
+            r#"
+fn main() {
+    let x = $0match (x, y) {
+        (a, b) if a > b && a % 2 == 0 => 1,
+        (a, b) if a < b || b % 2 == 1 => 2,
+        (a, _) if a > 40 => 3,
+        _ => 4,
+    };
+
+    println!("x: {}", x);
+}
+"#,
+            expect![[r#"
+                FileId(0) 24..29
+                FileId(0) 80..81
+                FileId(0) 124..125
+                FileId(0) 155..156
+                FileId(0) 171..172
+            "#]],
+        );
+    }
+
+    #[test]
+    fn test_highlight_mixed_if_match_expressions() {
+        check(
+            r#"
+fn main() {
+    let x = $0if let Some(x) = Some(42) {
+        1
+    } else if let None = None {
+        2
+    } else {
+        match 42 {
+            0 => 3,
+            _ => 4,
+        }
+    };
+}
+"#,
+            expect![[r#"
+                FileId(0) 24..26
+                FileId(0) 60..61
+                FileId(0) 73..75
+                FileId(0) 102..103
+                FileId(0) 153..154
+                FileId(0) 173..174
+            "#]],
+        );
+    }
+
     fn check(#[rust_analyzer::rust_fixture] ra_fixture: &str, expect: Expect) {
         check_with_scope(ra_fixture, None, expect)
     }
@@ -2867,4 +3026,66 @@ fn howdy() {
             "#]],
         );
     }
+
+    #[test]
+    fn test_highlight_if_let_match_combined() {
+        check(
+            r#"
+enum MyEnum { A(i32), B(String), C }
+
+fn main() {
+    let val = MyEnum::A(42);
+
+    let x = $0if let MyEnum::A(x) = val {
+        1
+    } else if let MyEnum::B(s) = val {
+        2
+    } else {
+        match val {
+            MyEnum::C => 3,
+            _ => 4,
+        }
+    };
+}
+"#,
+            expect![[r#"
+                FileId(0) 92..94
+                FileId(0) 128..129
+                FileId(0) 141..143
+                FileId(0) 177..178
+                FileId(0) 237..238
+                FileId(0) 257..258
+            "#]],
+        );
+    }
+
+    #[test]
+    fn test_highlight_nested_match_expressions() {
+        check(
+            r#"
+enum Outer { A(Inner), B }
+enum Inner { X, Y(i32) }
+
+fn main() {
+    let val = Outer::A(Inner::Y(42));
+
+    $0match val {
+        Outer::A(inner) => match inner {
+            Inner::X => println!("Inner::X"),
+            Inner::Y(n) if n > 0 => println!("Inner::Y positive: {}", n),
+            Inner::Y(_) => println!("Inner::Y non-positive"),
+        },
+        Outer::B => println!("Outer::B"),
+    }
+}
+"#,
+            expect![[r#"
+                FileId(0) 108..113
+                FileId(0) 185..205
+                FileId(0) 243..279
+                FileId(0) 308..341
+                FileId(0) 374..394
+            "#]],
+        );
+    }
 }
diff --git a/src/tools/rust-analyzer/crates/intern/Cargo.toml b/src/tools/rust-analyzer/crates/intern/Cargo.toml
index 9ff656c..81b6703 100644
--- a/src/tools/rust-analyzer/crates/intern/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/intern/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 
 [dependencies]
diff --git a/src/tools/rust-analyzer/crates/intern/src/symbol/symbols.rs b/src/tools/rust-analyzer/crates/intern/src/symbol/symbols.rs
index adc5813..1ccd20c 100644
--- a/src/tools/rust-analyzer/crates/intern/src/symbol/symbols.rs
+++ b/src/tools/rust-analyzer/crates/intern/src/symbol/symbols.rs
@@ -438,6 +438,8 @@ pub(super) fn prefill() -> DashMap<Symbol, (), BuildHasherDefault<FxHasher>> {
     shr,
     simd,
     sized,
+    meta_sized,
+    pointee_sized,
     skip,
     slice_len_fn,
     Some,
diff --git a/src/tools/rust-analyzer/crates/mbe/Cargo.toml b/src/tools/rust-analyzer/crates/mbe/Cargo.toml
index f3ab093..eef718b 100644
--- a/src/tools/rust-analyzer/crates/mbe/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/mbe/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cov-mark = "2.0.0"
diff --git a/src/tools/rust-analyzer/crates/parser/Cargo.toml b/src/tools/rust-analyzer/crates/parser/Cargo.toml
index c80510e..c7da654 100644
--- a/src/tools/rust-analyzer/crates/parser/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/parser/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 drop_bomb = "0.1.5"
diff --git a/src/tools/rust-analyzer/crates/parser/src/grammar/generic_params.rs b/src/tools/rust-analyzer/crates/parser/src/grammar/generic_params.rs
index ea5a3bc..55c5dc4 100644
--- a/src/tools/rust-analyzer/crates/parser/src/grammar/generic_params.rs
+++ b/src/tools/rust-analyzer/crates/parser/src/grammar/generic_params.rs
@@ -122,7 +122,7 @@ fn lifetime_bounds(p: &mut Parser<'_>) {
 }
 
 // test type_param_bounds
-// struct S<T: 'a + ?Sized + (Copy) + ~const Drop>;
+// struct S<T: 'a + ?Sized + (Copy) + [const] Drop>;
 pub(super) fn bounds(p: &mut Parser<'_>) {
     p.expect(T![:]);
     bounds_without_colon(p);
@@ -187,6 +187,11 @@ fn type_bound(p: &mut Parser<'_>) -> bool {
                     p.bump_any();
                     p.expect(T![const]);
                 }
+                T!['['] => {
+                    p.bump_any();
+                    p.expect(T![const]);
+                    p.expect(T![']']);
+                }
                 // test const_trait_bound
                 // const fn foo(_: impl const Trait) {}
                 T![const] => {
diff --git a/src/tools/rust-analyzer/crates/parser/src/lexed_str.rs b/src/tools/rust-analyzer/crates/parser/src/lexed_str.rs
index 0fa9a26..e6c92de 100644
--- a/src/tools/rust-analyzer/crates/parser/src/lexed_str.rs
+++ b/src/tools/rust-analyzer/crates/parser/src/lexed_str.rs
@@ -11,7 +11,8 @@
 use std::ops;
 
 use rustc_literal_escaper::{
-    EscapeError, Mode, unescape_byte, unescape_char, unescape_mixed, unescape_unicode,
+    EscapeError, Mode, unescape_byte, unescape_byte_str, unescape_c_str, unescape_char,
+    unescape_str,
 };
 
 use crate::{
@@ -151,14 +152,14 @@ fn finalize_with_eof(mut self) -> LexedStr<'a> {
         self.res
     }
 
-    fn push(&mut self, kind: SyntaxKind, len: usize, err: Option<&str>) {
+    fn push(&mut self, kind: SyntaxKind, len: usize, errors: Vec<String>) {
         self.res.push(kind, self.offset);
         self.offset += len;
 
-        if let Some(err) = err {
-            let token = self.res.len() as u32;
-            let msg = err.to_owned();
-            self.res.error.push(LexError { msg, token });
+        for msg in errors {
+            if !msg.is_empty() {
+                self.res.error.push(LexError { msg, token: self.res.len() as u32 });
+            }
         }
     }
 
@@ -167,14 +168,16 @@ fn extend_token(&mut self, kind: &rustc_lexer::TokenKind, mut token_text: &str)
         // We drop some useful information here (see patterns with double dots `..`)
         // Storing that info in `SyntaxKind` is not possible due to its layout requirements of
         // being `u16` that come from `rowan::SyntaxKind`.
-        let mut err = "";
+        let mut errors: Vec<String> = vec![];
 
         let syntax_kind = {
             match kind {
                 rustc_lexer::TokenKind::LineComment { doc_style: _ } => COMMENT,
                 rustc_lexer::TokenKind::BlockComment { doc_style: _, terminated } => {
                     if !terminated {
-                        err = "Missing trailing `*/` symbols to terminate the block comment";
+                        errors.push(
+                            "Missing trailing `*/` symbols to terminate the block comment".into(),
+                        );
                     }
                     COMMENT
                 }
@@ -184,9 +187,9 @@ fn extend_token(&mut self, kind: &rustc_lexer::TokenKind, mut token_text: &str)
                     invalid_infostring,
                 } => {
                     if *has_invalid_preceding_whitespace {
-                        err = "invalid preceding whitespace for frontmatter opening"
+                        errors.push("invalid preceding whitespace for frontmatter opening".into());
                     } else if *invalid_infostring {
-                        err = "invalid infostring for frontmatter"
+                        errors.push("invalid infostring for frontmatter".into());
                     }
                     FRONTMATTER
                 }
@@ -198,7 +201,7 @@ fn extend_token(&mut self, kind: &rustc_lexer::TokenKind, mut token_text: &str)
                     SyntaxKind::from_keyword(token_text, self.edition).unwrap_or(IDENT)
                 }
                 rustc_lexer::TokenKind::InvalidIdent => {
-                    err = "Ident contains invalid characters";
+                    errors.push("Ident contains invalid characters".into());
                     IDENT
                 }
 
@@ -206,7 +209,7 @@ fn extend_token(&mut self, kind: &rustc_lexer::TokenKind, mut token_text: &str)
 
                 rustc_lexer::TokenKind::GuardedStrPrefix if self.edition.at_least_2024() => {
                     // FIXME: rustc does something better for recovery.
-                    err = "Invalid string literal (reserved syntax)";
+                    errors.push("Invalid string literal (reserved syntax)".into());
                     ERROR
                 }
                 rustc_lexer::TokenKind::GuardedStrPrefix => {
@@ -222,12 +225,12 @@ fn extend_token(&mut self, kind: &rustc_lexer::TokenKind, mut token_text: &str)
 
                 rustc_lexer::TokenKind::Lifetime { starts_with_number } => {
                     if *starts_with_number {
-                        err = "Lifetime name cannot start with a number";
+                        errors.push("Lifetime name cannot start with a number".into());
                     }
                     LIFETIME_IDENT
                 }
                 rustc_lexer::TokenKind::UnknownPrefixLifetime => {
-                    err = "Unknown lifetime prefix";
+                    errors.push("Unknown lifetime prefix".into());
                     LIFETIME_IDENT
                 }
                 rustc_lexer::TokenKind::RawLifetime => LIFETIME_IDENT,
@@ -262,119 +265,128 @@ fn extend_token(&mut self, kind: &rustc_lexer::TokenKind, mut token_text: &str)
                 rustc_lexer::TokenKind::Unknown => ERROR,
                 rustc_lexer::TokenKind::UnknownPrefix if token_text == "builtin" => IDENT,
                 rustc_lexer::TokenKind::UnknownPrefix => {
-                    err = "unknown literal prefix";
+                    errors.push("unknown literal prefix".into());
                     IDENT
                 }
                 rustc_lexer::TokenKind::Eof => EOF,
             }
         };
 
-        let err = if err.is_empty() { None } else { Some(err) };
-        self.push(syntax_kind, token_text.len(), err);
+        self.push(syntax_kind, token_text.len(), errors);
     }
 
     fn extend_literal(&mut self, len: usize, kind: &rustc_lexer::LiteralKind) {
-        let mut err = "";
+        let invalid_raw_msg = String::from("Invalid raw string literal");
+
+        let mut errors = vec![];
+        let mut no_end_quote = |c: char, kind: &str| {
+            errors.push(format!("Missing trailing `{c}` symbol to terminate the {kind} literal"));
+        };
 
         let syntax_kind = match *kind {
             rustc_lexer::LiteralKind::Int { empty_int, base: _ } => {
                 if empty_int {
-                    err = "Missing digits after the integer base prefix";
+                    errors.push("Missing digits after the integer base prefix".into());
                 }
                 INT_NUMBER
             }
             rustc_lexer::LiteralKind::Float { empty_exponent, base: _ } => {
                 if empty_exponent {
-                    err = "Missing digits after the exponent symbol";
+                    errors.push("Missing digits after the exponent symbol".into());
                 }
                 FLOAT_NUMBER
             }
             rustc_lexer::LiteralKind::Char { terminated } => {
                 if !terminated {
-                    err = "Missing trailing `'` symbol to terminate the character literal";
+                    no_end_quote('\'', "character");
                 } else {
                     let text = &self.res.text[self.offset + 1..][..len - 1];
-                    let i = text.rfind('\'').unwrap();
-                    let text = &text[..i];
+                    let text = &text[..text.rfind('\'').unwrap()];
                     if let Err(e) = unescape_char(text) {
-                        err = error_to_diagnostic_message(e, Mode::Char);
+                        errors.push(err_to_msg(e, Mode::Char));
                     }
                 }
                 CHAR
             }
             rustc_lexer::LiteralKind::Byte { terminated } => {
                 if !terminated {
-                    err = "Missing trailing `'` symbol to terminate the byte literal";
+                    no_end_quote('\'', "byte");
                 } else {
                     let text = &self.res.text[self.offset + 2..][..len - 2];
-                    let i = text.rfind('\'').unwrap();
-                    let text = &text[..i];
+                    let text = &text[..text.rfind('\'').unwrap()];
                     if let Err(e) = unescape_byte(text) {
-                        err = error_to_diagnostic_message(e, Mode::Byte);
+                        errors.push(err_to_msg(e, Mode::Byte));
                     }
                 }
-
                 BYTE
             }
             rustc_lexer::LiteralKind::Str { terminated } => {
                 if !terminated {
-                    err = "Missing trailing `\"` symbol to terminate the string literal";
+                    no_end_quote('"', "string");
                 } else {
                     let text = &self.res.text[self.offset + 1..][..len - 1];
-                    let i = text.rfind('"').unwrap();
-                    let text = &text[..i];
-                    err = unescape_string_error_message(text, Mode::Str);
+                    let text = &text[..text.rfind('"').unwrap()];
+                    unescape_str(text, |_, res| {
+                        if let Err(e) = res {
+                            errors.push(err_to_msg(e, Mode::Str));
+                        }
+                    });
                 }
                 STRING
             }
             rustc_lexer::LiteralKind::ByteStr { terminated } => {
                 if !terminated {
-                    err = "Missing trailing `\"` symbol to terminate the byte string literal";
+                    no_end_quote('"', "byte string");
                 } else {
                     let text = &self.res.text[self.offset + 2..][..len - 2];
-                    let i = text.rfind('"').unwrap();
-                    let text = &text[..i];
-                    err = unescape_string_error_message(text, Mode::ByteStr);
+                    let text = &text[..text.rfind('"').unwrap()];
+                    unescape_byte_str(text, |_, res| {
+                        if let Err(e) = res {
+                            errors.push(err_to_msg(e, Mode::ByteStr));
+                        }
+                    });
                 }
                 BYTE_STRING
             }
             rustc_lexer::LiteralKind::CStr { terminated } => {
                 if !terminated {
-                    err = "Missing trailing `\"` symbol to terminate the string literal";
+                    no_end_quote('"', "C string")
                 } else {
                     let text = &self.res.text[self.offset + 2..][..len - 2];
-                    let i = text.rfind('"').unwrap();
-                    let text = &text[..i];
-                    err = unescape_string_error_message(text, Mode::CStr);
+                    let text = &text[..text.rfind('"').unwrap()];
+                    unescape_c_str(text, |_, res| {
+                        if let Err(e) = res {
+                            errors.push(err_to_msg(e, Mode::CStr));
+                        }
+                    });
                 }
                 C_STRING
             }
             rustc_lexer::LiteralKind::RawStr { n_hashes } => {
                 if n_hashes.is_none() {
-                    err = "Invalid raw string literal";
+                    errors.push(invalid_raw_msg);
                 }
                 STRING
             }
             rustc_lexer::LiteralKind::RawByteStr { n_hashes } => {
                 if n_hashes.is_none() {
-                    err = "Invalid raw string literal";
+                    errors.push(invalid_raw_msg);
                 }
                 BYTE_STRING
             }
             rustc_lexer::LiteralKind::RawCStr { n_hashes } => {
                 if n_hashes.is_none() {
-                    err = "Invalid raw string literal";
+                    errors.push(invalid_raw_msg);
                 }
                 C_STRING
             }
         };
 
-        let err = if err.is_empty() { None } else { Some(err) };
-        self.push(syntax_kind, len, err);
+        self.push(syntax_kind, len, errors);
     }
 }
 
-fn error_to_diagnostic_message(error: EscapeError, mode: Mode) -> &'static str {
+fn err_to_msg(error: EscapeError, mode: Mode) -> String {
     match error {
         EscapeError::ZeroChars => "empty character literal",
         EscapeError::MoreThanOneChar => "character literal may only contain one codepoint",
@@ -410,28 +422,5 @@ fn error_to_diagnostic_message(error: EscapeError, mode: Mode) -> &'static str {
         EscapeError::UnskippedWhitespaceWarning => "",
         EscapeError::MultipleSkippedLinesWarning => "",
     }
-}
-
-fn unescape_string_error_message(text: &str, mode: Mode) -> &'static str {
-    let mut error_message = "";
-    match mode {
-        Mode::CStr => {
-            unescape_mixed(text, mode, &mut |_, res| {
-                if let Err(e) = res {
-                    error_message = error_to_diagnostic_message(e, mode);
-                }
-            });
-        }
-        Mode::ByteStr | Mode::Str => {
-            unescape_unicode(text, mode, &mut |_, res| {
-                if let Err(e) = res {
-                    error_message = error_to_diagnostic_message(e, mode);
-                }
-            });
-        }
-        _ => {
-            // Other Modes are not supported yet or do not apply
-        }
-    }
-    error_message
+    .into()
 }
diff --git a/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rast b/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rast
index dee860c..259637c 100644
--- a/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rast
+++ b/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rast
@@ -40,8 +40,9 @@
           PLUS "+"
           WHITESPACE " "
           TYPE_BOUND
-            TILDE "~"
+            L_BRACK "["
             CONST_KW "const"
+            R_BRACK "]"
             WHITESPACE " "
             PATH_TYPE
               PATH
diff --git a/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rs b/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rs
index 5da3083..8f37af7 100644
--- a/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rs
+++ b/src/tools/rust-analyzer/crates/parser/test_data/parser/inline/ok/type_param_bounds.rs
@@ -1 +1 @@
-struct S<T: 'a + ?Sized + (Copy) + ~const Drop>;
+struct S<T: 'a + ?Sized + (Copy) + [const] Drop>;
diff --git a/src/tools/rust-analyzer/crates/paths/Cargo.toml b/src/tools/rust-analyzer/crates/paths/Cargo.toml
index 4cc7072..f0dafab 100644
--- a/src/tools/rust-analyzer/crates/paths/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/paths/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 camino.workspace = true
diff --git a/src/tools/rust-analyzer/crates/proc-macro-api/Cargo.toml b/src/tools/rust-analyzer/crates/proc-macro-api/Cargo.toml
index f5ba40a..dac8e09 100644
--- a/src/tools/rust-analyzer/crates/proc-macro-api/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/proc-macro-api/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 serde.workspace = true
diff --git a/src/tools/rust-analyzer/crates/proc-macro-srv/Cargo.toml b/src/tools/rust-analyzer/crates/proc-macro-srv/Cargo.toml
index 8fd675d..4034f24 100644
--- a/src/tools/rust-analyzer/crates/proc-macro-srv/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/proc-macro-srv/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 object.workspace = true
diff --git a/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/Cargo.toml b/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/Cargo.toml
index c416d99..bc04482 100644
--- a/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/Cargo.toml
@@ -7,6 +7,7 @@
 license = "MIT OR Apache-2.0"
 
 [lib]
+doctest = false
 
 [build-dependencies]
 cargo_metadata = "0.20.0"
diff --git a/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/build.rs b/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/build.rs
index b97569d..b9e84a4 100644
--- a/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/build.rs
+++ b/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/build.rs
@@ -109,13 +109,11 @@ fn main() {
 
     let mut artifact_path = None;
     for message in Message::parse_stream(output.stdout.as_slice()) {
-        if let Message::CompilerArtifact(artifact) = message.unwrap() {
-            if artifact.target.kind.contains(&cargo_metadata::TargetKind::ProcMacro)
-                && (artifact.package_id.repr.starts_with(&repr)
-                    || artifact.package_id.repr == pkgid)
-            {
-                artifact_path = Some(PathBuf::from(&artifact.filenames[0]));
-            }
+        if let Message::CompilerArtifact(artifact) = message.unwrap()
+            && artifact.target.kind.contains(&cargo_metadata::TargetKind::ProcMacro)
+            && (artifact.package_id.repr.starts_with(&repr) || artifact.package_id.repr == pkgid)
+        {
+            artifact_path = Some(PathBuf::from(&artifact.filenames[0]));
         }
     }
 
diff --git a/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/imp/Cargo.toml b/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/imp/Cargo.toml
index 33b7c2b..e1678bd 100644
--- a/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/imp/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/proc-macro-srv/proc-macro-test/imp/Cargo.toml
@@ -6,6 +6,7 @@
 publish = false
 
 [lib]
+doctest = false
 proc-macro = true
 
 [dependencies]
diff --git a/src/tools/rust-analyzer/crates/profile/Cargo.toml b/src/tools/rust-analyzer/crates/profile/Cargo.toml
index bae891c..4828419 100644
--- a/src/tools/rust-analyzer/crates/profile/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/profile/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 cfg-if = "1.0.1"
diff --git a/src/tools/rust-analyzer/crates/project-model/Cargo.toml b/src/tools/rust-analyzer/crates/project-model/Cargo.toml
index 64ea759..27fe9f7 100644
--- a/src/tools/rust-analyzer/crates/project-model/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/project-model/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 anyhow.workspace = true
diff --git a/src/tools/rust-analyzer/crates/project-model/src/build_dependencies.rs b/src/tools/rust-analyzer/crates/project-model/src/build_dependencies.rs
index 4435376..bbaa8f4 100644
--- a/src/tools/rust-analyzer/crates/project-model/src/build_dependencies.rs
+++ b/src/tools/rust-analyzer/crates/project-model/src/build_dependencies.rs
@@ -20,9 +20,7 @@
 
 use crate::{
     CargoConfig, CargoFeatures, CargoWorkspace, InvocationStrategy, ManifestPath, Package, Sysroot,
-    TargetKind,
-    toolchain_info::{QueryConfig, version},
-    utf8_stdout,
+    TargetKind, utf8_stdout,
 };
 
 /// Output of the build script and proc-macro building steps for a workspace.
@@ -64,6 +62,7 @@ pub(crate) fn run_for_workspace(
         workspace: &CargoWorkspace,
         progress: &dyn Fn(String),
         sysroot: &Sysroot,
+        toolchain: Option<&semver::Version>,
     ) -> io::Result<WorkspaceBuildScripts> {
         let current_dir = workspace.workspace_root();
 
@@ -74,6 +73,7 @@ pub(crate) fn run_for_workspace(
             workspace.manifest_path(),
             current_dir,
             sysroot,
+            toolchain,
         )?;
         Self::run_per_ws(cmd, workspace, progress)
     }
@@ -95,6 +95,7 @@ pub(crate) fn run_once(
             &ManifestPath::try_from(working_directory.clone()).unwrap(),
             working_directory,
             &Sysroot::empty(),
+            None,
         )?;
         // NB: Cargo.toml could have been modified between `cargo metadata` and
         // `cargo check`. We shouldn't assume that package ids we see here are
@@ -356,7 +357,7 @@ fn run_command(
                         });
                     }
                     Message::CompilerMessage(message) => {
-                        progress(message.target.name);
+                        progress(format!("received compiler message for: {}", message.target.name));
 
                         if let Some(diag) = message.message.rendered.as_deref() {
                             push_err(diag);
@@ -387,12 +388,13 @@ fn build_command(
         manifest_path: &ManifestPath,
         current_dir: &AbsPath,
         sysroot: &Sysroot,
+        toolchain: Option<&semver::Version>,
     ) -> io::Result<Command> {
-        let mut cmd = match config.run_build_script_command.as_deref() {
+        match config.run_build_script_command.as_deref() {
             Some([program, args @ ..]) => {
                 let mut cmd = toolchain::command(program, current_dir, &config.extra_env);
                 cmd.args(args);
-                cmd
+                Ok(cmd)
             }
             _ => {
                 let mut cmd = sysroot.tool(Tool::Cargo, current_dir, &config.extra_env);
@@ -444,40 +446,35 @@ fn build_command(
 
                 cmd.arg("--keep-going");
 
-                cmd
+                // If [`--compile-time-deps` flag](https://github.com/rust-lang/cargo/issues/14434) is
+                // available in current toolchain's cargo, use it to build compile time deps only.
+                const COMP_TIME_DEPS_MIN_TOOLCHAIN_VERSION: semver::Version = semver::Version {
+                    major: 1,
+                    minor: 89,
+                    patch: 0,
+                    pre: semver::Prerelease::EMPTY,
+                    build: semver::BuildMetadata::EMPTY,
+                };
+
+                let cargo_comp_time_deps_available =
+                    toolchain.is_some_and(|v| *v >= COMP_TIME_DEPS_MIN_TOOLCHAIN_VERSION);
+
+                if cargo_comp_time_deps_available {
+                    cmd.env("__CARGO_TEST_CHANNEL_OVERRIDE_DO_NOT_USE_THIS", "nightly");
+                    cmd.arg("-Zunstable-options");
+                    cmd.arg("--compile-time-deps");
+                } else if config.wrap_rustc_in_build_scripts {
+                    // Setup RUSTC_WRAPPER to point to `rust-analyzer` binary itself. We use
+                    // that to compile only proc macros and build scripts during the initial
+                    // `cargo check`.
+                    // We don't need this if we are using `--compile-time-deps` flag.
+                    let myself = std::env::current_exe()?;
+                    cmd.env("RUSTC_WRAPPER", myself);
+                    cmd.env("RA_RUSTC_WRAPPER", "1");
+                }
+                Ok(cmd)
             }
-        };
-
-        // If [`--compile-time-deps` flag](https://github.com/rust-lang/cargo/issues/14434) is
-        // available in current toolchain's cargo, use it to build compile time deps only.
-        const COMP_TIME_DEPS_MIN_TOOLCHAIN_VERSION: semver::Version = semver::Version {
-            major: 1,
-            minor: 90,
-            patch: 0,
-            pre: semver::Prerelease::EMPTY,
-            build: semver::BuildMetadata::EMPTY,
-        };
-
-        let query_config = QueryConfig::Cargo(sysroot, manifest_path);
-        let toolchain = version::get(query_config, &config.extra_env).ok().flatten();
-        let cargo_comp_time_deps_available =
-            toolchain.is_some_and(|v| v >= COMP_TIME_DEPS_MIN_TOOLCHAIN_VERSION);
-
-        if cargo_comp_time_deps_available {
-            cmd.env("__CARGO_TEST_CHANNEL_OVERRIDE_DO_NOT_USE_THIS", "nightly");
-            cmd.arg("-Zunstable-options");
-            cmd.arg("--compile-time-deps");
-        } else if config.wrap_rustc_in_build_scripts {
-            // Setup RUSTC_WRAPPER to point to `rust-analyzer` binary itself. We use
-            // that to compile only proc macros and build scripts during the initial
-            // `cargo check`.
-            // We don't need this if we are using `--compile-time-deps` flag.
-            let myself = std::env::current_exe()?;
-            cmd.env("RUSTC_WRAPPER", myself);
-            cmd.env("RA_RUSTC_WRAPPER", "1");
         }
-
-        Ok(cmd)
     }
 }
 
diff --git a/src/tools/rust-analyzer/crates/project-model/src/cargo_workspace.rs b/src/tools/rust-analyzer/crates/project-model/src/cargo_workspace.rs
index 5850741..4bacc90 100644
--- a/src/tools/rust-analyzer/crates/project-model/src/cargo_workspace.rs
+++ b/src/tools/rust-analyzer/crates/project-model/src/cargo_workspace.rs
@@ -48,6 +48,7 @@ pub struct CargoWorkspace {
     is_sysroot: bool,
     /// Environment variables set in the `.cargo/config` file.
     config_env: Env,
+    requires_rustc_private: bool,
 }
 
 impl ops::Index<Package> for CargoWorkspace {
@@ -513,6 +514,7 @@ pub fn new(
         let workspace_root = AbsPathBuf::assert(meta.workspace_root);
         let target_directory = AbsPathBuf::assert(meta.target_directory);
         let mut is_virtual_workspace = true;
+        let mut requires_rustc_private = false;
 
         meta.packages.sort_by(|a, b| a.id.cmp(&b.id));
         for meta_pkg in meta.packages {
@@ -577,6 +579,7 @@ pub fn new(
                 metadata: meta.rust_analyzer.unwrap_or_default(),
             });
             let pkg_data = &mut packages[pkg];
+            requires_rustc_private |= pkg_data.metadata.rustc_private;
             pkg_by_id.insert(id, pkg);
             for meta_tgt in meta_targets {
                 let cargo_metadata::Target { name, kind, required_features, src_path, .. } =
@@ -626,6 +629,7 @@ pub fn new(
             target_directory,
             manifest_path: ws_manifest_path,
             is_virtual_workspace,
+            requires_rustc_private,
             is_sysroot,
             config_env: cargo_config_env,
         }
@@ -724,4 +728,8 @@ pub fn env(&self) -> &Env {
     pub fn is_sysroot(&self) -> bool {
         self.is_sysroot
     }
+
+    pub fn requires_rustc_private(&self) -> bool {
+        self.requires_rustc_private
+    }
 }
diff --git a/src/tools/rust-analyzer/crates/project-model/src/env.rs b/src/tools/rust-analyzer/crates/project-model/src/env.rs
index 450def5..9e0415c 100644
--- a/src/tools/rust-analyzer/crates/project-model/src/env.rs
+++ b/src/tools/rust-analyzer/crates/project-model/src/env.rs
@@ -1,6 +1,6 @@
 //! Cargo-like environment variables injection.
 use base_db::Env;
-use paths::Utf8Path;
+use paths::{Utf8Path, Utf8PathBuf};
 use rustc_hash::FxHashMap;
 use toolchain::Tool;
 
@@ -123,6 +123,26 @@ fn parse_output_cargo_config_env(manifest: &ManifestPath, stdout: &str) -> Env {
     env
 }
 
+pub(crate) fn cargo_config_build_target_dir(
+    manifest: &ManifestPath,
+    extra_env: &FxHashMap<String, Option<String>>,
+    sysroot: &Sysroot,
+) -> Option<Utf8PathBuf> {
+    let mut cargo_config = sysroot.tool(Tool::Cargo, manifest.parent(), extra_env);
+    cargo_config
+        .args(["-Z", "unstable-options", "config", "get", "build.target-dir"])
+        .env("RUSTC_BOOTSTRAP", "1");
+    if manifest.is_rust_manifest() {
+        cargo_config.arg("-Zscript");
+    }
+    utf8_stdout(&mut cargo_config)
+        .map(|stdout| {
+            Utf8Path::new(stdout.trim_start_matches("build.target-dir = ").trim_matches('"'))
+                .to_owned()
+        })
+        .ok()
+}
+
 #[test]
 fn parse_output_cargo_config_env_works() {
     let stdout = r#"
diff --git a/src/tools/rust-analyzer/crates/project-model/src/workspace.rs b/src/tools/rust-analyzer/crates/project-model/src/workspace.rs
index a6743a3..5bc64df 100644
--- a/src/tools/rust-analyzer/crates/project-model/src/workspace.rs
+++ b/src/tools/rust-analyzer/crates/project-model/src/workspace.rs
@@ -16,6 +16,7 @@
 use rustc_hash::{FxHashMap, FxHashSet};
 use semver::Version;
 use span::{Edition, FileId};
+use toolchain::Tool;
 use tracing::instrument;
 use triomphe::Arc;
 
@@ -25,10 +26,14 @@
     WorkspaceBuildScripts,
     build_dependencies::BuildScriptOutput,
     cargo_workspace::{CargoMetadataConfig, DepKind, PackageData, RustLibSource},
-    env::{cargo_config_env, inject_cargo_env, inject_cargo_package_env, inject_rustc_tool_env},
+    env::{
+        cargo_config_build_target_dir, cargo_config_env, inject_cargo_env,
+        inject_cargo_package_env, inject_rustc_tool_env,
+    },
     project_json::{Crate, CrateArrayIdx},
     sysroot::RustLibSrcWorkspace,
     toolchain_info::{QueryConfig, rustc_cfg, target_data_layout, target_tuple, version},
+    utf8_stdout,
 };
 use tracing::{debug, error, info};
 
@@ -208,8 +213,7 @@ fn load_cargo(
         config: &CargoConfig,
         progress: &(dyn Fn(String) + Sync),
     ) -> Result<ProjectWorkspace, anyhow::Error> {
-        progress("Discovering sysroot".to_owned());
-        let workspace_dir = cargo_toml.parent();
+        progress("discovering sysroot".to_owned());
         let CargoConfig {
             features,
             rustc_source,
@@ -224,6 +228,7 @@ fn load_cargo(
             no_deps,
             ..
         } = config;
+        let workspace_dir = cargo_toml.parent();
         let mut sysroot = match (sysroot, sysroot_src) {
             (Some(RustLibSource::Discover), None) => Sysroot::discover(workspace_dir, extra_env),
             (Some(RustLibSource::Discover), Some(sysroot_src)) => {
@@ -238,8 +243,33 @@ fn load_cargo(
             (None, _) => Sysroot::empty(),
         };
 
+        // Resolve the Cargo.toml to the workspace root as we base the `target` dir off of it.
+        let mut cmd = sysroot.tool(Tool::Cargo, workspace_dir, extra_env);
+        cmd.args(["locate-project", "--workspace", "--manifest-path", cargo_toml.as_str()]);
+        let cargo_toml = &match utf8_stdout(&mut cmd) {
+            Ok(output) => {
+                #[derive(serde_derive::Deserialize)]
+                struct Root {
+                    root: Utf8PathBuf,
+                }
+                match serde_json::from_str::<Root>(&output) {
+                    Ok(object) => ManifestPath::try_from(AbsPathBuf::assert(object.root))
+                        .expect("manifest path should be absolute"),
+                    Err(e) => {
+                        tracing::error!(%e, %cargo_toml, "failed fetching cargo workspace root");
+                        cargo_toml.clone()
+                    }
+                }
+            }
+            Err(e) => {
+                tracing::error!(%e, %cargo_toml, "failed fetching cargo workspace root");
+                cargo_toml.clone()
+            }
+        };
+        let workspace_dir = cargo_toml.parent();
+
         tracing::info!(workspace = %cargo_toml, src_root = ?sysroot.rust_lib_src_root(), root = ?sysroot.root(), "Using sysroot");
-        progress("Querying project metadata".to_owned());
+        progress("querying project metadata".to_owned());
         let toolchain_config = QueryConfig::Cargo(&sysroot, cargo_toml);
         let targets =
             target_tuple::get(toolchain_config, target.as_deref(), extra_env).unwrap_or_default();
@@ -252,8 +282,11 @@ fn load_cargo(
             .ok()
             .flatten();
 
-        let target_dir =
-            config.target_dir.clone().unwrap_or_else(|| workspace_dir.join("target").into());
+        let target_dir = config
+            .target_dir
+            .clone()
+            .or_else(|| cargo_config_build_target_dir(cargo_toml, extra_env, &sysroot))
+            .unwrap_or_else(|| workspace_dir.join("target").into());
 
         // We spawn a bunch of processes to query various information about the workspace's
         // toolchain and sysroot
@@ -374,11 +407,17 @@ fn load_cargo(
             ))
         });
 
-        let (rustc_cfg, data_layout, rustc, loaded_sysroot, cargo_metadata, cargo_config_extra_env) =
-            match join {
-                Ok(it) => it,
-                Err(e) => std::panic::resume_unwind(e),
-            };
+        let (
+            rustc_cfg,
+            data_layout,
+            mut rustc,
+            loaded_sysroot,
+            cargo_metadata,
+            cargo_config_extra_env,
+        ) = match join {
+            Ok(it) => it,
+            Err(e) => std::panic::resume_unwind(e),
+        };
 
         let (meta, error) = cargo_metadata.with_context(|| {
             format!(
@@ -391,6 +430,14 @@ fn load_cargo(
             sysroot.set_workspace(loaded_sysroot);
         }
 
+        if !cargo.requires_rustc_private() {
+            if let Err(e) = &mut rustc {
+                // We don't need the rustc sources here,
+                // so just discard the error.
+                _ = e.take();
+            }
+        }
+
         Ok(ProjectWorkspace {
             kind: ProjectWorkspaceKind::Cargo {
                 cargo,
@@ -413,17 +460,25 @@ pub fn load_inline(
         config: &CargoConfig,
         progress: &(dyn Fn(String) + Sync),
     ) -> ProjectWorkspace {
-        progress("Discovering sysroot".to_owned());
+        progress("discovering sysroot".to_owned());
         let mut sysroot =
             Sysroot::new(project_json.sysroot.clone(), project_json.sysroot_src.clone());
 
         tracing::info!(workspace = %project_json.manifest_or_root(), src_root = ?sysroot.rust_lib_src_root(), root = ?sysroot.root(), "Using sysroot");
-        progress("Querying project metadata".to_owned());
+        progress("querying project metadata".to_owned());
         let sysroot_project = project_json.sysroot_project.take();
         let query_config = QueryConfig::Rustc(&sysroot, project_json.path().as_ref());
         let targets = target_tuple::get(query_config, config.target.as_deref(), &config.extra_env)
             .unwrap_or_default();
         let toolchain = version::get(query_config, &config.extra_env).ok().flatten();
+        let project_root = project_json.project_root();
+        let target_dir = config
+            .target_dir
+            .clone()
+            .or_else(|| {
+                cargo_config_build_target_dir(project_json.manifest()?, &config.extra_env, &sysroot)
+            })
+            .unwrap_or_else(|| project_root.join("target").into());
 
         // We spawn a bunch of processes to query various information about the workspace's
         // toolchain and sysroot
@@ -441,7 +496,6 @@ pub fn load_inline(
                 )
             });
             let loaded_sysroot = s.spawn(|| {
-                let project_root = project_json.project_root();
                 if let Some(sysroot_project) = sysroot_project {
                     sysroot.load_workspace(
                         &RustSourceWorkspaceConfig::Json(*sysroot_project),
@@ -449,10 +503,6 @@ pub fn load_inline(
                         progress,
                     )
                 } else {
-                    let target_dir = config
-                        .target_dir
-                        .clone()
-                        .unwrap_or_else(|| project_root.join("target").into());
                     sysroot.load_workspace(
                         &RustSourceWorkspaceConfig::CargoMetadata(sysroot_metadata_config(
                             config,
@@ -507,7 +557,12 @@ pub fn load_detached_file(
             .unwrap_or_default();
         let rustc_cfg = rustc_cfg::get(query_config, None, &config.extra_env);
         let data_layout = target_data_layout::get(query_config, None, &config.extra_env);
-        let target_dir = config.target_dir.clone().unwrap_or_else(|| dir.join("target").into());
+        let target_dir = config
+            .target_dir
+            .clone()
+            .or_else(|| cargo_config_build_target_dir(detached_file, &config.extra_env, &sysroot))
+            .unwrap_or_else(|| dir.join("target").into());
+
         let loaded_sysroot = sysroot.load_workspace(
             &RustSourceWorkspaceConfig::CargoMetadata(sysroot_metadata_config(
                 config,
@@ -581,10 +636,16 @@ pub fn run_build_scripts(
         match &self.kind {
             ProjectWorkspaceKind::DetachedFile { cargo: Some((cargo, _, None)), .. }
             | ProjectWorkspaceKind::Cargo { cargo, error: None, .. } => {
-                WorkspaceBuildScripts::run_for_workspace(config, cargo, progress, &self.sysroot)
-                    .with_context(|| {
-                        format!("Failed to run build scripts for {}", cargo.workspace_root())
-                    })
+                WorkspaceBuildScripts::run_for_workspace(
+                    config,
+                    cargo,
+                    progress,
+                    &self.sysroot,
+                    self.toolchain.as_ref(),
+                )
+                .with_context(|| {
+                    format!("Failed to run build scripts for {}", cargo.workspace_root())
+                })
             }
             _ => Ok(WorkspaceBuildScripts::default()),
         }
@@ -1166,14 +1227,10 @@ fn cargo_to_crate_graph(
     // Mapping of a package to its library target
     let mut pkg_to_lib_crate = FxHashMap::default();
     let mut pkg_crates = FxHashMap::default();
-    // Does any crate signal to rust-analyzer that they need the rustc_private crates?
-    let mut has_private = false;
     let workspace_proc_macro_cwd = Arc::new(cargo.workspace_root().to_path_buf());
 
     // Next, create crates for each package, target pair
     for pkg in cargo.packages() {
-        has_private |= cargo[pkg].metadata.rustc_private;
-
         let cfg_options = {
             let mut cfg_options = cfg_options.clone();
 
@@ -1318,7 +1375,7 @@ fn cargo_to_crate_graph(
         add_dep(crate_graph, from, name, to);
     }
 
-    if has_private {
+    if cargo.requires_rustc_private() {
         // If the user provided a path to rustc sources, we add all the rustc_private crates
         // and create dependencies on them for the crates which opt-in to that
         if let Some((rustc_workspace, rustc_build_scripts)) = rustc {
@@ -1588,7 +1645,7 @@ fn add_target_crate_root(
                     None => Err("proc-macro crate build data is missing dylib path".to_owned()),
                 }
             }
-            None => Err("proc-macro crate is missing its build data".to_owned()),
+            None => Err("build scripts have not been built".to_owned()),
         };
         proc_macros.insert(crate_id, proc_macro);
     }
diff --git a/src/tools/rust-analyzer/crates/query-group-macro/Cargo.toml b/src/tools/rust-analyzer/crates/query-group-macro/Cargo.toml
index 8b03d8f..5991120 100644
--- a/src/tools/rust-analyzer/crates/query-group-macro/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/query-group-macro/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 proc-macro = true
 
 [dependencies]
diff --git a/src/tools/rust-analyzer/crates/rust-analyzer/Cargo.toml b/src/tools/rust-analyzer/crates/rust-analyzer/Cargo.toml
index 5e63521..b301a71 100644
--- a/src/tools/rust-analyzer/crates/rust-analyzer/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/rust-analyzer/Cargo.toml
@@ -13,6 +13,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [[bin]]
 name = "rust-analyzer"
diff --git a/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs b/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs
index 05e1b83..e716d14 100644
--- a/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs
+++ b/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs
@@ -94,6 +94,8 @@ pub enum MaxSubstitutionLength {
 
 
 
+        /// Enables highlighting of related return values while the cursor is on any `match`, `if`, or match arm arrow (`=>`).
+        highlightRelated_branchExitPoints_enable: bool = true,
         /// Enables highlighting of related references while the cursor is on `break`, `loop`, `while`, or `for` keywords.
         highlightRelated_breakPoints_enable: bool = true,
         /// Enables highlighting of all captures of a closure while the cursor is on the `|` or move keyword of a closure.
@@ -1629,6 +1631,7 @@ pub fn highlight_related(&self, _source_root: Option<SourceRootId>) -> Highlight
             exit_points: self.highlightRelated_exitPoints_enable().to_owned(),
             yield_points: self.highlightRelated_yieldPoints_enable().to_owned(),
             closure_captures: self.highlightRelated_closureCaptures_enable().to_owned(),
+            branch_exit_points: self.highlightRelated_branchExitPoints_enable().to_owned(),
         }
     }
 
diff --git a/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs b/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs
index afd9eff..a76a652 100644
--- a/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs
+++ b/src/tools/rust-analyzer/crates/rust-analyzer/src/handlers/request.rs
@@ -2433,17 +2433,14 @@ fn run_rustfmt(
             }
             _ => {
                 // Something else happened - e.g. `rustfmt` is missing or caught a signal
-                Err(LspError::new(
-                    -32900,
-                    format!(
-                        r#"rustfmt exited with:
-                           Status: {}
-                           stdout: {captured_stdout}
-                           stderr: {captured_stderr}"#,
-                        output.status,
-                    ),
-                )
-                .into())
+                tracing::error!(
+                    ?command,
+                    %output.status,
+                    %captured_stdout,
+                    %captured_stderr,
+                    "rustfmt failed"
+                );
+                Ok(None)
             }
         };
     }
diff --git a/src/tools/rust-analyzer/crates/rust-analyzer/src/lsp/to_proto.rs b/src/tools/rust-analyzer/crates/rust-analyzer/src/lsp/to_proto.rs
index 4efe330..8a848fb 100644
--- a/src/tools/rust-analyzer/crates/rust-analyzer/src/lsp/to_proto.rs
+++ b/src/tools/rust-analyzer/crates/rust-analyzer/src/lsp/to_proto.rs
@@ -900,14 +900,17 @@ pub(crate) fn folding_range(
         FoldKind::Comment => Some(lsp_types::FoldingRangeKind::Comment),
         FoldKind::Imports => Some(lsp_types::FoldingRangeKind::Imports),
         FoldKind::Region => Some(lsp_types::FoldingRangeKind::Region),
-        FoldKind::Mods
+        FoldKind::Modules
         | FoldKind::Block
         | FoldKind::ArgList
         | FoldKind::Consts
         | FoldKind::Statics
+        | FoldKind::TypeAliases
         | FoldKind::WhereClause
         | FoldKind::ReturnType
         | FoldKind::Array
+        | FoldKind::TraitAliases
+        | FoldKind::ExternCrates
         | FoldKind::MatchArm => None,
     };
 
diff --git a/src/tools/rust-analyzer/crates/rust-analyzer/src/reload.rs b/src/tools/rust-analyzer/crates/rust-analyzer/src/reload.rs
index 189d95e..133d5a6 100644
--- a/src/tools/rust-analyzer/crates/rust-analyzer/src/reload.rs
+++ b/src/tools/rust-analyzer/crates/rust-analyzer/src/reload.rs
@@ -428,7 +428,7 @@ pub(crate) fn fetch_proc_macros(
                     let expansion_res = match client {
                         Ok(client) => match res {
                             Ok((crate_name, path)) => {
-                                progress(path.to_string());
+                                progress(format!("loading proc-macros: {path}"));
                                 let ignored_proc_macros = ignored_proc_macros
                                     .iter()
                                     .find_map(|(name, macros)| {
diff --git a/src/tools/rust-analyzer/crates/stdx/Cargo.toml b/src/tools/rust-analyzer/crates/stdx/Cargo.toml
index a6d5781..2c19f00 100644
--- a/src/tools/rust-analyzer/crates/stdx/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/stdx/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 backtrace = { version = "0.3.75", optional = true }
diff --git a/src/tools/rust-analyzer/crates/syntax-bridge/Cargo.toml b/src/tools/rust-analyzer/crates/syntax-bridge/Cargo.toml
index cccd41d..b0fd40f 100644
--- a/src/tools/rust-analyzer/crates/syntax-bridge/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/syntax-bridge/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 rustc-hash.workspace = true
diff --git a/src/tools/rust-analyzer/crates/syntax/Cargo.toml b/src/tools/rust-analyzer/crates/syntax/Cargo.toml
index 9d3aaa8..1ee9301 100644
--- a/src/tools/rust-analyzer/crates/syntax/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/syntax/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 either.workspace = true
diff --git a/src/tools/rust-analyzer/crates/syntax/rust.ungram b/src/tools/rust-analyzer/crates/syntax/rust.ungram
index c81da06..3f43947 100644
--- a/src/tools/rust-analyzer/crates/syntax/rust.ungram
+++ b/src/tools/rust-analyzer/crates/syntax/rust.ungram
@@ -669,7 +669,7 @@
 
 TypeBound =
   Lifetime
-| ('~' 'const' | 'const')? 'async'? '?'? Type
+| ('~' 'const' | '[' 'const' ']' | 'const')? 'async'? '?'? Type
 | 'use' UseBoundGenericArgs
 
 UseBoundGenericArgs =
diff --git a/src/tools/rust-analyzer/crates/syntax/src/ast/generated/nodes.rs b/src/tools/rust-analyzer/crates/syntax/src/ast/generated/nodes.rs
index 04c7e8a..79a9f4d 100644
--- a/src/tools/rust-analyzer/crates/syntax/src/ast/generated/nodes.rs
+++ b/src/tools/rust-analyzer/crates/syntax/src/ast/generated/nodes.rs
@@ -1766,6 +1766,10 @@ pub fn use_bound_generic_args(&self) -> Option<UseBoundGenericArgs> {
         support::child(&self.syntax)
     }
     #[inline]
+    pub fn l_brack_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T!['[']) }
+    #[inline]
+    pub fn r_brack_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![']']) }
+    #[inline]
     pub fn question_mark_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![?]) }
     #[inline]
     pub fn async_token(&self) -> Option<SyntaxToken> { support::token(&self.syntax, T![async]) }
diff --git a/src/tools/rust-analyzer/crates/syntax/src/ast/token_ext.rs b/src/tools/rust-analyzer/crates/syntax/src/ast/token_ext.rs
index ced3b71..4afdda7 100644
--- a/src/tools/rust-analyzer/crates/syntax/src/ast/token_ext.rs
+++ b/src/tools/rust-analyzer/crates/syntax/src/ast/token_ext.rs
@@ -1,9 +1,11 @@
 //! There are many AstNodes, but only a few tokens, so we hand-write them here.
 
+use std::ops::Range;
 use std::{borrow::Cow, num::ParseIntError};
 
 use rustc_literal_escaper::{
-    EscapeError, MixedUnit, Mode, unescape_byte, unescape_char, unescape_mixed, unescape_unicode,
+    EscapeError, MixedUnit, unescape_byte, unescape_byte_str, unescape_c_str, unescape_char,
+    unescape_str,
 };
 use stdx::always;
 
@@ -150,7 +152,7 @@ fn new(literal: &str) -> Option<QuoteOffsets> {
 
 pub trait IsString: AstToken {
     const RAW_PREFIX: &'static str;
-    const MODE: Mode;
+    fn unescape(s: &str, callback: impl FnMut(Range<usize>, Result<char, EscapeError>));
     fn is_raw(&self) -> bool {
         self.text().starts_with(Self::RAW_PREFIX)
     }
@@ -185,7 +187,7 @@ fn escaped_char_ranges(&self, cb: &mut dyn FnMut(TextRange, Result<char, EscapeE
         let text = &self.text()[text_range_no_quotes - start];
         let offset = text_range_no_quotes.start() - start;
 
-        unescape_unicode(text, Self::MODE, &mut |range, unescaped_char| {
+        Self::unescape(text, &mut |range: Range<usize>, unescaped_char| {
             if let Some((s, e)) = range.start.try_into().ok().zip(range.end.try_into().ok()) {
                 cb(TextRange::new(s, e) + offset, unescaped_char);
             }
@@ -203,7 +205,9 @@ fn map_range_up(&self, range: TextRange) -> Option<TextRange> {
 
 impl IsString for ast::String {
     const RAW_PREFIX: &'static str = "r";
-    const MODE: Mode = Mode::Str;
+    fn unescape(s: &str, cb: impl FnMut(Range<usize>, Result<char, EscapeError>)) {
+        unescape_str(s, cb)
+    }
 }
 
 impl ast::String {
@@ -218,20 +222,19 @@ pub fn value(&self) -> Result<Cow<'_, str>, EscapeError> {
         let mut buf = String::new();
         let mut prev_end = 0;
         let mut has_error = None;
-        unescape_unicode(text, Self::MODE, &mut |char_range, unescaped_char| match (
-            unescaped_char,
-            buf.capacity() == 0,
-        ) {
-            (Ok(c), false) => buf.push(c),
-            (Ok(_), true) if char_range.len() == 1 && char_range.start == prev_end => {
-                prev_end = char_range.end
+        unescape_str(text, |char_range, unescaped_char| {
+            match (unescaped_char, buf.capacity() == 0) {
+                (Ok(c), false) => buf.push(c),
+                (Ok(_), true) if char_range.len() == 1 && char_range.start == prev_end => {
+                    prev_end = char_range.end
+                }
+                (Ok(c), true) => {
+                    buf.reserve_exact(text.len());
+                    buf.push_str(&text[..prev_end]);
+                    buf.push(c);
+                }
+                (Err(e), _) => has_error = Some(e),
             }
-            (Ok(c), true) => {
-                buf.reserve_exact(text.len());
-                buf.push_str(&text[..prev_end]);
-                buf.push(c);
-            }
-            (Err(e), _) => has_error = Some(e),
         });
 
         match (has_error, buf.capacity() == 0) {
@@ -244,7 +247,9 @@ pub fn value(&self) -> Result<Cow<'_, str>, EscapeError> {
 
 impl IsString for ast::ByteString {
     const RAW_PREFIX: &'static str = "br";
-    const MODE: Mode = Mode::ByteStr;
+    fn unescape(s: &str, mut callback: impl FnMut(Range<usize>, Result<char, EscapeError>)) {
+        unescape_byte_str(s, |range, res| callback(range, res.map(char::from)))
+    }
 }
 
 impl ast::ByteString {
@@ -259,20 +264,19 @@ pub fn value(&self) -> Result<Cow<'_, [u8]>, EscapeError> {
         let mut buf: Vec<u8> = Vec::new();
         let mut prev_end = 0;
         let mut has_error = None;
-        unescape_unicode(text, Self::MODE, &mut |char_range, unescaped_char| match (
-            unescaped_char,
-            buf.capacity() == 0,
-        ) {
-            (Ok(c), false) => buf.push(c as u8),
-            (Ok(_), true) if char_range.len() == 1 && char_range.start == prev_end => {
-                prev_end = char_range.end
+        unescape_byte_str(text, |char_range, unescaped_byte| {
+            match (unescaped_byte, buf.capacity() == 0) {
+                (Ok(b), false) => buf.push(b),
+                (Ok(_), true) if char_range.len() == 1 && char_range.start == prev_end => {
+                    prev_end = char_range.end
+                }
+                (Ok(b), true) => {
+                    buf.reserve_exact(text.len());
+                    buf.extend_from_slice(&text.as_bytes()[..prev_end]);
+                    buf.push(b);
+                }
+                (Err(e), _) => has_error = Some(e),
             }
-            (Ok(c), true) => {
-                buf.reserve_exact(text.len());
-                buf.extend_from_slice(&text.as_bytes()[..prev_end]);
-                buf.push(c as u8);
-            }
-            (Err(e), _) => has_error = Some(e),
         });
 
         match (has_error, buf.capacity() == 0) {
@@ -285,25 +289,10 @@ pub fn value(&self) -> Result<Cow<'_, [u8]>, EscapeError> {
 
 impl IsString for ast::CString {
     const RAW_PREFIX: &'static str = "cr";
-    const MODE: Mode = Mode::CStr;
-
-    fn escaped_char_ranges(&self, cb: &mut dyn FnMut(TextRange, Result<char, EscapeError>)) {
-        let text_range_no_quotes = match self.text_range_between_quotes() {
-            Some(it) => it,
-            None => return,
-        };
-
-        let start = self.syntax().text_range().start();
-        let text = &self.text()[text_range_no_quotes - start];
-        let offset = text_range_no_quotes.start() - start;
-
-        unescape_mixed(text, Self::MODE, &mut |range, unescaped_char| {
-            let text_range =
-                TextRange::new(range.start.try_into().unwrap(), range.end.try_into().unwrap());
-            // XXX: This method should only be used for highlighting ranges. The unescaped
-            // char/byte is not used. For simplicity, we return an arbitrary placeholder char.
-            cb(text_range + offset, unescaped_char.map(|_| ' '));
-        });
+    // NOTE: This method should only be used for highlighting ranges. The unescaped
+    // char/byte is not used. For simplicity, we return an arbitrary placeholder char.
+    fn unescape(s: &str, mut callback: impl FnMut(Range<usize>, Result<char, EscapeError>)) {
+        unescape_c_str(s, |range, _res| callback(range, Ok('_')))
     }
 }
 
@@ -323,10 +312,7 @@ pub fn value(&self) -> Result<Cow<'_, [u8]>, EscapeError> {
             MixedUnit::Char(c) => buf.extend(c.encode_utf8(&mut [0; 4]).as_bytes()),
             MixedUnit::HighByte(b) => buf.push(b),
         };
-        unescape_mixed(text, Self::MODE, &mut |char_range, unescaped| match (
-            unescaped,
-            buf.capacity() == 0,
-        ) {
+        unescape_c_str(text, |char_range, unescaped| match (unescaped, buf.capacity() == 0) {
             (Ok(u), false) => extend_unit(&mut buf, u),
             (Ok(_), true) if char_range.len() == 1 && char_range.start == prev_end => {
                 prev_end = char_range.end
diff --git a/src/tools/rust-analyzer/crates/syntax/src/validation.rs b/src/tools/rust-analyzer/crates/syntax/src/validation.rs
index 5bfeb3b..4180f9c 100644
--- a/src/tools/rust-analyzer/crates/syntax/src/validation.rs
+++ b/src/tools/rust-analyzer/crates/syntax/src/validation.rs
@@ -6,7 +6,9 @@
 
 use itertools::Itertools;
 use rowan::Direction;
-use rustc_literal_escaper::{self, EscapeError, Mode, unescape_mixed, unescape_unicode};
+use rustc_literal_escaper::{
+    EscapeError, unescape_byte, unescape_byte_str, unescape_c_str, unescape_char, unescape_str,
+};
 
 use crate::{
     AstNode, SyntaxError,
@@ -47,7 +49,7 @@ pub(crate) fn validate(root: &SyntaxNode, errors: &mut Vec<SyntaxError>) {
 }
 
 fn rustc_unescape_error_to_string(err: EscapeError) -> (&'static str, bool) {
-    use rustc_literal_escaper::EscapeError as EE;
+    use EscapeError as EE;
 
     #[rustfmt::skip]
     let err_message = match err {
@@ -142,7 +144,7 @@ fn unquote(text: &str, prefix_len: usize, end_delimiter: char) -> Option<&str> {
         ast::LiteralKind::String(s) => {
             if !s.is_raw() {
                 if let Some(without_quotes) = unquote(text, 1, '"') {
-                    unescape_unicode(without_quotes, Mode::Str, &mut |range, char| {
+                    unescape_str(without_quotes, |range, char| {
                         if let Err(err) = char {
                             push_err(1, range.start, err);
                         }
@@ -153,7 +155,7 @@ fn unquote(text: &str, prefix_len: usize, end_delimiter: char) -> Option<&str> {
         ast::LiteralKind::ByteString(s) => {
             if !s.is_raw() {
                 if let Some(without_quotes) = unquote(text, 2, '"') {
-                    unescape_unicode(without_quotes, Mode::ByteStr, &mut |range, char| {
+                    unescape_byte_str(without_quotes, |range, char| {
                         if let Err(err) = char {
                             push_err(1, range.start, err);
                         }
@@ -164,7 +166,7 @@ fn unquote(text: &str, prefix_len: usize, end_delimiter: char) -> Option<&str> {
         ast::LiteralKind::CString(s) => {
             if !s.is_raw() {
                 if let Some(without_quotes) = unquote(text, 2, '"') {
-                    unescape_mixed(without_quotes, Mode::CStr, &mut |range, char| {
+                    unescape_c_str(without_quotes, |range, char| {
                         if let Err(err) = char {
                             push_err(1, range.start, err);
                         }
@@ -174,20 +176,16 @@ fn unquote(text: &str, prefix_len: usize, end_delimiter: char) -> Option<&str> {
         }
         ast::LiteralKind::Char(_) => {
             if let Some(without_quotes) = unquote(text, 1, '\'') {
-                unescape_unicode(without_quotes, Mode::Char, &mut |range, char| {
-                    if let Err(err) = char {
-                        push_err(1, range.start, err);
-                    }
-                });
+                if let Err(err) = unescape_char(without_quotes) {
+                    push_err(1, 0, err);
+                }
             }
         }
         ast::LiteralKind::Byte(_) => {
             if let Some(without_quotes) = unquote(text, 2, '\'') {
-                unescape_unicode(without_quotes, Mode::Byte, &mut |range, char| {
-                    if let Err(err) = char {
-                        push_err(2, range.start, err);
-                    }
-                });
+                if let Err(err) = unescape_byte(without_quotes) {
+                    push_err(2, 0, err);
+                }
             }
         }
         ast::LiteralKind::IntNumber(_)
diff --git a/src/tools/rust-analyzer/crates/test-utils/Cargo.toml b/src/tools/rust-analyzer/crates/test-utils/Cargo.toml
index c27e850..6d1930aa 100644
--- a/src/tools/rust-analyzer/crates/test-utils/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/test-utils/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 # Avoid adding deps here, this crate is widely used in tests it should compile fast!
diff --git a/src/tools/rust-analyzer/crates/test-utils/src/minicore.rs b/src/tools/rust-analyzer/crates/test-utils/src/minicore.rs
index d13a81d..d48063f 100644
--- a/src/tools/rust-analyzer/crates/test-utils/src/minicore.rs
+++ b/src/tools/rust-analyzer/crates/test-utils/src/minicore.rs
@@ -26,7 +26,7 @@
 //!     deref: sized
 //!     derive:
 //!     discriminant:
-//!     drop:
+//!     drop: sized
 //!     env: option
 //!     eq: sized
 //!     error: fmt
@@ -37,7 +37,7 @@
 //!     future: pin
 //!     coroutine: pin
 //!     dispatch_from_dyn: unsize, pin
-//!     hash:
+//!     hash: sized
 //!     include:
 //!     index: sized
 //!     infallible:
@@ -77,33 +77,46 @@
 
 pub mod marker {
     // region:sized
+    #[lang = "pointee_sized"]
+    #[fundamental]
+    #[rustc_specialization_trait]
+    #[rustc_coinductive]
+    pub trait PointeeSized {}
+
+    #[lang = "meta_sized"]
+    #[fundamental]
+    #[rustc_specialization_trait]
+    #[rustc_coinductive]
+    pub trait MetaSized: PointeeSized {}
+
     #[lang = "sized"]
     #[fundamental]
     #[rustc_specialization_trait]
-    pub trait Sized {}
+    #[rustc_coinductive]
+    pub trait Sized: MetaSized {}
     // endregion:sized
 
     // region:send
     pub unsafe auto trait Send {}
 
-    impl<T: ?Sized> !Send for *const T {}
-    impl<T: ?Sized> !Send for *mut T {}
+    impl<T: PointeeSized> !Send for *const T {}
+    impl<T: PointeeSized> !Send for *mut T {}
     // region:sync
-    unsafe impl<T: Sync + ?Sized> Send for &T {}
-    unsafe impl<T: Send + ?Sized> Send for &mut T {}
+    unsafe impl<T: Sync + PointeeSized> Send for &T {}
+    unsafe impl<T: Send + PointeeSized> Send for &mut T {}
     // endregion:sync
     // endregion:send
 
     // region:sync
     pub unsafe auto trait Sync {}
 
-    impl<T: ?Sized> !Sync for *const T {}
-    impl<T: ?Sized> !Sync for *mut T {}
+    impl<T: PointeeSized> !Sync for *const T {}
+    impl<T: PointeeSized> !Sync for *mut T {}
     // endregion:sync
 
     // region:unsize
     #[lang = "unsize"]
-    pub trait Unsize<T: ?Sized> {}
+    pub trait Unsize<T: PointeeSized>: PointeeSized {}
     // endregion:unsize
 
     // region:unpin
@@ -120,7 +133,7 @@ pub trait Copy: Clone {}
     // endregion:derive
 
     mod copy_impls {
-        use super::Copy;
+        use super::{Copy, PointeeSized};
 
         macro_rules! impl_copy {
             ($($t:ty)*) => {
@@ -137,9 +150,9 @@ impl Copy for $t {}
             bool char
         }
 
-        impl<T: ?Sized> Copy for *const T {}
-        impl<T: ?Sized> Copy for *mut T {}
-        impl<T: ?Sized> Copy for &T {}
+        impl<T: PointeeSized> Copy for *const T {}
+        impl<T: PointeeSized> Copy for *mut T {}
+        impl<T: PointeeSized> Copy for &T {}
         impl Copy for ! {}
     }
     // endregion:copy
@@ -151,7 +164,7 @@ pub trait Tuple {}
 
     // region:phantom_data
     #[lang = "phantom_data"]
-    pub struct PhantomData<T: ?Sized>;
+    pub struct PhantomData<T: PointeeSized>;
     // endregion:phantom_data
 
     // region:discriminant
@@ -206,9 +219,11 @@ fn default() -> Self {
 
 // region:hash
 pub mod hash {
+    use crate::marker::PointeeSized;
+
     pub trait Hasher {}
 
-    pub trait Hash {
+    pub trait Hash: PointeeSized {
         fn hash<H: Hasher>(&self, state: &mut H);
     }
 
@@ -221,10 +236,11 @@ pub trait Hash {
 
 // region:cell
 pub mod cell {
+    use crate::marker::PointeeSized;
     use crate::mem;
 
     #[lang = "unsafe_cell"]
-    pub struct UnsafeCell<T: ?Sized> {
+    pub struct UnsafeCell<T: PointeeSized> {
         value: T,
     }
 
@@ -238,7 +254,7 @@ pub const fn get(&self) -> *mut T {
         }
     }
 
-    pub struct Cell<T: ?Sized> {
+    pub struct Cell<T: PointeeSized> {
         value: UnsafeCell<T>,
     }
 
@@ -357,7 +373,7 @@ fn try_into(self) -> Result<U, U::Error> {
     // endregion:from
 
     // region:as_ref
-    pub trait AsRef<T: ?Sized> {
+    pub trait AsRef<T: crate::marker::PointeeSized>: crate::marker::PointeeSized {
         fn as_ref(&self) -> &T;
     }
     // endregion:as_ref
@@ -368,9 +384,11 @@ pub enum Infallible {}
 
 pub mod mem {
     // region:manually_drop
+    use crate::marker::PointeeSized;
+
     #[lang = "manually_drop"]
     #[repr(transparent)]
-    pub struct ManuallyDrop<T: ?Sized> {
+    pub struct ManuallyDrop<T: PointeeSized> {
         value: T,
     }
 
@@ -381,7 +399,7 @@ pub const fn new(value: T) -> ManuallyDrop<T> {
     }
 
     // region:deref
-    impl<T: ?Sized> crate::ops::Deref for ManuallyDrop<T> {
+    impl<T: PointeeSized> crate::ops::Deref for ManuallyDrop<T> {
         type Target = T;
         fn deref(&self) -> &T {
             &self.value
@@ -428,7 +446,7 @@ pub const fn replace<T>(dest: &mut T, src: T) -> T {
 pub mod ptr {
     // region:drop
     #[lang = "drop_in_place"]
-    pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
+    pub unsafe fn drop_in_place<T: crate::marker::PointeeSized>(to_drop: *mut T) {
         unsafe { drop_in_place(to_drop) }
     }
     pub const unsafe fn read<T>(src: *const T) -> T {
@@ -444,7 +462,7 @@ pub unsafe fn drop_in_place<T: ?Sized>(to_drop: *mut T) {
     // region:pointee
     #[lang = "pointee_trait"]
     #[rustc_deny_explicit_impl(implement_via_object = false)]
-    pub trait Pointee {
+    pub trait Pointee: crate::marker::PointeeSized {
         #[lang = "metadata_type"]
         type Metadata: Copy + Send + Sync + Ord + Hash + Unpin;
     }
@@ -452,12 +470,14 @@ pub trait Pointee {
     // region:non_null
     #[rustc_layout_scalar_valid_range_start(1)]
     #[rustc_nonnull_optimization_guaranteed]
-    pub struct NonNull<T: ?Sized> {
+    pub struct NonNull<T: crate::marker::PointeeSized> {
         pointer: *const T,
     }
     // region:coerce_unsized
-    impl<T: ?Sized, U: ?Sized> crate::ops::CoerceUnsized<NonNull<U>> for NonNull<T> where
-        T: crate::marker::Unsize<U>
+    impl<T: crate::marker::PointeeSized, U: crate::marker::PointeeSized>
+        crate::ops::CoerceUnsized<NonNull<U>> for NonNull<T>
+    where
+        T: crate::marker::Unsize<U>,
     {
     }
     // endregion:coerce_unsized
@@ -478,42 +498,44 @@ impl<T: ?Sized, U: ?Sized> crate::ops::CoerceUnsized<NonNull<U>> for NonNull<T>
 pub mod ops {
     // region:coerce_unsized
     mod unsize {
-        use crate::marker::Unsize;
+        use crate::marker::{PointeeSized, Unsize};
 
         #[lang = "coerce_unsized"]
-        pub trait CoerceUnsized<T: ?Sized> {}
+        pub trait CoerceUnsized<T> {}
 
-        impl<'a, T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<&'a mut U> for &'a mut T {}
-        impl<'a, 'b: 'a, T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<&'a U> for &'b mut T {}
-        impl<'a, T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<*mut U> for &'a mut T {}
-        impl<'a, T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<*const U> for &'a mut T {}
+        impl<'a, T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<&'a mut U> for &'a mut T {}
+        impl<'a, 'b: 'a, T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<&'a U> for &'b mut T {}
+        impl<'a, T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<*mut U> for &'a mut T {}
+        impl<'a, T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<*const U> for &'a mut T {}
 
-        impl<'a, 'b: 'a, T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<&'a U> for &'b T {}
-        impl<'a, T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<*const U> for &'a T {}
+        impl<'a, 'b: 'a, T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<&'a U> for &'b T {}
+        impl<'a, T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<*const U> for &'a T {}
 
-        impl<T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<*mut U> for *mut T {}
-        impl<T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<*const U> for *mut T {}
-        impl<T: ?Sized + Unsize<U>, U: ?Sized> CoerceUnsized<*const U> for *const T {}
+        impl<T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<*mut U> for *mut T {}
+        impl<T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<*const U> for *mut T {}
+        impl<T: PointeeSized + Unsize<U>, U: PointeeSized> CoerceUnsized<*const U> for *const T {}
     }
     pub use self::unsize::CoerceUnsized;
     // endregion:coerce_unsized
 
     // region:deref
     mod deref {
+        use crate::marker::PointeeSized;
+
         #[lang = "deref"]
-        pub trait Deref {
+        pub trait Deref: PointeeSized {
             #[lang = "deref_target"]
             type Target: ?Sized;
             fn deref(&self) -> &Self::Target;
         }
 
-        impl<T: ?Sized> Deref for &T {
+        impl<T: PointeeSized> Deref for &T {
             type Target = T;
             fn deref(&self) -> &T {
                 loop {}
             }
         }
-        impl<T: ?Sized> Deref for &mut T {
+        impl<T: PointeeSized> Deref for &mut T {
             type Target = T;
             fn deref(&self) -> &T {
                 loop {}
@@ -521,19 +543,19 @@ fn deref(&self) -> &T {
         }
         // region:deref_mut
         #[lang = "deref_mut"]
-        pub trait DerefMut: Deref {
+        pub trait DerefMut: Deref + PointeeSized {
             fn deref_mut(&mut self) -> &mut Self::Target;
         }
         // endregion:deref_mut
 
         // region:receiver
         #[lang = "receiver"]
-        pub trait Receiver {
+        pub trait Receiver: PointeeSized {
             #[lang = "receiver_target"]
             type Target: ?Sized;
         }
 
-        impl<P: ?Sized, T: ?Sized> Receiver for P
+        impl<P: PointeeSized, T: PointeeSized> Receiver for P
         where
             P: Deref<Target = T>,
         {
@@ -686,7 +708,7 @@ mod impls {
             #[rustc_const_unstable(feature = "const_fn_trait_ref_impls", issue = "101803")]
             impl<A: Tuple, F: ?Sized> const Fn<A> for &F
             where
-                F: ~const Fn<A>,
+                F: [const] Fn<A>,
             {
                 extern "rust-call" fn call(&self, args: A) -> F::Output {
                     (**self).call(args)
@@ -697,7 +719,7 @@ extern "rust-call" fn call(&self, args: A) -> F::Output {
             #[rustc_const_unstable(feature = "const_fn_trait_ref_impls", issue = "101803")]
             impl<A: Tuple, F: ?Sized> const FnMut<A> for &F
             where
-                F: ~const Fn<A>,
+                F: [const] Fn<A>,
             {
                 extern "rust-call" fn call_mut(&mut self, args: A) -> F::Output {
                     (**self).call(args)
@@ -708,7 +730,7 @@ extern "rust-call" fn call_mut(&mut self, args: A) -> F::Output {
             #[rustc_const_unstable(feature = "const_fn_trait_ref_impls", issue = "101803")]
             impl<A: Tuple, F: ?Sized> const FnOnce<A> for &F
             where
-                F: ~const Fn<A>,
+                F: [const] Fn<A>,
             {
                 type Output = F::Output;
 
@@ -721,7 +743,7 @@ extern "rust-call" fn call_once(self, args: A) -> F::Output {
             #[rustc_const_unstable(feature = "const_fn_trait_ref_impls", issue = "101803")]
             impl<A: Tuple, F: ?Sized> const FnMut<A> for &mut F
             where
-                F: ~const FnMut<A>,
+                F: [const] FnMut<A>,
             {
                 extern "rust-call" fn call_mut(&mut self, args: A) -> F::Output {
                     (*self).call_mut(args)
@@ -732,7 +754,7 @@ extern "rust-call" fn call_mut(&mut self, args: A) -> F::Output {
             #[rustc_const_unstable(feature = "const_fn_trait_ref_impls", issue = "101803")]
             impl<A: Tuple, F: ?Sized> const FnOnce<A> for &mut F
             where
-                F: ~const FnMut<A>,
+                F: [const] FnMut<A>,
             {
                 type Output = F::Output;
                 extern "rust-call" fn call_once(self, args: A) -> F::Output {
@@ -1006,18 +1028,18 @@ pub enum CoroutineState<Y, R> {
 
     // region:dispatch_from_dyn
     mod dispatch_from_dyn {
-        use crate::marker::Unsize;
+        use crate::marker::{PointeeSized, Unsize};
 
         #[lang = "dispatch_from_dyn"]
         pub trait DispatchFromDyn<T> {}
 
-        impl<'a, T: ?Sized + Unsize<U>, U: ?Sized> DispatchFromDyn<&'a U> for &'a T {}
+        impl<'a, T: PointeeSized + Unsize<U>, U: PointeeSized> DispatchFromDyn<&'a U> for &'a T {}
 
-        impl<'a, T: ?Sized + Unsize<U>, U: ?Sized> DispatchFromDyn<&'a mut U> for &'a mut T {}
+        impl<'a, T: PointeeSized + Unsize<U>, U: PointeeSized> DispatchFromDyn<&'a mut U> for &'a mut T {}
 
-        impl<T: ?Sized + Unsize<U>, U: ?Sized> DispatchFromDyn<*const U> for *const T {}
+        impl<T: PointeeSized + Unsize<U>, U: PointeeSized> DispatchFromDyn<*const U> for *const T {}
 
-        impl<T: ?Sized + Unsize<U>, U: ?Sized> DispatchFromDyn<*mut U> for *mut T {}
+        impl<T: PointeeSized + Unsize<U>, U: PointeeSized> DispatchFromDyn<*mut U> for *mut T {}
     }
     pub use self::dispatch_from_dyn::DispatchFromDyn;
     // endregion:dispatch_from_dyn
@@ -1025,15 +1047,17 @@ impl<T: ?Sized + Unsize<U>, U: ?Sized> DispatchFromDyn<*mut U> for *mut T {}
 
 // region:eq
 pub mod cmp {
+    use crate::marker::PointeeSized;
+
     #[lang = "eq"]
-    pub trait PartialEq<Rhs: ?Sized = Self> {
+    pub trait PartialEq<Rhs: PointeeSized = Self>: PointeeSized {
         fn eq(&self, other: &Rhs) -> bool;
         fn ne(&self, other: &Rhs) -> bool {
             !self.eq(other)
         }
     }
 
-    pub trait Eq: PartialEq<Self> {}
+    pub trait Eq: PartialEq<Self> + PointeeSized {}
 
     // region:derive
     #[rustc_builtin_macro]
@@ -1044,11 +1068,11 @@ pub trait Eq: PartialEq<Self> {}
 
     // region:ord
     #[lang = "partial_ord"]
-    pub trait PartialOrd<Rhs: ?Sized = Self>: PartialEq<Rhs> {
+    pub trait PartialOrd<Rhs: PointeeSized = Self>: PartialEq<Rhs> + PointeeSized {
         fn partial_cmp(&self, other: &Rhs) -> Option<Ordering>;
     }
 
-    pub trait Ord: Eq + PartialOrd<Self> {
+    pub trait Ord: Eq + PartialOrd<Self> + PointeeSized {
         fn cmp(&self, other: &Self) -> Ordering;
     }
 
@@ -1071,6 +1095,8 @@ pub enum Ordering {
 
 // region:fmt
 pub mod fmt {
+    use crate::marker::PointeeSized;
+
     pub struct Error;
     pub type Result = crate::result::Result<(), Error>;
     pub struct Formatter<'a>;
@@ -1106,10 +1132,10 @@ pub fn finish(&mut self) -> Result {
         }
     }
 
-    pub trait Debug {
+    pub trait Debug: PointeeSized {
         fn fmt(&self, f: &mut Formatter<'_>) -> Result;
     }
-    pub trait Display {
+    pub trait Display: PointeeSized {
         fn fmt(&self, f: &mut Formatter<'_>) -> Result;
     }
 
@@ -1268,7 +1294,7 @@ fn fmt(&self, _f: &mut Formatter<'_>) -> Result {
         }
     }
 
-    impl<T: Debug + ?Sized> Debug for &T {
+    impl<T: Debug + PointeeSized> Debug for &T {
         fn fmt(&self, f: &mut Formatter<'_>) -> Result {
             (&**self).fmt(f)
         }
@@ -1512,6 +1538,8 @@ fn next(&mut self) -> Option<A> {
 
     mod traits {
         mod iterator {
+            use crate::marker::PointeeSized;
+
             #[doc(notable_trait)]
             #[lang = "iterator"]
             pub trait Iterator {
@@ -1543,7 +1571,7 @@ fn filter_map<B, F>(self, _f: F) -> crate::iter::FilterMap<Self, F>
                 }
                 // endregion:iterators
             }
-            impl<I: Iterator + ?Sized> Iterator for &mut I {
+            impl<I: Iterator + PointeeSized> Iterator for &mut I {
                 type Item = I::Item;
                 fn next(&mut self) -> Option<I::Item> {
                     (**self).next()
diff --git a/src/tools/rust-analyzer/crates/toolchain/Cargo.toml b/src/tools/rust-analyzer/crates/toolchain/Cargo.toml
index 315a3a2..f561c1c 100644
--- a/src/tools/rust-analyzer/crates/toolchain/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/toolchain/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 home = "0.5.11"
diff --git a/src/tools/rust-analyzer/crates/tt/Cargo.toml b/src/tools/rust-analyzer/crates/tt/Cargo.toml
index 529fad3..82e7c24 100644
--- a/src/tools/rust-analyzer/crates/tt/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/tt/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 arrayvec.workspace = true
diff --git a/src/tools/rust-analyzer/crates/vfs-notify/Cargo.toml b/src/tools/rust-analyzer/crates/vfs-notify/Cargo.toml
index 9b32ee1..bd6c833 100644
--- a/src/tools/rust-analyzer/crates/vfs-notify/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/vfs-notify/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 tracing.workspace = true
diff --git a/src/tools/rust-analyzer/crates/vfs/Cargo.toml b/src/tools/rust-analyzer/crates/vfs/Cargo.toml
index 5461954..e8a6195 100644
--- a/src/tools/rust-analyzer/crates/vfs/Cargo.toml
+++ b/src/tools/rust-analyzer/crates/vfs/Cargo.toml
@@ -10,6 +10,7 @@
 rust-version.workspace = true
 
 [lib]
+doctest = false
 
 [dependencies]
 rustc-hash.workspace = true
diff --git a/src/tools/rust-analyzer/docs/book/src/SUMMARY.md b/src/tools/rust-analyzer/docs/book/src/SUMMARY.md
index 1f211a9..dffdae9 100644
--- a/src/tools/rust-analyzer/docs/book/src/SUMMARY.md
+++ b/src/tools/rust-analyzer/docs/book/src/SUMMARY.md
@@ -6,6 +6,7 @@
   - [rust-analyzer Binary](rust_analyzer_binary.md)
   - [Other Editors](other_editors.md)
 - [Troubleshooting](troubleshooting.md)
+  - [FAQ](faq.md)
 - [Configuration](configuration.md)
   - [Non-Cargo Based Projects](non_cargo_based_projects.md)
 - [Security](security.md)
diff --git a/src/tools/rust-analyzer/docs/book/src/configuration_generated.md b/src/tools/rust-analyzer/docs/book/src/configuration_generated.md
index 9404b14..ebac26e 100644
--- a/src/tools/rust-analyzer/docs/book/src/configuration_generated.md
+++ b/src/tools/rust-analyzer/docs/book/src/configuration_generated.md
@@ -612,6 +612,13 @@
 Controls file watching implementation.
 
 
+## rust-analyzer.highlightRelated.branchExitPoints.enable {#highlightRelated.branchExitPoints.enable}
+
+Default: `true`
+
+Enables highlighting of related return values while the cursor is on any `match`, `if`, or match arm arrow (`=>`).
+
+
 ## rust-analyzer.highlightRelated.breakPoints.enable {#highlightRelated.breakPoints.enable}
 
 Default: `true`
diff --git a/src/tools/rust-analyzer/docs/book/src/faq.md b/src/tools/rust-analyzer/docs/book/src/faq.md
new file mode 100644
index 0000000..c872033
--- /dev/null
+++ b/src/tools/rust-analyzer/docs/book/src/faq.md
@@ -0,0 +1,7 @@
+# Troubleshooting FAQ
+
+### I see a warning "Variable `None` should have snake_case name, e.g. `none`"
+
+rust-analyzer fails to resolve `None`, and thinks you are binding to a variable
+named `None`. That's usually a sign of a corrupted sysroot. Try removing and re-installing
+it: `rustup component remove rust-src` then `rustup component install rust-src`.
diff --git a/src/tools/rust-analyzer/docs/book/src/non_cargo_based_projects.md b/src/tools/rust-analyzer/docs/book/src/non_cargo_based_projects.md
index bbdb48b..befb631 100644
--- a/src/tools/rust-analyzer/docs/book/src/non_cargo_based_projects.md
+++ b/src/tools/rust-analyzer/docs/book/src/non_cargo_based_projects.md
@@ -40,6 +40,9 @@
     /// several different "sysroots" in one graph of
     /// crates.
     sysroot_src?: string;
+    /// A ProjectJson describing the crates of the sysroot.
+    sysroot_project?: ProjectJson;
+
     /// List of groups of common cfg values, to allow
     /// sharing them between crates.
     ///
diff --git a/src/tools/rust-analyzer/docs/book/src/troubleshooting.md b/src/tools/rust-analyzer/docs/book/src/troubleshooting.md
index 1b28414..a357cbe 100644
--- a/src/tools/rust-analyzer/docs/book/src/troubleshooting.md
+++ b/src/tools/rust-analyzer/docs/book/src/troubleshooting.md
@@ -1,5 +1,8 @@
 # Troubleshooting
 
+First, search the [troubleshooting FAQ](faq.html). If your problem appears
+there (and the proposed solution works for you), great! Otherwise, read on.
+
 Start with looking at the rust-analyzer version. Try **rust-analyzer:
 Show RA Version** in VS Code (using **Command Palette** feature
 typically activated by Ctrl+Shift+P) or `rust-analyzer --version` in the
diff --git a/src/tools/rust-analyzer/editors/code/package.json b/src/tools/rust-analyzer/editors/code/package.json
index 26a21c1..3cb4c21 100644
--- a/src/tools/rust-analyzer/editors/code/package.json
+++ b/src/tools/rust-analyzer/editors/code/package.json
@@ -1532,6 +1532,16 @@
             {
                 "title": "highlightRelated",
                 "properties": {
+                    "rust-analyzer.highlightRelated.branchExitPoints.enable": {
+                        "markdownDescription": "Enables highlighting of related return values while the cursor is on any `match`, `if`, or match arm arrow (`=>`).",
+                        "default": true,
+                        "type": "boolean"
+                    }
+                }
+            },
+            {
+                "title": "highlightRelated",
+                "properties": {
                     "rust-analyzer.highlightRelated.breakPoints.enable": {
                         "markdownDescription": "Enables highlighting of related references while the cursor is on `break`, `loop`, `while`, or `for` keywords.",
                         "default": true,
diff --git a/src/tools/rust-analyzer/editors/code/src/client.ts b/src/tools/rust-analyzer/editors/code/src/client.ts
index cdeea73..073ff2f 100644
--- a/src/tools/rust-analyzer/editors/code/src/client.ts
+++ b/src/tools/rust-analyzer/editors/code/src/client.ts
@@ -3,7 +3,7 @@
 import * as vscode from "vscode";
 import * as ra from "../src/lsp_ext";
 import * as Is from "vscode-languageclient/lib/common/utils/is";
-import { assert, unwrapUndefinable } from "./util";
+import { assert } from "./util";
 import * as diagnostics from "./diagnostics";
 import { WorkspaceEdit } from "vscode";
 import { type Config, prepareVSCodeConfig } from "./config";
@@ -188,11 +188,17 @@
                 context: await client.code2ProtocolConverter.asCodeActionContext(context, token),
             };
             const callback = async (
-                values: (lc.Command | lc.CodeAction)[] | null,
+                values: (lc.Command | lc.CodeAction | object)[] | null,
             ): Promise<(vscode.Command | vscode.CodeAction)[] | undefined> => {
                 if (values === null) return undefined;
                 const result: (vscode.CodeAction | vscode.Command)[] = [];
-                const groups = new Map<string, { index: number; items: vscode.CodeAction[] }>();
+                const groups = new Map<
+                    string,
+                    {
+                        primary: vscode.CodeAction;
+                        items: { label: string; arguments: lc.CodeAction }[];
+                    }
+                >();
                 for (const item of values) {
                     // In our case we expect to get code edits only from diagnostics
                     if (lc.CodeAction.is(item)) {
@@ -204,62 +210,55 @@
                         result.push(action);
                         continue;
                     }
-                    assert(
-                        isCodeActionWithoutEditsAndCommands(item),
-                        "We don't expect edits or commands here",
-                    );
-                    // eslint-disable-next-line @typescript-eslint/no-explicit-any
-                    const kind = client.protocol2CodeConverter.asCodeActionKind((item as any).kind);
-                    const action = new vscode.CodeAction(item.title, kind);
-                    // eslint-disable-next-line @typescript-eslint/no-explicit-any
-                    const group = (item as any).group;
-                    action.command = {
-                        command: "rust-analyzer.resolveCodeAction",
-                        title: item.title,
-                        arguments: [item],
-                    };
+                    assertIsCodeActionWithoutEditsAndCommands(item);
+                    const kind = client.protocol2CodeConverter.asCodeActionKind(item.kind);
+                    const group = item.group;
 
-                    // Set a dummy edit, so that VS Code doesn't try to resolve this.
-                    action.edit = new WorkspaceEdit();
+                    const mkAction = () => {
+                        const action = new vscode.CodeAction(item.title, kind);
+                        action.command = {
+                            command: "rust-analyzer.resolveCodeAction",
+                            title: item.title,
+                            arguments: [item],
+                        };
+                        // Set a dummy edit, so that VS Code doesn't try to resolve this.
+                        action.edit = new WorkspaceEdit();
+                        return action;
+                    };
 
                     if (group) {
                         let entry = groups.get(group);
                         if (!entry) {
-                            entry = { index: result.length, items: [] };
+                            entry = { primary: mkAction(), items: [] };
                             groups.set(group, entry);
-                            result.push(action);
+                        } else {
+                            entry.items.push({
+                                label: item.title,
+                                arguments: item,
+                            });
                         }
-                        entry.items.push(action);
                     } else {
-                        result.push(action);
+                        result.push(mkAction());
                     }
                 }
-                for (const [group, { index, items }] of groups) {
-                    if (items.length === 1) {
-                        const item = unwrapUndefinable(items[0]);
-                        result[index] = item;
-                    } else {
-                        const action = new vscode.CodeAction(group);
-                        const item = unwrapUndefinable(items[0]);
-                        action.kind = item.kind;
-                        action.command = {
+                for (const [group, { items, primary }] of groups) {
+                    // This group contains more than one item, so rewrite it to be a group action
+                    if (items.length !== 0) {
+                        const args = [
+                            {
+                                label: primary.title,
+                                arguments: primary.command!.arguments![0],
+                            },
+                            ...items,
+                        ];
+                        primary.title = group;
+                        primary.command = {
                             command: "rust-analyzer.applyActionGroup",
                             title: "",
-                            arguments: [
-                                items.map((item) => {
-                                    return {
-                                        label: item.title,
-                                        arguments: item.command!.arguments![0],
-                                    };
-                                }),
-                            ],
+                            arguments: [args],
                         };
-
-                        // Set a dummy edit, so that VS Code doesn't try to resolve this.
-                        action.edit = new WorkspaceEdit();
-
-                        result[index] = action;
                     }
+                    result.push(primary);
                 }
                 return result;
             };
@@ -363,17 +362,22 @@
     clear(): void {}
 }
 
-// eslint-disable-next-line @typescript-eslint/no-explicit-any
-function isCodeActionWithoutEditsAndCommands(value: any): boolean {
-    const candidate: lc.CodeAction = value;
-    return (
+function assertIsCodeActionWithoutEditsAndCommands(
+    // eslint-disable-next-line @typescript-eslint/no-explicit-any
+    candidate: any,
+): asserts candidate is lc.CodeAction & {
+    group?: string;
+} {
+    assert(
         candidate &&
-        Is.string(candidate.title) &&
-        (candidate.diagnostics === void 0 ||
-            Is.typedArray(candidate.diagnostics, lc.Diagnostic.is)) &&
-        (candidate.kind === void 0 || Is.string(candidate.kind)) &&
-        candidate.edit === void 0 &&
-        candidate.command === void 0
+            Is.string(candidate.title) &&
+            (candidate.diagnostics === undefined ||
+                Is.typedArray(candidate.diagnostics, lc.Diagnostic.is)) &&
+            (candidate.group === undefined || Is.string(candidate.group)) &&
+            (candidate.kind === undefined || Is.string(candidate.kind)) &&
+            candidate.edit === undefined &&
+            candidate.command === undefined,
+        `Expected a CodeAction without edits or commands, got: ${JSON.stringify(candidate)}`,
     );
 }
 
diff --git a/src/tools/rust-analyzer/editors/code/src/commands.ts b/src/tools/rust-analyzer/editors/code/src/commands.ts
index 3ac1a93..25b3001 100644
--- a/src/tools/rust-analyzer/editors/code/src/commands.ts
+++ b/src/tools/rust-analyzer/editors/code/src/commands.ts
@@ -1114,11 +1114,11 @@
     };
 }
 
-export function run(ctx: CtxInit): Cmd {
+export function run(ctx: CtxInit, mode?: "cursor"): Cmd {
     let prevRunnable: RunnableQuickPick | undefined;
 
     return async () => {
-        const item = await selectRunnable(ctx, prevRunnable);
+        const item = await selectRunnable(ctx, prevRunnable, false, true, mode);
         if (!item) return;
 
         item.detail = "rerun";
diff --git a/src/tools/rust-analyzer/editors/code/src/main.ts b/src/tools/rust-analyzer/editors/code/src/main.ts
index 5e50073..9962985 100644
--- a/src/tools/rust-analyzer/editors/code/src/main.ts
+++ b/src/tools/rust-analyzer/editors/code/src/main.ts
@@ -167,7 +167,7 @@
         viewCrateGraph: { enabled: commands.viewCrateGraph },
         viewFullCrateGraph: { enabled: commands.viewFullCrateGraph },
         expandMacro: { enabled: commands.expandMacro },
-        run: { enabled: commands.run },
+        run: { enabled: (ctx) => (mode?: "cursor") => commands.run(ctx, mode)() },
         copyRunCommandLine: { enabled: commands.copyRunCommandLine },
         debug: { enabled: commands.debug },
         newDebugConfig: { enabled: commands.newDebugConfig },
diff --git a/src/tools/rust-analyzer/editors/code/src/run.ts b/src/tools/rust-analyzer/editors/code/src/run.ts
index 40027cc..95166c4 100644
--- a/src/tools/rust-analyzer/editors/code/src/run.ts
+++ b/src/tools/rust-analyzer/editors/code/src/run.ts
@@ -18,10 +18,15 @@
     prevRunnable?: RunnableQuickPick,
     debuggeeOnly = false,
     showButtons: boolean = true,
+    mode?: "cursor",
 ): Promise<RunnableQuickPick | undefined> {
     const editor = ctx.activeRustEditor ?? ctx.activeCargoTomlEditor;
     if (!editor) return;
 
+    if (mode === "cursor") {
+        return selectRunnableAtCursor(ctx, editor, prevRunnable);
+    }
+
     // show a placeholder while we get the runnables from the server
     const quickPick = vscode.window.createQuickPick();
     quickPick.title = "Select Runnable";
@@ -54,6 +59,58 @@
     );
 }
 
+async function selectRunnableAtCursor(
+    ctx: CtxInit,
+    editor: RustEditor,
+    prevRunnable?: RunnableQuickPick,
+): Promise<RunnableQuickPick | undefined> {
+    const runnableQuickPicks = await getRunnables(ctx.client, editor, prevRunnable, false);
+    let runnableQuickPickAtCursor = null;
+    const cursorPosition = ctx.client.code2ProtocolConverter.asPosition(editor.selection.active);
+    for (const runnableQuickPick of runnableQuickPicks) {
+        if (!runnableQuickPick.runnable.location?.targetRange) {
+            continue;
+        }
+        const runnableQuickPickRange = runnableQuickPick.runnable.location.targetRange;
+        if (
+            runnableQuickPickAtCursor?.runnable?.location?.targetRange != null &&
+            rangeContainsOtherRange(
+                runnableQuickPickRange,
+                runnableQuickPickAtCursor.runnable.location.targetRange,
+            )
+        ) {
+            continue;
+        }
+        if (rangeContainsPosition(runnableQuickPickRange, cursorPosition)) {
+            runnableQuickPickAtCursor = runnableQuickPick;
+        }
+    }
+    if (runnableQuickPickAtCursor == null) {
+        return;
+    }
+    return Promise.resolve(runnableQuickPickAtCursor);
+}
+
+function rangeContainsPosition(range: lc.Range, position: lc.Position): boolean {
+    return (
+        (position.line > range.start.line ||
+            (position.line === range.start.line && position.character >= range.start.character)) &&
+        (position.line < range.end.line ||
+            (position.line === range.end.line && position.character <= range.end.character))
+    );
+}
+
+function rangeContainsOtherRange(range: lc.Range, otherRange: lc.Range) {
+    return (
+        (range.start.line < otherRange.start.line ||
+            (range.start.line === otherRange.start.line &&
+                range.start.character <= otherRange.start.character)) &&
+        (range.end.line > otherRange.end.line ||
+            (range.end.line === otherRange.end.line &&
+                range.end.character >= otherRange.end.character))
+    );
+}
+
 export class RunnableQuickPick implements vscode.QuickPickItem {
     public label: string;
     public description?: string | undefined;
diff --git a/src/tools/rust-analyzer/rust-version b/src/tools/rust-analyzer/rust-version
index a454087..9027932 100644
--- a/src/tools/rust-analyzer/rust-version
+++ b/src/tools/rust-analyzer/rust-version
@@ -1 +1 @@
-27733d46d79f4eb92e240fbba502c43022665735
+ad3b7257615c28aaf8212a189ec032b8af75de51
diff --git a/src/tools/rust-installer/README.md b/src/tools/rust-installer/README.md
index 99d8e5c..505ffe4 100644
--- a/src/tools/rust-installer/README.md
+++ b/src/tools/rust-installer/README.md
@@ -51,7 +51,7 @@
 
 * Make install.sh not have to be customized, pull it's data from a
   config file.
-* Be more resiliant to installation failures, particularly if the disk
+* Be more resilient to installation failures, particularly if the disk
   is full.
 * Pre-install and post-uninstall scripts.
 * Allow components to depend on or contradict other components.
diff --git a/src/tools/rustfmt/src/types.rs b/src/tools/rustfmt/src/types.rs
index 7ec1032..dd15158 100644
--- a/src/tools/rustfmt/src/types.rs
+++ b/src/tools/rustfmt/src/types.rs
@@ -835,12 +835,6 @@ fn rewrite_result(&self, context: &RewriteContext<'_>, shape: Shape) -> RewriteR
                             .max_width_error(shape.width, self.span())?;
                         (shape, "dyn ")
                     }
-                    ast::TraitObjectSyntax::DynStar => {
-                        let shape = shape
-                            .offset_left(5)
-                            .max_width_error(shape.width, self.span())?;
-                        (shape, "dyn* ")
-                    }
                     ast::TraitObjectSyntax::None => (shape, ""),
                 };
                 let mut res = bounds.rewrite_result(context, shape)?;
diff --git a/src/tools/rustfmt/tests/target/issue_5542.rs b/src/tools/rustfmt/tests/target/issue_5542.rs
deleted file mode 100644
index 730bb7b..0000000
--- a/src/tools/rustfmt/tests/target/issue_5542.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use core::fmt::Debug;
-
-fn main() {
-    let i = 42;
-    let dyn_i = i as dyn* Debug;
-    dbg!(dyn_i);
-}
diff --git a/src/tools/test-float-parse/src/lib.rs b/src/tools/test-float-parse/src/lib.rs
index f590149..0bd4878 100644
--- a/src/tools/test-float-parse/src/lib.rs
+++ b/src/tools/test-float-parse/src/lib.rs
@@ -119,7 +119,6 @@ pub fn register_tests(cfg: &Config) -> Vec<TestInfo> {
 
     // Register normal generators for all floats.
 
-    #[cfg(not(bootstrap))]
     #[cfg(target_has_reliable_f16)]
     register_float::<f16>(&mut tests, cfg);
     register_float::<f32>(&mut tests, cfg);
diff --git a/src/tools/test-float-parse/src/traits.rs b/src/tools/test-float-parse/src/traits.rs
index 16484f8..65a8721 100644
--- a/src/tools/test-float-parse/src/traits.rs
+++ b/src/tools/test-float-parse/src/traits.rs
@@ -170,7 +170,6 @@ fn constants() -> &'static Constants {
 
 impl_float!(f32, u32; f64, u64);
 
-#[cfg(not(bootstrap))]
 #[cfg(target_has_reliable_f16)]
 impl_float!(f16, u16);
 
diff --git a/src/tools/tidy/src/issues.txt b/src/tools/tidy/src/issues.txt
index 7e27e02..49b4287 100644
--- a/src/tools/tidy/src/issues.txt
+++ b/src/tools/tidy/src/issues.txt
@@ -930,7 +930,6 @@
 ui/dst/issue-90528-unsizing-suggestion-4.rs
 ui/dyn-keyword/issue-5153.rs
 ui/dyn-keyword/issue-56327-dyn-trait-in-macro-is-okay.rs
-ui/dyn-star/issue-102430.rs
 ui/empty/issue-37026.rs
 ui/entry-point/issue-118772.rs
 ui/enum-discriminant/auxiliary/issue-41394.rs
@@ -1368,7 +1367,6 @@
 ui/intrinsics/issue-28575.rs
 ui/intrinsics/issue-84297-reifying-copy.rs
 ui/invalid/issue-114435-layout-type-err.rs
-ui/issue-11881.rs
 ui/issue-15924.rs
 ui/issue-16822.rs
 ui/issues-71798.rs
@@ -2847,7 +2845,6 @@
 ui/macros/issue-99261.rs
 ui/macros/issue-99265.rs
 ui/macros/issue-99907.rs
-ui/macros/rfc-3086-metavar-expr/issue-111904.rs
 ui/malformed/issue-107423-unused-delim-only-one-no-pair.rs
 ui/malformed/issue-69341-malformed-derive-inert.rs
 ui/marker_trait_attr/issue-61651-type-mismatch.rs
diff --git a/tests/codegen/align-fn.rs b/tests/codegen/align-fn.rs
index 267da06..90073ff 100644
--- a/tests/codegen/align-fn.rs
+++ b/tests/codegen/align-fn.rs
@@ -1,10 +1,10 @@
-//@ compile-flags: -C no-prepopulate-passes -Z mir-opt-level=0
+//@ compile-flags: -C no-prepopulate-passes -Z mir-opt-level=0 -Clink-dead-code
 
 #![crate_type = "lib"]
 #![feature(fn_align)]
 
 // CHECK: align 16
-#[no_mangle]
+#[unsafe(no_mangle)]
 #[align(16)]
 pub fn fn_align() {}
 
@@ -12,12 +12,12 @@ pub fn fn_align() {}
 
 impl A {
     // CHECK: align 16
-    #[no_mangle]
+    #[unsafe(no_mangle)]
     #[align(16)]
     pub fn method_align(self) {}
 
     // CHECK: align 16
-    #[no_mangle]
+    #[unsafe(no_mangle)]
     #[align(16)]
     pub fn associated_fn() {}
 }
@@ -25,46 +25,94 @@ pub fn associated_fn() {}
 trait T: Sized {
     fn trait_fn() {}
 
-    // CHECK: align 32
-    #[align(32)]
     fn trait_method(self) {}
+
+    #[align(8)]
+    fn trait_method_inherit_low(self);
+
+    #[align(32)]
+    fn trait_method_inherit_high(self);
+
+    #[align(32)]
+    fn trait_method_inherit_default(self) {}
+
+    #[align(4)]
+    #[align(128)]
+    #[align(8)]
+    fn inherit_highest(self) {}
 }
 
 impl T for A {
-    // CHECK: align 16
-    #[no_mangle]
+    // CHECK-LABEL: trait_fn
+    // CHECK-SAME: align 16
+    #[unsafe(no_mangle)]
     #[align(16)]
     fn trait_fn() {}
 
-    // CHECK: align 16
-    #[no_mangle]
+    // CHECK-LABEL: trait_method
+    // CHECK-SAME: align 16
+    #[unsafe(no_mangle)]
     #[align(16)]
     fn trait_method(self) {}
+
+    // The prototype's align is ignored because the align here is higher.
+    // CHECK-LABEL: trait_method_inherit_low
+    // CHECK-SAME: align 16
+    #[unsafe(no_mangle)]
+    #[align(16)]
+    fn trait_method_inherit_low(self) {}
+
+    // The prototype's align is used because it is higher.
+    // CHECK-LABEL: trait_method_inherit_high
+    // CHECK-SAME: align 32
+    #[unsafe(no_mangle)]
+    #[align(16)]
+    fn trait_method_inherit_high(self) {}
+
+    // The prototype's align inherited.
+    // CHECK-LABEL: trait_method_inherit_default
+    // CHECK-SAME: align 32
+    #[unsafe(no_mangle)]
+    fn trait_method_inherit_default(self) {}
+
+    // The prototype's highest align inherited.
+    // CHECK-LABEL: inherit_highest
+    // CHECK-SAME: align 128
+    #[unsafe(no_mangle)]
+    #[align(32)]
+    #[align(64)]
+    fn inherit_highest(self) {}
 }
 
-impl T for () {}
-
-pub fn foo() {
-    ().trait_method();
+trait HasDefaultImpl: Sized {
+    // CHECK-LABEL: inherit_from_default_method
+    // CHECK-LABEL: inherit_from_default_method
+    // CHECK-SAME: align 32
+    #[align(32)]
+    fn inherit_from_default_method(self) {}
 }
 
+pub struct InstantiateDefaultMethods;
+
+impl HasDefaultImpl for InstantiateDefaultMethods {}
+
 // CHECK-LABEL: align_specified_twice_1
 // CHECK-SAME: align 64
-#[no_mangle]
+#[unsafe(no_mangle)]
 #[align(32)]
 #[align(64)]
 pub fn align_specified_twice_1() {}
 
 // CHECK-LABEL: align_specified_twice_2
 // CHECK-SAME: align 128
-#[no_mangle]
+#[unsafe(no_mangle)]
 #[align(128)]
 #[align(32)]
 pub fn align_specified_twice_2() {}
 
 // CHECK-LABEL: align_specified_twice_3
 // CHECK-SAME: align 256
-#[no_mangle]
+#[unsafe(no_mangle)]
 #[align(32)]
 #[align(256)]
 pub fn align_specified_twice_3() {}
diff --git a/tests/codegen/function-arguments.rs b/tests/codegen/function-arguments.rs
index f0708a7..c8cd852 100644
--- a/tests/codegen/function-arguments.rs
+++ b/tests/codegen/function-arguments.rs
@@ -1,7 +1,6 @@
 //@ compile-flags: -Copt-level=3 -C no-prepopulate-passes
 #![crate_type = "lib"]
 #![feature(rustc_attrs)]
-#![feature(dyn_star)]
 #![feature(allocator_api)]
 
 use std::marker::PhantomPinned;
@@ -277,11 +276,3 @@ pub fn enum_id_1(x: Option<Result<u16, u16>>) -> Option<Result<u16, u16>> {
 pub fn enum_id_2(x: Option<u8>) -> Option<u8> {
     x
 }
-
-// CHECK: { ptr, {{.+}} } @dyn_star(ptr noundef %x.0, {{.+}} noalias noundef readonly align {{.*}} dereferenceable({{.*}}) %x.1)
-// Expect an ABI something like `{ {}*, [3 x i64]* }`, but that's hard to match on generically,
-// so do like the `trait_box` test and just match on `{{.+}}` for the vtable.
-#[no_mangle]
-pub fn dyn_star(x: dyn* Drop) -> dyn* Drop {
-    x
-}
diff --git a/tests/crashes/116979.rs b/tests/crashes/116979.rs
deleted file mode 100644
index 28bbc97..0000000
--- a/tests/crashes/116979.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-//@ known-bug: #116979
-//@ compile-flags: -Csymbol-mangling-version=v0
-//@ needs-rustc-debug-assertions
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Display;
-
-pub fn require_dyn_star_display(_: dyn* Display) {}
-
-fn main() {
-    require_dyn_star_display(1usize);
-}
diff --git a/tests/crashes/119694.rs b/tests/crashes/119694.rs
deleted file mode 100644
index f655ea1..0000000
--- a/tests/crashes/119694.rs
+++ /dev/null
@@ -1,18 +0,0 @@
-//@ known-bug: #119694
-#![feature(dyn_star)]
-
-trait Trait {
-    fn foo(self);
-}
-
-impl Trait for usize {
-    fn foo(self) {}
-}
-
-fn bar(x: dyn* Trait) {
-    x.foo();
-}
-
-fn main() {
-    bar(0usize);
-}
diff --git a/tests/crashes/132882.rs b/tests/crashes/132882.rs
deleted file mode 100644
index 6b5e4db..0000000
--- a/tests/crashes/132882.rs
+++ /dev/null
@@ -1,13 +0,0 @@
-//@ known-bug: #132882
-
-use std::ops::Add;
-
-pub trait Numoid
-where
-    for<N: Numoid> &'a Self: Add<Self>,
-{
-}
-
-pub fn compute<N: Numoid>(a: N) -> N {
-    &a + a
-}
diff --git a/tests/incremental/issue-54242.rs b/tests/incremental/issue-54242.rs
index 9fa5363..17bbd61 100644
--- a/tests/incremental/issue-54242.rs
+++ b/tests/incremental/issue-54242.rs
@@ -14,7 +14,7 @@ impl Tr for str {
     type Arr = [u8; 8];
     #[cfg(cfail)]
     type Arr = [u8; Self::C];
-    //[cfail]~^ ERROR cycle detected when evaluating type-level constant
+    //[cfail]~^ ERROR cycle detected when caching mir
 }
 
 fn main() {}
diff --git a/tests/run-make/short-ice/rmake.rs b/tests/run-make/short-ice/rmake.rs
index 483def6..dbe0f69 100644
--- a/tests/run-make/short-ice/rmake.rs
+++ b/tests/run-make/short-ice/rmake.rs
@@ -5,9 +5,12 @@
 // See https://github.com/rust-lang/rust/issues/107910
 
 //@ needs-target-std
-//@ ignore-i686-pc-windows-msvc
-// Reason: the assert_eq! on line 37 fails, almost seems like it missing debug info?
-// Haven't been able to reproduce locally, but it happens on CI.
+//@ ignore-windows-msvc
+//
+// - FIXME(#143198): On `i686-pc-windows-msvc`: the assert_eq! on line 37 fails, almost seems like
+//   it missing debug info? Haven't been able to reproduce locally, but it happens on CI.
+// - FIXME(#143198): On `x86_64-pc-windows-msvc`: full backtrace sometimes do not contain matching
+//   count of short backtrace markers (e.g. 5x end marker, but 3x start marker).
 
 use run_make_support::rustc;
 
diff --git a/tests/rustdoc-json/attrs/link_section_2021.rs b/tests/rustdoc-json/attrs/link_section_2021.rs
new file mode 100644
index 0000000..a1312f4
--- /dev/null
+++ b/tests/rustdoc-json/attrs/link_section_2021.rs
@@ -0,0 +1,6 @@
+//@ edition: 2021
+#![no_std]
+
+//@ is "$.index[?(@.name=='example')].attrs" '["#[link_section = \".text\"]"]'
+#[link_section = ".text"]
+pub extern "C" fn example() {}
diff --git a/tests/rustdoc-json/attrs/link_section_2024.rs b/tests/rustdoc-json/attrs/link_section_2024.rs
new file mode 100644
index 0000000..edb0284
--- /dev/null
+++ b/tests/rustdoc-json/attrs/link_section_2024.rs
@@ -0,0 +1,9 @@
+//@ edition: 2024
+#![no_std]
+
+// Since the 2024 edition the link_section attribute must use the unsafe qualification.
+// However, the unsafe qualification is not shown by rustdoc.
+
+//@ is "$.index[?(@.name=='example')].attrs" '["#[link_section = \".text\"]"]'
+#[unsafe(link_section = ".text")]
+pub extern "C" fn example() {}
diff --git a/tests/rustdoc-ui/invalid_infered_static_and_const.stderr b/tests/rustdoc-ui/invalid_infered_static_and_const.stderr
index 4010202..3e11682 100644
--- a/tests/rustdoc-ui/invalid_infered_static_and_const.stderr
+++ b/tests/rustdoc-ui/invalid_infered_static_and_const.stderr
@@ -1,10 +1,10 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for constant items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
   --> $DIR/invalid_infered_static_and_const.rs:1:24
    |
 LL | const FOO: dyn Fn() -> _ = "";
    |                        ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for static items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for statics
   --> $DIR/invalid_infered_static_and_const.rs:2:25
    |
 LL | static BOO: dyn Fn() -> _ = "";
diff --git a/tests/ui-fulldeps/stable-mir/check_allocation.rs b/tests/ui-fulldeps/stable-mir/check_allocation.rs
index 692c24f..64194e7 100644
--- a/tests/ui-fulldeps/stable-mir/check_allocation.rs
+++ b/tests/ui-fulldeps/stable-mir/check_allocation.rs
@@ -19,12 +19,6 @@
 extern crate rustc_interface;
 extern crate stable_mir;
 
-use stable_mir::crate_def::CrateDef;
-use stable_mir::mir::alloc::GlobalAlloc;
-use stable_mir::mir::mono::{Instance, InstanceKind, StaticDef};
-use stable_mir::mir::{Body, TerminatorKind};
-use stable_mir::ty::{Allocation, ConstantKind, RigidTy, TyKind};
-use stable_mir::{CrateItem, CrateItems, ItemKind};
 use std::ascii::Char;
 use std::assert_matches::assert_matches;
 use std::cmp::{max, min};
@@ -33,6 +27,13 @@
 use std::io::Write;
 use std::ops::ControlFlow;
 
+use stable_mir::crate_def::CrateDef;
+use stable_mir::mir::Body;
+use stable_mir::mir::alloc::GlobalAlloc;
+use stable_mir::mir::mono::{Instance, StaticDef};
+use stable_mir::ty::{Allocation, ConstantKind};
+use stable_mir::{CrateItem, CrateItems, ItemKind};
+
 const CRATE_NAME: &str = "input";
 
 /// This function uses the Stable MIR APIs to get information about the test crate.
@@ -44,7 +45,6 @@ fn test_stable_mir() -> ControlFlow<()> {
     check_len(*get_item(&items, (ItemKind::Static, "LEN")).unwrap());
     check_cstr(*get_item(&items, (ItemKind::Static, "C_STR")).unwrap());
     check_other_consts(*get_item(&items, (ItemKind::Fn, "other_consts")).unwrap());
-    check_type_id(*get_item(&items, (ItemKind::Fn, "check_type_id")).unwrap());
     ControlFlow::Continue(())
 }
 
@@ -107,7 +107,9 @@ fn check_other_consts(item: CrateItem) {
     // Instance body will force constant evaluation.
     let body = Instance::try_from(item).unwrap().body().unwrap();
     let assigns = collect_consts(&body);
-    assert_eq!(assigns.len(), 8);
+    assert_eq!(assigns.len(), 10);
+    let mut char_id = None;
+    let mut bool_id = None;
     for (name, alloc) in assigns {
         match name.as_str() {
             "_max_u128" => {
@@ -149,35 +151,21 @@ fn check_other_consts(item: CrateItem) {
                 assert_eq!(max(first, second) as u32, u32::MAX);
                 assert_eq!(min(first, second), 10);
             }
+            "_bool_id" => {
+                bool_id = Some(alloc);
+            }
+            "_char_id" => {
+                char_id = Some(alloc);
+            }
             _ => {
                 unreachable!("{name} -- {alloc:?}")
             }
         }
     }
-}
-
-/// Check that we can retrieve the type id of char and bool, and that they have different values.
-fn check_type_id(item: CrateItem) {
-    let body = Instance::try_from(item).unwrap().body().unwrap();
-    let mut ids: Vec<u128> = vec![];
-    for term in body.blocks.iter().map(|bb| &bb.terminator) {
-        match &term.kind {
-            TerminatorKind::Call { func, destination, .. } => {
-                let TyKind::RigidTy(ty) = func.ty(body.locals()).unwrap().kind() else {
-                    unreachable!()
-                };
-                let RigidTy::FnDef(def, args) = ty else { unreachable!() };
-                let instance = Instance::resolve(def, &args).unwrap();
-                assert_eq!(instance.kind, InstanceKind::Intrinsic);
-                let dest_ty = destination.ty(body.locals()).unwrap();
-                let alloc = instance.try_const_eval(dest_ty).unwrap();
-                ids.push(alloc.read_uint().unwrap());
-            }
-            _ => { /* Do nothing */ }
-        }
-    }
-    assert_eq!(ids.len(), 2);
-    assert_ne!(ids[0], ids[1]);
+    let bool_id = bool_id.unwrap();
+    let char_id = char_id.unwrap();
+    // FIXME(stable_mir): add `read_ptr` to `Allocation`
+    assert_ne!(bool_id, char_id);
 }
 
 /// Collects all the constant assignments.
@@ -235,6 +223,7 @@ fn generate_input(path: &str) -> std::io::Result<()> {
         file,
         r#"
     #![feature(core_intrinsics)]
+    #![expect(internal_features)]
     use std::intrinsics::type_id;
 
     static LEN: usize = 2;
@@ -254,11 +243,8 @@ fn other_consts() {{
         let _ptr = &BAR;
         let _null_ptr: *const u8 = NULL;
         let _tuple = TUPLE;
-    }}
-
-    fn check_type_id() {{
-        let _char_id = type_id::<char>();
-        let _bool_id = type_id::<bool>();
+        let _char_id = const {{ type_id::<char>() }};
+        let _bool_id = const {{ type_id::<bool>() }};
     }}
 
     pub fn main() {{
diff --git a/tests/ui/SUMMARY.md b/tests/ui/SUMMARY.md
index 72b673d..8de74d4 100644
--- a/tests/ui/SUMMARY.md
+++ b/tests/ui/SUMMARY.md
@@ -484,10 +484,6 @@
 
 See [`dyn` keyword](https://doc.rust-lang.org/std/keyword.dyn.html).
 
-## `tests/ui/dyn-star/`: `dyn*`, Sized `dyn`, `#![feature(dyn_star)]`
-
-See [Tracking issue for dyn-star #102425](https://github.com/rust-lang/rust/issues/102425).
-
 ## `tests/ui/editions/`: Rust edition-specific peculiarities
 
 These tests run in specific Rust editions, such as Rust 2015 or Rust 2018, and check errors and functionality related to specific now-deprecated idioms and features.
diff --git a/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.rs b/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.rs
index a718eb2..e583b12 100644
--- a/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.rs
+++ b/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.rs
@@ -12,7 +12,7 @@ fn take(
         K = { () }
     >,
 ) {}
-//~^^^^^^ ERROR implementation of `Project` is not general enough
+//~^^^^^ ERROR implementation of `Project` is not general enough
 //~^^^^ ERROR higher-ranked subtype error
 //~| ERROR higher-ranked subtype error
 
diff --git a/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.stderr b/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.stderr
index 967814c..42e084f 100644
--- a/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.stderr
+++ b/tests/ui/associated-consts/assoc-const-eq-bound-var-in-ty-not-wf.stderr
@@ -13,10 +13,14 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: implementation of `Project` is not general enough
-  --> $DIR/assoc-const-eq-bound-var-in-ty-not-wf.rs:9:4
+  --> $DIR/assoc-const-eq-bound-var-in-ty-not-wf.rs:10:13
    |
-LL | fn take(
-   |    ^^^^ implementation of `Project` is not general enough
+LL |       _: impl Trait<
+   |  _____________^
+LL | |         <<for<'a> fn(&'a str) -> &'a str as Project>::Out as Discard>::Out,
+LL | |         K = { () }
+LL | |     >,
+   | |_____^ implementation of `Project` is not general enough
    |
    = note: `Project` would have to be implemented for the type `for<'a> fn(&'a str) -> &'a str`
    = note: ...but `Project` is actually implemented for the type `fn(&'0 str) -> &'0 str`, for some specific lifetime `'0`
diff --git a/tests/ui/associated-inherent-types/issue-111879-0.stderr b/tests/ui/associated-inherent-types/issue-111879-0.stderr
index f60fd58..144f648 100644
--- a/tests/ui/associated-inherent-types/issue-111879-0.stderr
+++ b/tests/ui/associated-inherent-types/issue-111879-0.stderr
@@ -1,8 +1,8 @@
 error: overflow evaluating associated type `Carrier<'b>::Focus<i32>`
-  --> $DIR/issue-111879-0.rs:9:25
+  --> $DIR/issue-111879-0.rs:9:5
    |
 LL |     pub type Focus<T> = &'a mut for<'b> fn(Carrier<'b>::Focus<i32>);
-   |                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |     ^^^^^^^^^^^^^^^^^
 
 error: aborting due to 1 previous error
 
diff --git a/tests/ui/associated-inherent-types/normalization-overflow.stderr b/tests/ui/associated-inherent-types/normalization-overflow.stderr
index 7f991a5..05aad31 100644
--- a/tests/ui/associated-inherent-types/normalization-overflow.stderr
+++ b/tests/ui/associated-inherent-types/normalization-overflow.stderr
@@ -1,8 +1,8 @@
 error: overflow evaluating associated type `T::This`
-  --> $DIR/normalization-overflow.rs:9:17
+  --> $DIR/normalization-overflow.rs:9:5
    |
 LL |     type This = Self::This;
-   |                 ^^^^^^^^^^
+   |     ^^^^^^^^^
 
 error: aborting due to 1 previous error
 
diff --git a/tests/ui/associated-inherent-types/regionck-1.stderr b/tests/ui/associated-inherent-types/regionck-1.stderr
index 62a0086..4e0ecc3 100644
--- a/tests/ui/associated-inherent-types/regionck-1.stderr
+++ b/tests/ui/associated-inherent-types/regionck-1.stderr
@@ -1,10 +1,11 @@
 error[E0309]: the parameter type `T` may not live long enough
-  --> $DIR/regionck-1.rs:9:30
+  --> $DIR/regionck-1.rs:9:5
    |
 LL |     type NoTyOutliv<'a, T> = &'a T;
-   |                     --       ^^^^^ ...so that the reference type `&'a T` does not outlive the data it points at
-   |                     |
-   |                     the parameter type `T` must be valid for the lifetime `'a` as defined here...
+   |     ^^^^^^^^^^^^^^^^--^^^^
+   |     |               |
+   |     |               the parameter type `T` must be valid for the lifetime `'a` as defined here...
+   |     ...so that the reference type `&'a T` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |
@@ -12,10 +13,10 @@
    |                          ++++
 
 error[E0491]: in type `&'a &'b ()`, reference has a longer lifetime than the data it references
-  --> $DIR/regionck-1.rs:10:31
+  --> $DIR/regionck-1.rs:10:5
    |
 LL |     type NoReOutliv<'a, 'b> = &'a &'b ();
-   |                               ^^^^^^^^^^
+   |     ^^^^^^^^^^^^^^^^^^^^^^^
    |
 note: the pointer is valid for the lifetime `'a` as defined here
   --> $DIR/regionck-1.rs:10:21
diff --git a/tests/ui/associated-types/impl-wf-cycle-4.stderr b/tests/ui/associated-types/impl-wf-cycle-4.stderr
index c966579..fac06e6 100644
--- a/tests/ui/associated-types/impl-wf-cycle-4.stderr
+++ b/tests/ui/associated-types/impl-wf-cycle-4.stderr
@@ -1,4 +1,4 @@
-error[E0391]: cycle detected when computing normalized predicates of `<impl at $DIR/impl-wf-cycle-4.rs:5:1: 7:26>`
+error[E0391]: cycle detected when computing whether `<impl at $DIR/impl-wf-cycle-4.rs:5:1: 7:26>` has a guaranteed unsized self type
   --> $DIR/impl-wf-cycle-4.rs:5:1
    |
 LL | / impl<T> Filter for T
@@ -6,14 +6,14 @@
 LL | |     T: Fn(Self::ToMatch),
    | |_________________________^
    |
-note: ...which requires computing whether `<impl at $DIR/impl-wf-cycle-4.rs:5:1: 7:26>` has a guaranteed unsized self type...
+note: ...which requires computing normalized predicates of `<impl at $DIR/impl-wf-cycle-4.rs:5:1: 7:26>`...
   --> $DIR/impl-wf-cycle-4.rs:5:1
    |
 LL | / impl<T> Filter for T
 LL | | where
 LL | |     T: Fn(Self::ToMatch),
    | |_________________________^
-   = note: ...which again requires computing normalized predicates of `<impl at $DIR/impl-wf-cycle-4.rs:5:1: 7:26>`, completing the cycle
+   = note: ...which again requires computing whether `<impl at $DIR/impl-wf-cycle-4.rs:5:1: 7:26>` has a guaranteed unsized self type, completing the cycle
 note: cycle used when checking that `<impl at $DIR/impl-wf-cycle-4.rs:5:1: 7:26>` is well-formed
   --> $DIR/impl-wf-cycle-4.rs:5:1
    |
diff --git a/tests/ui/associated-types/issue-38821.rs b/tests/ui/associated-types/issue-38821.rs
index c9be136..60d3b22 100644
--- a/tests/ui/associated-types/issue-38821.rs
+++ b/tests/ui/associated-types/issue-38821.rs
@@ -32,16 +32,16 @@ pub trait Column: Expression {}
 //~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
 //~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
 //~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
 pub enum ColumnInsertValue<Col, Expr> where
 //~^ ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
     Col: Column,
     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>,
+//~^ ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+//~| ERROR the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
 {
     Expression(Col, Expr),
     Default(Col),
diff --git a/tests/ui/associated-types/issue-38821.stderr b/tests/ui/associated-types/issue-38821.stderr
index 8a19142..b03a3cf 100644
--- a/tests/ui/associated-types/issue-38821.stderr
+++ b/tests/ui/associated-types/issue-38821.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:40:1
+  --> $DIR/issue-38821.rs:35:1
    |
 LL | pub enum ColumnInsertValue<Col, Expr> where
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
@@ -17,16 +17,10 @@
    |                                                                         +++++++++++++++++++++++++++++++++++++
 
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:40:1
+  --> $DIR/issue-38821.rs:38:22
    |
-LL | / pub enum ColumnInsertValue<Col, Expr> where
-LL | |
-LL | |
-LL | |     Col: Column,
-...  |
-LL | |     Default(Col),
-LL | | }
-   | |_^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
+LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>,
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
    |
 note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
   --> $DIR/issue-38821.rs:9:18
@@ -71,25 +65,6 @@
    |         -------  ^^^^^^^^^^^^     ^
    |         |
    |         unsatisfied trait bound introduced here
-   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
-help: consider further restricting the associated type
-   |
-LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>, <Col as Expression>::SqlType: NotNull,
-   |                                                                       +++++++++++++++++++++++++++++++++++++++
-
-error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:23:10
-   |
-LL | #[derive(Debug, Copy, Clone)]
-   |          ^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
-   |
-note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
-  --> $DIR/issue-38821.rs:9:18
-   |
-LL | impl<T: NotNull> IntoNullable for T {
-   |         -------  ^^^^^^^^^^^^     ^
-   |         |
-   |         unsatisfied trait bound introduced here
 
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
   --> $DIR/issue-38821.rs:23:10
@@ -107,10 +82,10 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:23:17
+  --> $DIR/issue-38821.rs:38:22
    |
-LL | #[derive(Debug, Copy, Clone)]
-   |                 ^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
+LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>,
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
    |
 note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
   --> $DIR/issue-38821.rs:9:18
@@ -137,7 +112,24 @@
    |         -------  ^^^^^^^^^^^^     ^
    |         |
    |         unsatisfied trait bound introduced here
-   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+help: consider further restricting the associated type
+   |
+LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>, <Col as Expression>::SqlType: NotNull,
+   |                                                                       +++++++++++++++++++++++++++++++++++++++
+
+error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+  --> $DIR/issue-38821.rs:38:22
+   |
+LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>,
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
+   |
+note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
+  --> $DIR/issue-38821.rs:9:18
+   |
+LL | impl<T: NotNull> IntoNullable for T {
+   |         -------  ^^^^^^^^^^^^     ^
+   |         |
+   |         unsatisfied trait bound introduced here
 help: consider further restricting the associated type
    |
 LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>, <Col as Expression>::SqlType: NotNull,
@@ -174,42 +166,41 @@
    |         -------  ^^^^^^^^^^^^     ^
    |         |
    |         unsatisfied trait bound introduced here
+
+error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+  --> $DIR/issue-38821.rs:23:23
+   |
+LL | #[derive(Debug, Copy, Clone)]
+   |                       ^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
+   |
+note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
+  --> $DIR/issue-38821.rs:9:18
+   |
+LL | impl<T: NotNull> IntoNullable for T {
+   |         -------  ^^^^^^^^^^^^     ^
+   |         |
+   |         unsatisfied trait bound introduced here
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+
+error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
+  --> $DIR/issue-38821.rs:38:22
+   |
+LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>,
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
+   |
+note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
+  --> $DIR/issue-38821.rs:9:18
+   |
+LL | impl<T: NotNull> IntoNullable for T {
+   |         -------  ^^^^^^^^^^^^     ^
+   |         |
+   |         unsatisfied trait bound introduced here
 help: consider further restricting the associated type
    |
 LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>, <Col as Expression>::SqlType: NotNull,
    |                                                                       +++++++++++++++++++++++++++++++++++++++
 
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:23:23
-   |
-LL | #[derive(Debug, Copy, Clone)]
-   |                       ^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
-   |
-note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
-  --> $DIR/issue-38821.rs:9:18
-   |
-LL | impl<T: NotNull> IntoNullable for T {
-   |         -------  ^^^^^^^^^^^^     ^
-   |         |
-   |         unsatisfied trait bound introduced here
-
-error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:23:23
-   |
-LL | #[derive(Debug, Copy, Clone)]
-   |                       ^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
-   |
-note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
-  --> $DIR/issue-38821.rs:9:18
-   |
-LL | impl<T: NotNull> IntoNullable for T {
-   |         -------  ^^^^^^^^^^^^     ^
-   |         |
-   |         unsatisfied trait bound introduced here
-   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
-
-error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
   --> $DIR/issue-38821.rs:23:10
    |
 LL | #[derive(Debug, Copy, Clone)]
@@ -225,10 +216,10 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:23:10
+  --> $DIR/issue-38821.rs:38:22
    |
-LL | #[derive(Debug, Copy, Clone)]
-   |          ^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
+LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>,
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
    |
 note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
   --> $DIR/issue-38821.rs:9:18
@@ -237,7 +228,6 @@
    |         -------  ^^^^^^^^^^^^     ^
    |         |
    |         unsatisfied trait bound introduced here
-   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
   --> $DIR/issue-38821.rs:23:23
@@ -255,10 +245,10 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error[E0277]: the trait bound `<Col as Expression>::SqlType: NotNull` is not satisfied
-  --> $DIR/issue-38821.rs:23:23
+  --> $DIR/issue-38821.rs:38:22
    |
-LL | #[derive(Debug, Copy, Clone)]
-   |                       ^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
+LL |     Expr: Expression<SqlType=<Col::SqlType as IntoNullable>::Nullable>,
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `NotNull` is not implemented for `<Col as Expression>::SqlType`
    |
 note: required for `<Col as Expression>::SqlType` to implement `IntoNullable`
   --> $DIR/issue-38821.rs:9:18
diff --git a/tests/ui/associated-types/issue-59324.rs b/tests/ui/associated-types/issue-59324.rs
index 3abe847..9d4c7cb 100644
--- a/tests/ui/associated-types/issue-59324.rs
+++ b/tests/ui/associated-types/issue-59324.rs
@@ -10,8 +10,8 @@ pub trait Service {
 
 pub trait ThriftService<Bug: NotFoo>:
 //~^ ERROR the trait bound `Bug: Foo` is not satisfied
-//~| ERROR the trait bound `Bug: Foo` is not satisfied
     Service<AssocType = <Bug as Foo>::OnlyFoo>
+//~^ ERROR the trait bound `Bug: Foo` is not satisfied
 {
     fn get_service(
     //~^ ERROR the trait bound `Bug: Foo` is not satisfied
diff --git a/tests/ui/associated-types/issue-59324.stderr b/tests/ui/associated-types/issue-59324.stderr
index f79afc8..3e2b0f4 100644
--- a/tests/ui/associated-types/issue-59324.stderr
+++ b/tests/ui/associated-types/issue-59324.stderr
@@ -2,7 +2,7 @@
   --> $DIR/issue-59324.rs:11:1
    |
 LL | / pub trait ThriftService<Bug: NotFoo>:
-...  |
+LL | |
 LL | |     Service<AssocType = <Bug as Foo>::OnlyFoo>
    | |______________________________________________^ the trait `Foo` is not implemented for `Bug`
    |
@@ -12,15 +12,10 @@
    |                                     +++++
 
 error[E0277]: the trait bound `Bug: Foo` is not satisfied
-  --> $DIR/issue-59324.rs:11:1
+  --> $DIR/issue-59324.rs:13:13
    |
-LL | / pub trait ThriftService<Bug: NotFoo>:
-LL | |
-LL | |
-LL | |     Service<AssocType = <Bug as Foo>::OnlyFoo>
-...  |
-LL | | }
-   | |_^ the trait `Foo` is not implemented for `Bug`
+LL |     Service<AssocType = <Bug as Foo>::OnlyFoo>
+   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Foo` is not implemented for `Bug`
    |
 help: consider further restricting type parameter `Bug` with trait `Foo`
    |
diff --git a/tests/ui/async-await/async-fn/impl-header.stderr b/tests/ui/async-await/async-fn/impl-header.stderr
index 64a98aa..2fc7a90 100644
--- a/tests/ui/async-await/async-fn/impl-header.stderr
+++ b/tests/ui/async-await/async-fn/impl-header.stderr
@@ -22,6 +22,14 @@
    |
    = help: add `#![feature(unboxed_closures)]` to the crate attributes to enable
 
+error[E0046]: not all trait items implemented, missing: `call`
+  --> $DIR/impl-header.rs:5:1
+   |
+LL | impl async Fn<()> for F {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^ missing `call` in implementation
+   |
+   = help: implement the missing item: `fn call(&self, _: ()) -> <Self as FnOnce<()>>::Output { todo!() }`
+
 error[E0277]: expected a `FnMut()` closure, found `F`
   --> $DIR/impl-header.rs:5:23
    |
@@ -33,14 +41,6 @@
 note: required by a bound in `Fn`
   --> $SRC_DIR/core/src/ops/function.rs:LL:COL
 
-error[E0046]: not all trait items implemented, missing: `call`
-  --> $DIR/impl-header.rs:5:1
-   |
-LL | impl async Fn<()> for F {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^ missing `call` in implementation
-   |
-   = help: implement the missing item: `fn call(&self, _: ()) -> <Self as FnOnce<()>>::Output { todo!() }`
-
 error: aborting due to 5 previous errors
 
 Some errors have detailed explanations: E0046, E0183, E0277, E0658.
diff --git a/tests/ui/attributes/inner-attrs-impl-cfg.rs b/tests/ui/attributes/inner-attrs-impl-cfg.rs
new file mode 100644
index 0000000..e7a5cfa
--- /dev/null
+++ b/tests/ui/attributes/inner-attrs-impl-cfg.rs
@@ -0,0 +1,36 @@
+//! Test inner attributes (#![...]) behavior in impl blocks with cfg conditions.
+//!
+//! This test verifies that:
+//! - Inner attributes can conditionally exclude entire impl blocks
+//! - Regular attributes within impl blocks work independently
+//! - Attribute parsing doesn't consume too eagerly
+
+//@ run-pass
+
+struct Foo;
+
+impl Foo {
+    #![cfg(false)]
+
+    fn method(&self) -> bool {
+        false
+    }
+}
+
+impl Foo {
+    #![cfg(not(FALSE))]
+
+    // Check that we don't eat attributes too eagerly.
+    #[cfg(false)]
+    fn method(&self) -> bool {
+        false
+    }
+
+    fn method(&self) -> bool {
+        true
+    }
+}
+
+pub fn main() {
+    assert!(Foo.method());
+}
diff --git a/tests/ui/attributes/malformed-attrs.rs b/tests/ui/attributes/malformed-attrs.rs
new file mode 100644
index 0000000..64c0d22
--- /dev/null
+++ b/tests/ui/attributes/malformed-attrs.rs
@@ -0,0 +1,221 @@
+// This file contains a bunch of malformed attributes.
+// We enable a bunch of features to not get feature-gate errs in this test.
+#![feature(rustc_attrs)]
+#![feature(rustc_allow_const_fn_unstable)]
+#![feature(allow_internal_unstable)]
+#![feature(fn_align)]
+#![feature(optimize_attribute)]
+#![feature(dropck_eyepatch)]
+#![feature(export_stable)]
+#![allow(incomplete_features)]
+#![feature(min_generic_const_args)]
+#![feature(ffi_const, ffi_pure)]
+#![feature(coverage_attribute)]
+#![feature(no_sanitize)]
+#![feature(marker_trait_attr)]
+#![feature(thread_local)]
+#![feature(must_not_suspend)]
+#![feature(coroutines)]
+#![feature(linkage)]
+#![feature(cfi_encoding, extern_types)]
+#![feature(patchable_function_entry)]
+#![feature(omit_gdb_pretty_printer_section)]
+#![feature(fundamental)]
+
+
+#![omit_gdb_pretty_printer_section = 1]
+//~^ ERROR malformed `omit_gdb_pretty_printer_section` attribute input
+
+#![windows_subsystem]
+//~^ ERROR malformed
+
+#[unsafe(export_name)]
+//~^ ERROR malformed
+#[rustc_allow_const_fn_unstable]
+//~^ ERROR `rustc_allow_const_fn_unstable` expects a list of feature names
+#[allow_internal_unstable]
+//~^ ERROR `allow_internal_unstable` expects a list of feature names
+#[rustc_confusables]
+//~^ ERROR malformed
+#[deprecated = 5]
+//~^ ERROR malformed
+#[doc]
+//~^ ERROR valid forms for the attribute are
+//~| WARN this was previously accepted by the compiler
+#[rustc_macro_transparency]
+//~^ ERROR malformed
+#[repr]
+//~^ ERROR malformed
+#[rustc_as_ptr = 5]
+//~^ ERROR malformed
+#[inline = 5]
+//~^ ERROR valid forms for the attribute are
+//~| WARN this was previously accepted by the compiler
+#[align]
+//~^ ERROR malformed
+#[optimize]
+//~^ ERROR malformed
+#[cold = 1]
+//~^ ERROR malformed
+#[must_use()]
+//~^ ERROR valid forms for the attribute are
+#[no_mangle = 1]
+//~^ ERROR malformed
+#[unsafe(naked())]
+//~^ ERROR malformed
+#[track_caller()]
+//~^ ERROR malformed
+#[export_name()]
+//~^ ERROR malformed
+#[used()]
+//~^ ERROR malformed
+#[crate_name]
+//~^ ERROR malformed
+#[doc]
+//~^ ERROR valid forms for the attribute are
+//~| WARN this was previously accepted by the compiler
+#[target_feature]
+//~^ ERROR malformed
+#[export_stable = 1]
+//~^ ERROR malformed
+#[link]
+//~^ ERROR attribute must be of the form
+//~| WARN this was previously accepted by the compiler
+#[link_name]
+//~^ ERROR malformed
+#[link_section]
+//~^ ERROR malformed
+#[coverage]
+//~^ ERROR malformed `coverage` attribute input
+#[no_sanitize]
+//~^ ERROR malformed
+#[ignore()]
+//~^ ERROR valid forms for the attribute are
+//~| WARN this was previously accepted by the compiler
+#[no_implicit_prelude = 23]
+//~^ ERROR malformed
+#[proc_macro = 18]
+//~^ ERROR malformed
+//~| ERROR the `#[proc_macro]` attribute is only usable with crates of the `proc-macro` crate type
+#[cfg]
+//~^ ERROR is not followed by parentheses
+#[cfg_attr]
+//~^ ERROR malformed
+#[instruction_set]
+//~^ ERROR malformed
+#[patchable_function_entry]
+//~^ ERROR malformed
+fn test() {
+    #[coroutine = 63] || {}
+    //~^ ERROR malformed `coroutine` attribute input
+    //~| ERROR mismatched types [E0308]
+}
+
+#[proc_macro_attribute = 19]
+//~^ ERROR malformed
+//~| ERROR the `#[proc_macro_attribute]` attribute is only usable with crates of the `proc-macro` crate type
+#[must_use = 1]
+//~^ ERROR malformed
+fn test2() { }
+
+#[proc_macro_derive]
+//~^ ERROR malformed `proc_macro_derive` attribute
+//~| ERROR the `#[proc_macro_derive]` attribute is only usable with crates of the `proc-macro` crate type
+pub fn test3() {}
+
+#[rustc_layout_scalar_valid_range_start]
+//~^ ERROR malformed
+#[rustc_layout_scalar_valid_range_end]
+//~^ ERROR malformed
+#[must_not_suspend()]
+//~^ ERROR malformed
+#[cfi_encoding]
+//~^ ERROR malformed
+struct Test;
+
+#[diagnostic::on_unimplemented]
+//~^ WARN missing options for `on_unimplemented` attribute
+#[diagnostic::on_unimplemented = 1]
+//~^ WARN malformed
+trait Hey {
+    #[type_const = 1]
+    //~^ ERROR malformed
+    const HEY: usize = 5;
+}
+
+struct Empty;
+#[diagnostic::do_not_recommend()]
+//~^ WARN does not expect any arguments
+impl Hey for Empty {
+
+}
+
+#[marker = 3]
+//~^ ERROR malformed
+#[fundamental()]
+//~^ ERROR malformed
+trait EmptyTrait {
+
+}
+
+
+extern "C" {
+    #[unsafe(ffi_pure = 1)]
+    //~^ ERROR malformed
+    #[link_ordinal]
+    //~^ ERROR malformed
+    pub fn baz();
+
+    #[unsafe(ffi_const = 1)]
+    //~^ ERROR malformed
+    #[linkage]
+    //~^ ERROR malformed
+    pub fn bar();
+}
+
+#[allow]
+//~^ ERROR malformed
+#[expect]
+//~^ ERROR malformed
+#[warn]
+//~^ ERROR malformed
+#[deny]
+//~^ ERROR malformed
+#[forbid]
+//~^ ERROR malformed
+#[debugger_visualizer]
+//~^ ERROR invalid argument
+//~| ERROR malformed `debugger_visualizer` attribute input
+#[automatically_derived = 18]
+//~^ ERROR malformed
+mod yooo {
+
+}
+
+#[non_exhaustive = 1]
+//~^ ERROR malformed
+enum Slenum {
+
+}
+
+#[thread_local()]
+//~^ ERROR malformed
+static mut TLS: u8 = 42;
+
+#[no_link()]
+//~^ ERROR malformed
+#[macro_use = 1]
+//~^ ERROR malformed
+extern crate wloop;
+//~^ ERROR can't find crate for `wloop` [E0463]
+
+#[macro_export = 18]
+//~^ ERROR malformed `macro_export` attribute input
+#[allow_internal_unsafe = 1]
+//~^ ERROR malformed
+//~| ERROR allow_internal_unsafe side-steps the unsafe_code lint
+macro_rules! slump {
+    () => {}
+}
+
+fn main() {}
diff --git a/tests/ui/attributes/malformed-attrs.stderr b/tests/ui/attributes/malformed-attrs.stderr
new file mode 100644
index 0000000..bf063e8
--- /dev/null
+++ b/tests/ui/attributes/malformed-attrs.stderr
@@ -0,0 +1,596 @@
+error: `cfg` is not followed by parentheses
+  --> $DIR/malformed-attrs.rs:100:1
+   |
+LL | #[cfg]
+   | ^^^^^^ help: expected syntax is: `cfg(/* predicate */)`
+
+error: malformed `cfg_attr` attribute input
+  --> $DIR/malformed-attrs.rs:102:1
+   |
+LL | #[cfg_attr]
+   | ^^^^^^^^^^^
+   |
+   = note: for more information, visit <https://doc.rust-lang.org/reference/conditional-compilation.html#the-cfg_attr-attribute>
+help: missing condition and attribute
+   |
+LL | #[cfg_attr(condition, attribute, other_attribute, ...)]
+   |           ++++++++++++++++++++++++++++++++++++++++++++
+
+error[E0463]: can't find crate for `wloop`
+  --> $DIR/malformed-attrs.rs:209:1
+   |
+LL | extern crate wloop;
+   | ^^^^^^^^^^^^^^^^^^^ can't find crate
+
+error: malformed `omit_gdb_pretty_printer_section` attribute input
+  --> $DIR/malformed-attrs.rs:26:1
+   |
+LL | #![omit_gdb_pretty_printer_section = 1]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#![omit_gdb_pretty_printer_section]`
+
+error: malformed `windows_subsystem` attribute input
+  --> $DIR/malformed-attrs.rs:29:1
+   |
+LL | #![windows_subsystem]
+   | ^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#![windows_subsystem = "windows|console"]`
+
+error: malformed `crate_name` attribute input
+  --> $DIR/malformed-attrs.rs:72:1
+   |
+LL | #[crate_name]
+   | ^^^^^^^^^^^^^ help: must be of the form: `#[crate_name = "name"]`
+
+error: malformed `target_feature` attribute input
+  --> $DIR/malformed-attrs.rs:77:1
+   |
+LL | #[target_feature]
+   | ^^^^^^^^^^^^^^^^^ help: must be of the form: `#[target_feature(enable = "name")]`
+
+error: malformed `export_stable` attribute input
+  --> $DIR/malformed-attrs.rs:79:1
+   |
+LL | #[export_stable = 1]
+   | ^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[export_stable]`
+
+error: malformed `coverage` attribute input
+  --> $DIR/malformed-attrs.rs:88:1
+   |
+LL | #[coverage]
+   | ^^^^^^^^^^^
+   |
+help: the following are the possible correct uses
+   |
+LL | #[coverage(off)]
+   |           +++++
+LL | #[coverage(on)]
+   |           ++++
+
+error: malformed `no_sanitize` attribute input
+  --> $DIR/malformed-attrs.rs:90:1
+   |
+LL | #[no_sanitize]
+   | ^^^^^^^^^^^^^^ help: must be of the form: `#[no_sanitize(address, kcfi, memory, thread)]`
+
+error: malformed `no_implicit_prelude` attribute input
+  --> $DIR/malformed-attrs.rs:95:1
+   |
+LL | #[no_implicit_prelude = 23]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[no_implicit_prelude]`
+
+error: malformed `proc_macro` attribute input
+  --> $DIR/malformed-attrs.rs:97:1
+   |
+LL | #[proc_macro = 18]
+   | ^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[proc_macro]`
+
+error: malformed `instruction_set` attribute input
+  --> $DIR/malformed-attrs.rs:104:1
+   |
+LL | #[instruction_set]
+   | ^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[instruction_set(set)]`
+
+error: malformed `patchable_function_entry` attribute input
+  --> $DIR/malformed-attrs.rs:106:1
+   |
+LL | #[patchable_function_entry]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[patchable_function_entry(prefix_nops = m, entry_nops = n)]`
+
+error: malformed `coroutine` attribute input
+  --> $DIR/malformed-attrs.rs:109:5
+   |
+LL |     #[coroutine = 63] || {}
+   |     ^^^^^^^^^^^^^^^^^ help: must be of the form: `#[coroutine]`
+
+error: malformed `proc_macro_attribute` attribute input
+  --> $DIR/malformed-attrs.rs:114:1
+   |
+LL | #[proc_macro_attribute = 19]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[proc_macro_attribute]`
+
+error: malformed `proc_macro_derive` attribute input
+  --> $DIR/malformed-attrs.rs:121:1
+   |
+LL | #[proc_macro_derive]
+   | ^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[proc_macro_derive(TraitName, /*opt*/ attributes(name1, name2, ...))]`
+
+error: malformed `must_not_suspend` attribute input
+  --> $DIR/malformed-attrs.rs:130:1
+   |
+LL | #[must_not_suspend()]
+   | ^^^^^^^^^^^^^^^^^^^^^
+   |
+help: the following are the possible correct uses
+   |
+LL - #[must_not_suspend()]
+LL + #[must_not_suspend = "reason"]
+   |
+LL - #[must_not_suspend()]
+LL + #[must_not_suspend]
+   |
+
+error: malformed `cfi_encoding` attribute input
+  --> $DIR/malformed-attrs.rs:132:1
+   |
+LL | #[cfi_encoding]
+   | ^^^^^^^^^^^^^^^ help: must be of the form: `#[cfi_encoding = "encoding"]`
+
+error: malformed `type_const` attribute input
+  --> $DIR/malformed-attrs.rs:141:5
+   |
+LL |     #[type_const = 1]
+   |     ^^^^^^^^^^^^^^^^^ help: must be of the form: `#[type_const]`
+
+error: malformed `marker` attribute input
+  --> $DIR/malformed-attrs.rs:153:1
+   |
+LL | #[marker = 3]
+   | ^^^^^^^^^^^^^ help: must be of the form: `#[marker]`
+
+error: malformed `fundamental` attribute input
+  --> $DIR/malformed-attrs.rs:155:1
+   |
+LL | #[fundamental()]
+   | ^^^^^^^^^^^^^^^^ help: must be of the form: `#[fundamental]`
+
+error: malformed `ffi_pure` attribute input
+  --> $DIR/malformed-attrs.rs:163:5
+   |
+LL |     #[unsafe(ffi_pure = 1)]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[ffi_pure]`
+
+error: malformed `link_ordinal` attribute input
+  --> $DIR/malformed-attrs.rs:165:5
+   |
+LL |     #[link_ordinal]
+   |     ^^^^^^^^^^^^^^^ help: must be of the form: `#[link_ordinal(ordinal)]`
+
+error: malformed `ffi_const` attribute input
+  --> $DIR/malformed-attrs.rs:169:5
+   |
+LL |     #[unsafe(ffi_const = 1)]
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[ffi_const]`
+
+error: malformed `linkage` attribute input
+  --> $DIR/malformed-attrs.rs:171:5
+   |
+LL |     #[linkage]
+   |     ^^^^^^^^^^ help: must be of the form: `#[linkage = "external|internal|..."]`
+
+error: malformed `allow` attribute input
+  --> $DIR/malformed-attrs.rs:176:1
+   |
+LL | #[allow]
+   | ^^^^^^^^ help: must be of the form: `#[allow(lint1, lint2, ..., /*opt*/ reason = "...")]`
+
+error: malformed `expect` attribute input
+  --> $DIR/malformed-attrs.rs:178:1
+   |
+LL | #[expect]
+   | ^^^^^^^^^ help: must be of the form: `#[expect(lint1, lint2, ..., /*opt*/ reason = "...")]`
+
+error: malformed `warn` attribute input
+  --> $DIR/malformed-attrs.rs:180:1
+   |
+LL | #[warn]
+   | ^^^^^^^ help: must be of the form: `#[warn(lint1, lint2, ..., /*opt*/ reason = "...")]`
+
+error: malformed `deny` attribute input
+  --> $DIR/malformed-attrs.rs:182:1
+   |
+LL | #[deny]
+   | ^^^^^^^ help: must be of the form: `#[deny(lint1, lint2, ..., /*opt*/ reason = "...")]`
+
+error: malformed `forbid` attribute input
+  --> $DIR/malformed-attrs.rs:184:1
+   |
+LL | #[forbid]
+   | ^^^^^^^^^ help: must be of the form: `#[forbid(lint1, lint2, ..., /*opt*/ reason = "...")]`
+
+error: malformed `debugger_visualizer` attribute input
+  --> $DIR/malformed-attrs.rs:186:1
+   |
+LL | #[debugger_visualizer]
+   | ^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[debugger_visualizer(natvis_file = "...", gdb_script_file = "...")]`
+
+error: malformed `automatically_derived` attribute input
+  --> $DIR/malformed-attrs.rs:189:1
+   |
+LL | #[automatically_derived = 18]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[automatically_derived]`
+
+error: malformed `non_exhaustive` attribute input
+  --> $DIR/malformed-attrs.rs:195:1
+   |
+LL | #[non_exhaustive = 1]
+   | ^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[non_exhaustive]`
+
+error: malformed `thread_local` attribute input
+  --> $DIR/malformed-attrs.rs:201:1
+   |
+LL | #[thread_local()]
+   | ^^^^^^^^^^^^^^^^^ help: must be of the form: `#[thread_local]`
+
+error: malformed `no_link` attribute input
+  --> $DIR/malformed-attrs.rs:205:1
+   |
+LL | #[no_link()]
+   | ^^^^^^^^^^^^ help: must be of the form: `#[no_link]`
+
+error: malformed `macro_use` attribute input
+  --> $DIR/malformed-attrs.rs:207:1
+   |
+LL | #[macro_use = 1]
+   | ^^^^^^^^^^^^^^^^
+   |
+help: the following are the possible correct uses
+   |
+LL - #[macro_use = 1]
+LL + #[macro_use(name1, name2, ...)]
+   |
+LL - #[macro_use = 1]
+LL + #[macro_use]
+   |
+
+error: malformed `macro_export` attribute input
+  --> $DIR/malformed-attrs.rs:212:1
+   |
+LL | #[macro_export = 18]
+   | ^^^^^^^^^^^^^^^^^^^^
+   |
+help: the following are the possible correct uses
+   |
+LL - #[macro_export = 18]
+LL + #[macro_export(local_inner_macros)]
+   |
+LL - #[macro_export = 18]
+LL + #[macro_export]
+   |
+
+error: malformed `allow_internal_unsafe` attribute input
+  --> $DIR/malformed-attrs.rs:214:1
+   |
+LL | #[allow_internal_unsafe = 1]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[allow_internal_unsafe]`
+
+error: the `#[proc_macro]` attribute is only usable with crates of the `proc-macro` crate type
+  --> $DIR/malformed-attrs.rs:97:1
+   |
+LL | #[proc_macro = 18]
+   | ^^^^^^^^^^^^^^^^^^
+
+error: the `#[proc_macro_attribute]` attribute is only usable with crates of the `proc-macro` crate type
+  --> $DIR/malformed-attrs.rs:114:1
+   |
+LL | #[proc_macro_attribute = 19]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error: the `#[proc_macro_derive]` attribute is only usable with crates of the `proc-macro` crate type
+  --> $DIR/malformed-attrs.rs:121:1
+   |
+LL | #[proc_macro_derive]
+   | ^^^^^^^^^^^^^^^^^^^^
+
+error[E0658]: allow_internal_unsafe side-steps the unsafe_code lint
+  --> $DIR/malformed-attrs.rs:214:1
+   |
+LL | #[allow_internal_unsafe = 1]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = help: add `#![feature(allow_internal_unsafe)]` to the crate attributes to enable
+   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
+
+error: valid forms for the attribute are `#[doc(hidden|inline|...)]` and `#[doc = "string"]`
+  --> $DIR/malformed-attrs.rs:42:1
+   |
+LL | #[doc]
+   | ^^^^^^
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #57571 <https://github.com/rust-lang/rust/issues/57571>
+   = note: `#[deny(ill_formed_attribute_input)]` on by default
+
+error: valid forms for the attribute are `#[doc(hidden|inline|...)]` and `#[doc = "string"]`
+  --> $DIR/malformed-attrs.rs:74:1
+   |
+LL | #[doc]
+   | ^^^^^^
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #57571 <https://github.com/rust-lang/rust/issues/57571>
+
+error: attribute must be of the form `#[link(name = "...", /*opt*/ kind = "dylib|static|...", /*opt*/ wasm_import_module = "...", /*opt*/ import_name_type = "decorated|noprefix|undecorated")]`
+  --> $DIR/malformed-attrs.rs:81:1
+   |
+LL | #[link]
+   | ^^^^^^^
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #57571 <https://github.com/rust-lang/rust/issues/57571>
+
+error: valid forms for the attribute are `#[ignore]` and `#[ignore = "reason"]`
+  --> $DIR/malformed-attrs.rs:92:1
+   |
+LL | #[ignore()]
+   | ^^^^^^^^^^^
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #57571 <https://github.com/rust-lang/rust/issues/57571>
+
+error: invalid argument
+  --> $DIR/malformed-attrs.rs:186:1
+   |
+LL | #[debugger_visualizer]
+   | ^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: expected: `natvis_file = "..."`
+   = note: OR
+   = note: expected: `gdb_script_file = "..."`
+
+error[E0539]: malformed `export_name` attribute input
+  --> $DIR/malformed-attrs.rs:32:1
+   |
+LL | #[unsafe(export_name)]
+   | ^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[export_name = "name"]`
+
+error: `rustc_allow_const_fn_unstable` expects a list of feature names
+  --> $DIR/malformed-attrs.rs:34:1
+   |
+LL | #[rustc_allow_const_fn_unstable]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error: `allow_internal_unstable` expects a list of feature names
+  --> $DIR/malformed-attrs.rs:36:1
+   |
+LL | #[allow_internal_unstable]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error[E0539]: malformed `rustc_confusables` attribute input
+  --> $DIR/malformed-attrs.rs:38:1
+   |
+LL | #[rustc_confusables]
+   | ^^^^^^^^^^^^^^^^^^^^
+   | |
+   | expected this to be a list
+   | help: must be of the form: `#[rustc_confusables("name1", "name2", ...)]`
+
+error[E0539]: malformed `deprecated` attribute input
+  --> $DIR/malformed-attrs.rs:40:1
+   |
+LL | #[deprecated = 5]
+   | ^^^^^^^^^^^^^^^-^
+   |                |
+   |                expected a string literal here
+   |
+help: try changing it to one of the following valid forms of the attribute
+   |
+LL - #[deprecated = 5]
+LL + #[deprecated = "reason"]
+   |
+LL - #[deprecated = 5]
+LL + #[deprecated(/*opt*/ since = "version", /*opt*/ note = "reason")]
+   |
+LL - #[deprecated = 5]
+LL + #[deprecated]
+   |
+
+error[E0539]: malformed `rustc_macro_transparency` attribute input
+  --> $DIR/malformed-attrs.rs:45:1
+   |
+LL | #[rustc_macro_transparency]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[rustc_macro_transparency = "transparent|semitransparent|opaque"]`
+
+error[E0539]: malformed `repr` attribute input
+  --> $DIR/malformed-attrs.rs:47:1
+   |
+LL | #[repr]
+   | ^^^^^^^
+   | |
+   | expected this to be a list
+   | help: must be of the form: `#[repr(C | Rust | align(...) | packed(...) | <integer type> | transparent)]`
+
+error[E0565]: malformed `rustc_as_ptr` attribute input
+  --> $DIR/malformed-attrs.rs:49:1
+   |
+LL | #[rustc_as_ptr = 5]
+   | ^^^^^^^^^^^^^^^---^
+   | |              |
+   | |              didn't expect any arguments here
+   | help: must be of the form: `#[rustc_as_ptr]`
+
+error[E0539]: malformed `align` attribute input
+  --> $DIR/malformed-attrs.rs:54:1
+   |
+LL | #[align]
+   | ^^^^^^^^
+   | |
+   | expected this to be a list
+   | help: must be of the form: `#[align(<alignment in bytes>)]`
+
+error[E0539]: malformed `optimize` attribute input
+  --> $DIR/malformed-attrs.rs:56:1
+   |
+LL | #[optimize]
+   | ^^^^^^^^^^^
+   | |
+   | expected this to be a list
+   | help: must be of the form: `#[optimize(size|speed|none)]`
+
+error[E0565]: malformed `cold` attribute input
+  --> $DIR/malformed-attrs.rs:58:1
+   |
+LL | #[cold = 1]
+   | ^^^^^^^---^
+   | |      |
+   | |      didn't expect any arguments here
+   | help: must be of the form: `#[cold]`
+
+error: valid forms for the attribute are `#[must_use = "reason"]` and `#[must_use]`
+  --> $DIR/malformed-attrs.rs:60:1
+   |
+LL | #[must_use()]
+   | ^^^^^^^^^^^^^
+
+error[E0565]: malformed `no_mangle` attribute input
+  --> $DIR/malformed-attrs.rs:62:1
+   |
+LL | #[no_mangle = 1]
+   | ^^^^^^^^^^^^---^
+   | |           |
+   | |           didn't expect any arguments here
+   | help: must be of the form: `#[no_mangle]`
+
+error[E0565]: malformed `naked` attribute input
+  --> $DIR/malformed-attrs.rs:64:1
+   |
+LL | #[unsafe(naked())]
+   | ^^^^^^^^^^^^^^--^^
+   | |             |
+   | |             didn't expect any arguments here
+   | help: must be of the form: `#[naked]`
+
+error[E0565]: malformed `track_caller` attribute input
+  --> $DIR/malformed-attrs.rs:66:1
+   |
+LL | #[track_caller()]
+   | ^^^^^^^^^^^^^^--^
+   | |             |
+   | |             didn't expect any arguments here
+   | help: must be of the form: `#[track_caller]`
+
+error[E0539]: malformed `export_name` attribute input
+  --> $DIR/malformed-attrs.rs:68:1
+   |
+LL | #[export_name()]
+   | ^^^^^^^^^^^^^^^^ help: must be of the form: `#[export_name = "name"]`
+
+error[E0805]: malformed `used` attribute input
+  --> $DIR/malformed-attrs.rs:70:1
+   |
+LL | #[used()]
+   | ^^^^^^--^
+   |       |
+   |       expected a single argument here
+   |
+help: try changing it to one of the following valid forms of the attribute
+   |
+LL | #[used(compiler|linker)]
+   |        +++++++++++++++
+LL - #[used()]
+LL + #[used]
+   |
+
+error[E0539]: malformed `link_name` attribute input
+  --> $DIR/malformed-attrs.rs:84:1
+   |
+LL | #[link_name]
+   | ^^^^^^^^^^^^ help: must be of the form: `#[link_name = "name"]`
+
+error[E0539]: malformed `link_section` attribute input
+  --> $DIR/malformed-attrs.rs:86:1
+   |
+LL | #[link_section]
+   | ^^^^^^^^^^^^^^^ help: must be of the form: `#[link_section = "name"]`
+
+error[E0539]: malformed `must_use` attribute input
+  --> $DIR/malformed-attrs.rs:117:1
+   |
+LL | #[must_use = 1]
+   | ^^^^^^^^^^^^^-^
+   |              |
+   |              expected a string literal here
+   |
+help: try changing it to one of the following valid forms of the attribute
+   |
+LL - #[must_use = 1]
+LL + #[must_use = "reason"]
+   |
+LL - #[must_use = 1]
+LL + #[must_use]
+   |
+
+error[E0539]: malformed `rustc_layout_scalar_valid_range_start` attribute input
+  --> $DIR/malformed-attrs.rs:126:1
+   |
+LL | #[rustc_layout_scalar_valid_range_start]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   | |
+   | expected this to be a list
+   | help: must be of the form: `#[rustc_layout_scalar_valid_range_start(start)]`
+
+error[E0539]: malformed `rustc_layout_scalar_valid_range_end` attribute input
+  --> $DIR/malformed-attrs.rs:128:1
+   |
+LL | #[rustc_layout_scalar_valid_range_end]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   | |
+   | expected this to be a list
+   | help: must be of the form: `#[rustc_layout_scalar_valid_range_end(end)]`
+
+warning: `#[diagnostic::do_not_recommend]` does not expect any arguments
+  --> $DIR/malformed-attrs.rs:147:1
+   |
+LL | #[diagnostic::do_not_recommend()]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: `#[warn(unknown_or_malformed_diagnostic_attributes)]` on by default
+
+warning: missing options for `on_unimplemented` attribute
+  --> $DIR/malformed-attrs.rs:136:1
+   |
+LL | #[diagnostic::on_unimplemented]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = help: at least one of the `message`, `note` and `label` options are expected
+
+warning: malformed `on_unimplemented` attribute
+  --> $DIR/malformed-attrs.rs:138:1
+   |
+LL | #[diagnostic::on_unimplemented = 1]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ invalid option found here
+   |
+   = help: only `message`, `note` and `label` are allowed as options
+
+error: valid forms for the attribute are `#[inline(always|never)]` and `#[inline]`
+  --> $DIR/malformed-attrs.rs:51:1
+   |
+LL | #[inline = 5]
+   | ^^^^^^^^^^^^^
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #57571 <https://github.com/rust-lang/rust/issues/57571>
+
+error[E0308]: mismatched types
+  --> $DIR/malformed-attrs.rs:109:23
+   |
+LL | fn test() {
+   |          - help: a return type might be missing here: `-> _`
+LL |     #[coroutine = 63] || {}
+   |                       ^^^^^ expected `()`, found coroutine
+   |
+   = note: expected unit type `()`
+              found coroutine `{coroutine@$DIR/malformed-attrs.rs:109:23: 109:25}`
+
+error: aborting due to 72 previous errors; 3 warnings emitted
+
+Some errors have detailed explanations: E0308, E0463, E0539, E0565, E0658, E0805.
+For more information about an error, try `rustc --explain E0308`.
diff --git a/tests/ui/cast/non-primitive-cast-suggestion.fixed b/tests/ui/cast/non-primitive-cast-suggestion.fixed
new file mode 100644
index 0000000..9a1a3c0
--- /dev/null
+++ b/tests/ui/cast/non-primitive-cast-suggestion.fixed
@@ -0,0 +1,23 @@
+//! Test that casting non-primitive types with `as` is rejected with a helpful suggestion.
+//!
+//! You can't use `as` to cast between non-primitive types, even if they have
+//! `From`/`Into` implementations. The compiler should suggest using `From::from()`
+//! or `.into()` instead, and rustfix should be able to apply the suggestion.
+
+//@ run-rustfix
+
+#[derive(Debug)]
+struct Foo {
+    x: isize,
+}
+
+impl From<Foo> for isize {
+    fn from(val: Foo) -> isize {
+        val.x
+    }
+}
+
+fn main() {
+    let _ = isize::from(Foo { x: 1 });
+    //~^ ERROR non-primitive cast: `Foo` as `isize` [E0605]
+}
diff --git a/tests/ui/cast/non-primitive-cast-suggestion.rs b/tests/ui/cast/non-primitive-cast-suggestion.rs
new file mode 100644
index 0000000..79006f4
--- /dev/null
+++ b/tests/ui/cast/non-primitive-cast-suggestion.rs
@@ -0,0 +1,23 @@
+//! Test that casting non-primitive types with `as` is rejected with a helpful suggestion.
+//!
+//! You can't use `as` to cast between non-primitive types, even if they have
+//! `From`/`Into` implementations. The compiler should suggest using `From::from()`
+//! or `.into()` instead, and rustfix should be able to apply the suggestion.
+
+//@ run-rustfix
+
+#[derive(Debug)]
+struct Foo {
+    x: isize,
+}
+
+impl From<Foo> for isize {
+    fn from(val: Foo) -> isize {
+        val.x
+    }
+}
+
+fn main() {
+    let _ = Foo { x: 1 } as isize;
+    //~^ ERROR non-primitive cast: `Foo` as `isize` [E0605]
+}
diff --git a/tests/ui/cast/non-primitive-cast-suggestion.stderr b/tests/ui/cast/non-primitive-cast-suggestion.stderr
new file mode 100644
index 0000000..bd35ded
--- /dev/null
+++ b/tests/ui/cast/non-primitive-cast-suggestion.stderr
@@ -0,0 +1,15 @@
+error[E0605]: non-primitive cast: `Foo` as `isize`
+  --> $DIR/non-primitive-cast-suggestion.rs:21:13
+   |
+LL |     let _ = Foo { x: 1 } as isize;
+   |             ^^^^^^^^^^^^^^^^^^^^^ an `as` expression can only be used to convert between primitive types or to coerce to a specific trait object
+   |
+help: consider using the `From` trait instead
+   |
+LL -     let _ = Foo { x: 1 } as isize;
+LL +     let _ = isize::from(Foo { x: 1 });
+   |
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0605`.
diff --git a/tests/ui/closures/basic-closure-syntax.rs b/tests/ui/closures/basic-closure-syntax.rs
new file mode 100644
index 0000000..1d968f8
--- /dev/null
+++ b/tests/ui/closures/basic-closure-syntax.rs
@@ -0,0 +1,35 @@
+//! Test basic closure syntax and usage with generic functions.
+//!
+//! This test checks that closure syntax works correctly for:
+//! - Closures with parameters and return values
+//! - Closures without parameters (both expression and block forms)
+//! - Integration with generic functions and FnOnce trait bounds
+
+//@ run-pass
+
+fn f<F>(i: isize, f: F) -> isize
+where
+    F: FnOnce(isize) -> isize,
+{
+    f(i)
+}
+
+fn g<G>(_g: G)
+where
+    G: FnOnce(),
+{
+}
+
+pub fn main() {
+    // Closure with parameter that returns the same value
+    assert_eq!(f(10, |a| a), 10);
+
+    // Closure without parameters - expression form
+    g(|| ());
+
+    // Test closure reuse in generic context
+    assert_eq!(f(10, |a| a), 10);
+
+    // Closure without parameters - block form
+    g(|| {});
+}
diff --git a/tests/ui/closures/closure-clone-requires-captured-clone.rs b/tests/ui/closures/closure-clone-requires-captured-clone.rs
new file mode 100644
index 0000000..80938e5
--- /dev/null
+++ b/tests/ui/closures/closure-clone-requires-captured-clone.rs
@@ -0,0 +1,19 @@
+//! Test that closures only implement `Clone` if all captured values implement `Clone`.
+//!
+//! When a closure captures variables from its environment, it can only be cloned
+//! if all those captured variables are cloneable. This test makes sure the compiler
+//! properly rejects attempts to clone closures that capture non-Clone types.
+
+//@ compile-flags: --diagnostic-width=300
+
+struct NonClone(i32);
+
+fn main() {
+    let captured_value = NonClone(5);
+    let closure = move || {
+        let _ = captured_value.0;
+    };
+
+    closure.clone();
+    //~^ ERROR the trait bound `NonClone: Clone` is not satisfied
+}
diff --git a/tests/ui/closures/closure-clone-requires-captured-clone.stderr b/tests/ui/closures/closure-clone-requires-captured-clone.stderr
new file mode 100644
index 0000000..785cc8a
--- /dev/null
+++ b/tests/ui/closures/closure-clone-requires-captured-clone.stderr
@@ -0,0 +1,23 @@
+error[E0277]: the trait bound `NonClone: Clone` is not satisfied in `{closure@$DIR/closure-clone-requires-captured-clone.rs:13:19: 13:26}`
+  --> $DIR/closure-clone-requires-captured-clone.rs:17:13
+   |
+LL |     let closure = move || {
+   |                   ------- within this `{closure@$DIR/closure-clone-requires-captured-clone.rs:13:19: 13:26}`
+...
+LL |     closure.clone();
+   |             ^^^^^ within `{closure@$DIR/closure-clone-requires-captured-clone.rs:13:19: 13:26}`, the trait `Clone` is not implemented for `NonClone`
+   |
+note: required because it's used within this closure
+  --> $DIR/closure-clone-requires-captured-clone.rs:13:19
+   |
+LL |     let closure = move || {
+   |                   ^^^^^^^
+help: consider annotating `NonClone` with `#[derive(Clone)]`
+   |
+LL + #[derive(Clone)]
+LL | struct NonClone(i32);
+   |
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/closures/missing-body.rs b/tests/ui/closures/missing-body.rs
new file mode 100644
index 0000000..461c2be
--- /dev/null
+++ b/tests/ui/closures/missing-body.rs
@@ -0,0 +1,7 @@
+// Checks that the compiler complains about the missing closure body and does not
+// crash.
+// This is a regression test for <https://github.com/rust-lang/rust/issues/143128>.
+
+fn main() { |b: [str; _]| {}; }
+//~^ ERROR the placeholder `_` is not allowed within types on item signatures for closures
+//~| ERROR the size for values of type `str` cannot be known at compilation time
diff --git a/tests/ui/closures/missing-body.stderr b/tests/ui/closures/missing-body.stderr
new file mode 100644
index 0000000..33580fc
--- /dev/null
+++ b/tests/ui/closures/missing-body.stderr
@@ -0,0 +1,19 @@
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for closures
+  --> $DIR/missing-body.rs:5:23
+   |
+LL | fn main() { |b: [str; _]| {}; }
+   |                       ^ not allowed in type signatures
+
+error[E0277]: the size for values of type `str` cannot be known at compilation time
+  --> $DIR/missing-body.rs:5:17
+   |
+LL | fn main() { |b: [str; _]| {}; }
+   |                 ^^^^^^^^ doesn't have a size known at compile-time
+   |
+   = help: the trait `Sized` is not implemented for `str`
+   = note: slice and array elements must have `Sized` type
+
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0121, E0277.
+For more information about an error, try `rustc --explain E0121`.
diff --git a/tests/ui/codegen/maximal-hir-to-mir-coverage-flag.rs b/tests/ui/codegen/maximal-hir-to-mir-coverage-flag.rs
new file mode 100644
index 0000000..64c31be
--- /dev/null
+++ b/tests/ui/codegen/maximal-hir-to-mir-coverage-flag.rs
@@ -0,0 +1,12 @@
+//! Test that -Z maximal-hir-to-mir-coverage flag is accepted.
+//!
+//! Original PR: https://github.com/rust-lang/rust/pull/105286
+
+//@ compile-flags: -Zmaximal-hir-to-mir-coverage
+//@ run-pass
+
+fn main() {
+    let x = 1;
+    let y = x + 1;
+    println!("{y}");
+}
diff --git a/tests/ui/codegen/mono-respects-abi-alignment.rs b/tests/ui/codegen/mono-respects-abi-alignment.rs
new file mode 100644
index 0000000..045d82b
--- /dev/null
+++ b/tests/ui/codegen/mono-respects-abi-alignment.rs
@@ -0,0 +1,37 @@
+//! Test that monomorphization correctly distinguishes types with different ABI alignment.
+//!
+//! On x86_64-linux-gnu and similar platforms, structs get 8-byte "preferred"
+//! alignment, but their "ABI" alignment (what actually matters for data layout)
+//! is the largest alignment of any field. If monomorphization incorrectly uses
+//! "preferred" alignment instead of "ABI" alignment, it might unify types `A`
+//! and `B` even though `S<A>` and `S<B>` have field `t` at different offsets,
+//! leading to incorrect method dispatch for `unwrap()`.
+
+//@ run-pass
+
+#[derive(Copy, Clone)]
+struct S<T> {
+    #[allow(dead_code)]
+    i: u8,
+    t: T,
+}
+
+impl<T> S<T> {
+    fn unwrap(self) -> T {
+        self.t
+    }
+}
+
+#[derive(Copy, Clone, PartialEq, Debug)]
+struct A((u32, u32)); // Different ABI alignment than B
+
+#[derive(Copy, Clone, PartialEq, Debug)]
+struct B(u64); // Different ABI alignment than A
+
+pub fn main() {
+    static CA: S<A> = S { i: 0, t: A((13, 104)) };
+    static CB: S<B> = S { i: 0, t: B(31337) };
+
+    assert_eq!(CA.unwrap(), A((13, 104)));
+    assert_eq!(CB.unwrap(), B(31337));
+}
diff --git a/tests/ui/codegen/msvc-opt-level-z-no-corruption.rs b/tests/ui/codegen/msvc-opt-level-z-no-corruption.rs
new file mode 100644
index 0000000..ba97ace
--- /dev/null
+++ b/tests/ui/codegen/msvc-opt-level-z-no-corruption.rs
@@ -0,0 +1,37 @@
+//! Test that opt-level=z produces correct code on Windows MSVC targets.
+//!
+//! A previously outdated version of LLVM caused compilation failures and
+//! generated invalid code on Windows specifically with optimization level `z`.
+//! The bug manifested as corrupted base pointers due to incorrect register
+//! usage in the generated assembly (e.g., `popl %esi` corrupting local variables).
+//! After updating to a more recent LLVM version, this test ensures that
+//! compilation and execution both succeed with opt-level=z.
+//!
+//! Regression test for <https://github.com/rust-lang/rust/issues/45034>.
+
+//@ ignore-cross-compile
+// Reason: the compiled binary is executed
+//@ only-windows
+// Reason: the observed bug only occurred on Windows MSVC targets
+//@ run-pass
+//@ compile-flags: -C opt-level=z
+
+#![feature(test)]
+extern crate test;
+
+fn foo(x: i32, y: i32) -> i64 {
+    (x + y) as i64
+}
+
+#[inline(never)]
+fn bar() {
+    let _f = Box::new(0);
+    // This call used to trigger an LLVM bug in opt-level=z where the base
+    // pointer gets corrupted due to incorrect register allocation
+    let y: fn(i32, i32) -> i64 = test::black_box(foo);
+    test::black_box(y(1, 2));
+}
+
+fn main() {
+    bar();
+}
diff --git a/tests/ui/coherence/coherence-impl-trait-for-trait-dyn-compatible.stderr b/tests/ui/coherence/coherence-impl-trait-for-trait-dyn-compatible.stderr
index 033bfee..aafedc3 100644
--- a/tests/ui/coherence/coherence-impl-trait-for-trait-dyn-compatible.stderr
+++ b/tests/ui/coherence/coherence-impl-trait-for-trait-dyn-compatible.stderr
@@ -1,3 +1,11 @@
+error[E0046]: not all trait items implemented, missing: `eq`
+  --> $DIR/coherence-impl-trait-for-trait-dyn-compatible.rs:7:1
+   |
+LL | trait DynIncompatible { fn eq(&self, other: Self); }
+   |                         -------------------------- `eq` from trait
+LL | impl DynIncompatible for dyn DynIncompatible { }
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `eq` in implementation
+
 error[E0038]: the trait `DynIncompatible` is not dyn compatible
   --> $DIR/coherence-impl-trait-for-trait-dyn-compatible.rs:7:26
    |
@@ -14,14 +22,6 @@
    |       this trait is not dyn compatible...
    = help: consider moving `eq` to another trait
 
-error[E0046]: not all trait items implemented, missing: `eq`
-  --> $DIR/coherence-impl-trait-for-trait-dyn-compatible.rs:7:1
-   |
-LL | trait DynIncompatible { fn eq(&self, other: Self); }
-   |                         -------------------------- `eq` from trait
-LL | impl DynIncompatible for dyn DynIncompatible { }
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `eq` in implementation
-
 error: aborting due to 2 previous errors
 
 Some errors have detailed explanations: E0038, E0046.
diff --git a/tests/ui/coherence/fuzzing/best-obligation-ICE.stderr b/tests/ui/coherence/fuzzing/best-obligation-ICE.stderr
index 01b6eaf..fe28f4f 100644
--- a/tests/ui/coherence/fuzzing/best-obligation-ICE.stderr
+++ b/tests/ui/coherence/fuzzing/best-obligation-ICE.stderr
@@ -1,3 +1,12 @@
+error[E0046]: not all trait items implemented, missing: `Assoc`
+  --> $DIR/best-obligation-ICE.rs:10:1
+   |
+LL |     type Assoc;
+   |     ---------- `Assoc` from trait
+...
+LL | impl<T> Trait for W<W<W<T>>> {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `Assoc` in implementation
+
 error[E0277]: the trait bound `W<W<T>>: Trait` is not satisfied
   --> $DIR/best-obligation-ICE.rs:10:19
    |
@@ -46,15 +55,6 @@
 LL | impl<T: Trait> Trait for W<W<W<T>>> {}
    |       +++++++
 
-error[E0046]: not all trait items implemented, missing: `Assoc`
-  --> $DIR/best-obligation-ICE.rs:10:1
-   |
-LL |     type Assoc;
-   |     ---------- `Assoc` from trait
-...
-LL | impl<T> Trait for W<W<W<T>>> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `Assoc` in implementation
-
 error[E0119]: conflicting implementations of trait `NoOverlap` for type `W<W<W<W<_>>>>`
   --> $DIR/best-obligation-ICE.rs:18:1
    |
diff --git a/tests/ui/compiletest-self-test/ui-test-missing-annotations-detection.rs b/tests/ui/compiletest-self-test/ui-test-missing-annotations-detection.rs
new file mode 100644
index 0000000..3a110bd
--- /dev/null
+++ b/tests/ui/compiletest-self-test/ui-test-missing-annotations-detection.rs
@@ -0,0 +1,9 @@
+//! Regression test checks UI tests without error annotations are detected as failing.
+//!
+//! This tests that when we forget to use any `//~ ERROR` comments whatsoever,
+//! the test doesn't succeed
+//! Originally created in https://github.com/rust-lang/rust/pull/56244
+
+//@ should-fail
+
+fn main() {}
diff --git a/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.rs b/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.rs
index e5af632..478fa37 100644
--- a/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.rs
+++ b/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.rs
@@ -5,6 +5,7 @@
 struct Foo;
 impl<'a, const NUM: usize> std::ops::Add<&'a Foo> for Foo
 //~^ ERROR the const parameter `NUM` is not constrained by the impl trait, self type, or predicates
+//~| ERROR missing: `Output`, `add`
 where
     [(); 1 + 0]: Sized,
 {
diff --git a/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.stderr b/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.stderr
index ade18eb..29bbd23 100644
--- a/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.stderr
+++ b/tests/ui/const-generics/generic_const_exprs/post-analysis-user-facing-param-env.stderr
@@ -1,5 +1,5 @@
 error[E0407]: method `unimplemented` is not a member of trait `std::ops::Add`
-  --> $DIR/post-analysis-user-facing-param-env.rs:11:5
+  --> $DIR/post-analysis-user-facing-param-env.rs:12:5
    |
 LL | /     fn unimplemented(self, _: &Foo) -> Self::Output {
 LL | |
@@ -17,6 +17,19 @@
    = note: see issue #76560 <https://github.com/rust-lang/rust/issues/76560> for more information
    = note: `#[warn(incomplete_features)]` on by default
 
+error[E0046]: not all trait items implemented, missing: `Output`, `add`
+  --> $DIR/post-analysis-user-facing-param-env.rs:6:1
+   |
+LL | / impl<'a, const NUM: usize> std::ops::Add<&'a Foo> for Foo
+LL | |
+LL | |
+LL | | where
+LL | |     [(); 1 + 0]: Sized,
+   | |_______________________^ missing `Output`, `add` in implementation
+   |
+   = help: implement the missing item: `type Output = /* Type */;`
+   = help: implement the missing item: `fn add(self, _: &'a Foo) -> <Self as Add<&'a Foo>>::Output { todo!() }`
+
 error[E0207]: the const parameter `NUM` is not constrained by the impl trait, self type, or predicates
   --> $DIR/post-analysis-user-facing-param-env.rs:6:10
    |
@@ -27,7 +40,7 @@
    = note: proving the result of expressions other than the parameter are unique is not supported
 
 error[E0284]: type annotations needed
-  --> $DIR/post-analysis-user-facing-param-env.rs:11:40
+  --> $DIR/post-analysis-user-facing-param-env.rs:12:40
    |
 LL |     fn unimplemented(self, _: &Foo) -> Self::Output {
    |                                        ^^^^^^^^^^^^ cannot infer the value of const parameter `NUM`
@@ -40,7 +53,7 @@
    |          |
    |          unsatisfied trait bound introduced here
 
-error: aborting due to 3 previous errors; 1 warning emitted
+error: aborting due to 4 previous errors; 1 warning emitted
 
-Some errors have detailed explanations: E0207, E0284, E0407.
-For more information about an error, try `rustc --explain E0207`.
+Some errors have detailed explanations: E0046, E0207, E0284, E0407.
+For more information about an error, try `rustc --explain E0046`.
diff --git a/tests/ui/const-generics/generic_const_exprs/type_mismatch.stderr b/tests/ui/const-generics/generic_const_exprs/type_mismatch.stderr
index 7cb6725..3b4b579 100644
--- a/tests/ui/const-generics/generic_const_exprs/type_mismatch.stderr
+++ b/tests/ui/const-generics/generic_const_exprs/type_mismatch.stderr
@@ -1,11 +1,3 @@
-error: the constant `N` is not of type `usize`
-  --> $DIR/type_mismatch.rs:8:26
-   |
-LL | impl<const N: u64> Q for [u8; N] {}
-   |                          ^^^^^^^ expected `usize`, found `u64`
-   |
-   = note: the length of array `[u8; N]` must be type `usize`
-
 error[E0046]: not all trait items implemented, missing: `ASSOC`
   --> $DIR/type_mismatch.rs:8:1
    |
@@ -15,6 +7,14 @@
 LL | impl<const N: u64> Q for [u8; N] {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `ASSOC` in implementation
 
+error: the constant `N` is not of type `usize`
+  --> $DIR/type_mismatch.rs:8:26
+   |
+LL | impl<const N: u64> Q for [u8; N] {}
+   |                          ^^^^^^^ expected `usize`, found `u64`
+   |
+   = note: the length of array `[u8; N]` must be type `usize`
+
 error: the constant `13` is not of type `u64`
   --> $DIR/type_mismatch.rs:12:26
    |
diff --git a/tests/ui/const-generics/ice-unexpected-inference-var-122549.rs b/tests/ui/const-generics/ice-unexpected-inference-var-122549.rs
index 126ea66..34c7a25 100644
--- a/tests/ui/const-generics/ice-unexpected-inference-var-122549.rs
+++ b/tests/ui/const-generics/ice-unexpected-inference-var-122549.rs
@@ -15,6 +15,7 @@ struct ConstChunksExact<'rem, T: 'a, const N: usize> {}
 impl<'a, T, const N: usize> Iterator for ConstChunksExact<'a, T, {}> {
 //~^ ERROR the const parameter `N` is not constrained by the impl trait, self type, or predicates
 //~^^ ERROR mismatched types
+//~| ERROR missing: `next`
     type Item = &'a [T; N];
 }
 
diff --git a/tests/ui/const-generics/ice-unexpected-inference-var-122549.stderr b/tests/ui/const-generics/ice-unexpected-inference-var-122549.stderr
index 3b24808..311caae 100644
--- a/tests/ui/const-generics/ice-unexpected-inference-var-122549.stderr
+++ b/tests/ui/const-generics/ice-unexpected-inference-var-122549.stderr
@@ -49,6 +49,20 @@
    |
    = help: consider removing `T`, referring to it in a field, or using a marker such as `PhantomData`
 
+error[E0308]: mismatched types
+  --> $DIR/ice-unexpected-inference-var-122549.rs:15:66
+   |
+LL | impl<'a, T, const N: usize> Iterator for ConstChunksExact<'a, T, {}> {
+   |                                                                  ^^ expected `usize`, found `()`
+
+error[E0046]: not all trait items implemented, missing: `next`
+  --> $DIR/ice-unexpected-inference-var-122549.rs:15:1
+   |
+LL | impl<'a, T, const N: usize> Iterator for ConstChunksExact<'a, T, {}> {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `next` in implementation
+   |
+   = help: implement the missing item: `fn next(&mut self) -> Option<<Self as Iterator>::Item> { todo!() }`
+
 error[E0207]: the const parameter `N` is not constrained by the impl trait, self type, or predicates
   --> $DIR/ice-unexpected-inference-var-122549.rs:15:13
    |
@@ -58,13 +72,7 @@
    = note: expressions using a const parameter must map each value to a distinct output value
    = note: proving the result of expressions other than the parameter are unique is not supported
 
-error[E0308]: mismatched types
-  --> $DIR/ice-unexpected-inference-var-122549.rs:15:66
-   |
-LL | impl<'a, T, const N: usize> Iterator for ConstChunksExact<'a, T, {}> {
-   |                                                                  ^^ expected `usize`, found `()`
-
-error: aborting due to 7 previous errors
+error: aborting due to 8 previous errors
 
 Some errors have detailed explanations: E0046, E0207, E0261, E0308, E0392.
 For more information about an error, try `rustc --explain E0046`.
diff --git a/tests/ui/const-generics/issues/issue-71202.stderr b/tests/ui/const-generics/issues/issue-71202.stderr
index b7c3db4..dd0611a 100644
--- a/tests/ui/const-generics/issues/issue-71202.stderr
+++ b/tests/ui/const-generics/issues/issue-71202.stderr
@@ -7,7 +7,7 @@
 ...  |
 LL | |         <IsCopy<T>>::VALUE
 LL | |     } as usize] = [];
-   | |_____________________^
+   | |_______________^
    |
 help: try adding a `where` bound
    |
diff --git a/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.rs b/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.rs
index ba37087..9a39ab1 100644
--- a/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.rs
+++ b/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.rs
@@ -14,5 +14,6 @@ impl<'a, T: std::fmt::Debug, const N: usize> Iterator for ConstChunksExact<'a, T
     //~^ ERROR mismatched types [E0308]
     //~| ERROR the const parameter `N` is not constrained by the impl trait, self type, or predicates [E0207]
     type Item = &'a [T; N]; }
+    //~^ ERROR: `Item` specializes an item from a parent `impl`, but that item is not marked `default`
 
 fn main() {}
diff --git a/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.stderr b/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.stderr
index 1ee6864..ad89705 100644
--- a/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.stderr
+++ b/tests/ui/const-generics/normalizing_with_unconstrained_impl_params.stderr
@@ -34,6 +34,17 @@
    |
    = help: consider removing `T`, referring to it in a field, or using a marker such as `PhantomData`
 
+error[E0520]: `Item` specializes an item from a parent `impl`, but that item is not marked `default`
+  --> $DIR/normalizing_with_unconstrained_impl_params.rs:16:5
+   |
+LL | impl<'a, T: std::fmt::Debug, const N: usize> Iterator for ConstChunksExact<'a, T, { N }> {
+   | ---------------------------------------------------------------------------------------- parent `impl` is here
+...
+LL |     type Item = &'a [T; N]; }
+   |     ^^^^^^^^^ cannot specialize default item `Item`
+   |
+   = note: to specialize, `Item` in the parent `impl` must be marked `default`
+
 error[E0207]: the const parameter `N` is not constrained by the impl trait, self type, or predicates
   --> $DIR/normalizing_with_unconstrained_impl_params.rs:13:30
    |
@@ -54,7 +65,7 @@
    = note:   expected enum `Option<_>`
            found unit type `()`
 
-error: aborting due to 7 previous errors
+error: aborting due to 8 previous errors
 
-Some errors have detailed explanations: E0046, E0207, E0308, E0392, E0637.
+Some errors have detailed explanations: E0046, E0207, E0308, E0392, E0520, E0637.
 For more information about an error, try `rustc --explain E0046`.
diff --git a/tests/ui/const-generics/not_wf_param_in_rpitit.stderr b/tests/ui/const-generics/not_wf_param_in_rpitit.stderr
index 42ae012..3612cfa 100644
--- a/tests/ui/const-generics/not_wf_param_in_rpitit.stderr
+++ b/tests/ui/const-generics/not_wf_param_in_rpitit.stderr
@@ -11,7 +11,7 @@
    |                          ^^^^^
    |
    = note: ...which immediately requires computing type of `Trait::N` again
-note: cycle used when computing explicit predicates of trait `Trait`
+note: cycle used when checking that `Trait` is well-formed
   --> $DIR/not_wf_param_in_rpitit.rs:3:1
    |
 LL | trait Trait<const N: dyn Trait = bar> {
diff --git a/tests/ui/consts/array-repeat-expr-not-const.rs b/tests/ui/consts/array-repeat-expr-not-const.rs
new file mode 100644
index 0000000..55aee73
--- /dev/null
+++ b/tests/ui/consts/array-repeat-expr-not-const.rs
@@ -0,0 +1,10 @@
+//! Arrays created with `[value; length]` syntax need the length to be known at
+//! compile time. This test makes sure the compiler rejects runtime values like
+//! function parameters in the length position.
+
+fn main() {
+    fn create_array(n: usize) {
+        let _x = [0; n];
+        //~^ ERROR attempt to use a non-constant value in a constant [E0435]
+    }
+}
diff --git a/tests/ui/non-constant-expr-for-arr-len.stderr b/tests/ui/consts/array-repeat-expr-not-const.stderr
similarity index 61%
rename from tests/ui/non-constant-expr-for-arr-len.stderr
rename to tests/ui/consts/array-repeat-expr-not-const.stderr
index c9f977f..f576154 100644
--- a/tests/ui/non-constant-expr-for-arr-len.stderr
+++ b/tests/ui/consts/array-repeat-expr-not-const.stderr
@@ -1,8 +1,8 @@
 error[E0435]: attempt to use a non-constant value in a constant
-  --> $DIR/non-constant-expr-for-arr-len.rs:5:22
+  --> $DIR/array-repeat-expr-not-const.rs:7:22
    |
-LL |     fn bar(n: usize) {
-   |            - this would need to be a `const`
+LL |     fn create_array(n: usize) {
+   |                     - this would need to be a `const`
 LL |         let _x = [0; n];
    |                      ^
 
diff --git a/tests/ui/consts/const-fn-type-name.rs b/tests/ui/consts/const-fn-type-name.rs
index 5403c26..733ab79 100644
--- a/tests/ui/consts/const-fn-type-name.rs
+++ b/tests/ui/consts/const-fn-type-name.rs
@@ -5,7 +5,7 @@
 #![allow(dead_code)]
 
 const fn type_name_wrapper<T>(_: &T) -> &'static str {
-    core::intrinsics::type_name::<T>()
+    const { core::intrinsics::type_name::<T>() }
 }
 
 struct Struct<TA, TB, TC> {
diff --git a/tests/ui/consts/const-unsized.stderr b/tests/ui/consts/const-unsized.stderr
index cee364b..c92fbc1 100644
--- a/tests/ui/consts/const-unsized.stderr
+++ b/tests/ui/consts/const-unsized.stderr
@@ -17,19 +17,19 @@
    = note: statics and constants must have a statically known size
 
 error[E0277]: the size for values of type `(dyn Debug + Sync + 'static)` cannot be known at compilation time
-  --> $DIR/const-unsized.rs:11:18
+  --> $DIR/const-unsized.rs:11:1
    |
 LL | static STATIC_1: dyn Debug + Sync = *(&1 as &(dyn Debug + Sync));
-   |                  ^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `Sized` is not implemented for `(dyn Debug + Sync + 'static)`
    = note: statics and constants must have a statically known size
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/const-unsized.rs:15:20
+  --> $DIR/const-unsized.rs:15:1
    |
 LL | static STATIC_BAR: str = *"bar";
-   |                    ^^^ doesn't have a size known at compile-time
+   | ^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `Sized` is not implemented for `str`
    = note: statics and constants must have a statically known size
diff --git a/tests/ui/consts/const_refs_to_static-ice-121413.stderr b/tests/ui/consts/const_refs_to_static-ice-121413.stderr
index 3980a7e9..1263dee 100644
--- a/tests/ui/consts/const_refs_to_static-ice-121413.stderr
+++ b/tests/ui/consts/const_refs_to_static-ice-121413.stderr
@@ -24,10 +24,10 @@
    |                 +++
 
 error[E0277]: the size for values of type `(dyn Sync + 'static)` cannot be known at compilation time
-  --> $DIR/const_refs_to_static-ice-121413.rs:8:17
+  --> $DIR/const_refs_to_static-ice-121413.rs:8:5
    |
 LL |     static FOO: Sync = AtomicUsize::new(0);
-   |                 ^^^^ doesn't have a size known at compile-time
+   |     ^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `Sized` is not implemented for `(dyn Sync + 'static)`
    = note: statics and constants must have a statically known size
diff --git a/tests/ui/consts/dont-ctfe-unsized-initializer.stderr b/tests/ui/consts/dont-ctfe-unsized-initializer.stderr
index e69790f..5b0a016 100644
--- a/tests/ui/consts/dont-ctfe-unsized-initializer.stderr
+++ b/tests/ui/consts/dont-ctfe-unsized-initializer.stderr
@@ -1,8 +1,8 @@
 error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/dont-ctfe-unsized-initializer.rs:1:11
+  --> $DIR/dont-ctfe-unsized-initializer.rs:1:1
    |
 LL | static S: str = todo!();
-   |           ^^^ doesn't have a size known at compile-time
+   | ^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `Sized` is not implemented for `str`
    = note: statics and constants must have a statically known size
diff --git a/tests/ui/consts/issue-103790.stderr b/tests/ui/consts/issue-103790.stderr
index 1515fa6..adfac02 100644
--- a/tests/ui/consts/issue-103790.stderr
+++ b/tests/ui/consts/issue-103790.stderr
@@ -29,7 +29,7 @@
    |                                ^
    |
    = note: ...which immediately requires computing type of `S::S` again
-note: cycle used when computing explicit predicates of `S`
+note: cycle used when checking that `S` is well-formed
   --> $DIR/issue-103790.rs:4:1
    |
 LL | struct S<const S: (), const S: S = { S }>;
diff --git a/tests/ui/auxiliary/noexporttypelib.rs b/tests/ui/cross-crate/auxiliary/unexported-type-error-message.rs
similarity index 100%
rename from tests/ui/auxiliary/noexporttypelib.rs
rename to tests/ui/cross-crate/auxiliary/unexported-type-error-message.rs
diff --git a/tests/ui/noexporttypeexe.rs b/tests/ui/cross-crate/unexported-type-error-message.rs
similarity index 73%
rename from tests/ui/noexporttypeexe.rs
rename to tests/ui/cross-crate/unexported-type-error-message.rs
index 35257b2..5998f0d 100644
--- a/tests/ui/noexporttypeexe.rs
+++ b/tests/ui/cross-crate/unexported-type-error-message.rs
@@ -1,13 +1,13 @@
-//@ aux-build:noexporttypelib.rs
+//@ aux-build:unexported-type-error-message.rs
 
-extern crate noexporttypelib;
+extern crate unexported_type_error_message;
 
 fn main() {
     // Here, the type returned by foo() is not exported.
     // This used to cause internal errors when serializing
     // because the def_id associated with the type was
     // not convertible to a path.
-  let x: isize = noexporttypelib::foo();
+    let x: isize = unexported_type_error_message::foo();
     //~^ ERROR mismatched types
     //~| NOTE expected type `isize`
     //~| NOTE found enum `Option<isize>`
diff --git a/tests/ui/cross-crate/unexported-type-error-message.stderr b/tests/ui/cross-crate/unexported-type-error-message.stderr
new file mode 100644
index 0000000..b468d98
--- /dev/null
+++ b/tests/ui/cross-crate/unexported-type-error-message.stderr
@@ -0,0 +1,18 @@
+error[E0308]: mismatched types
+  --> $DIR/unexported-type-error-message.rs:10:20
+   |
+LL |     let x: isize = unexported_type_error_message::foo();
+   |            -----   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `isize`, found `Option<isize>`
+   |            |
+   |            expected due to this
+   |
+   = note: expected type `isize`
+              found enum `Option<isize>`
+help: consider using `Option::expect` to unwrap the `Option<isize>` value, panicking if the value is an `Option::None`
+   |
+LL |     let x: isize = unexported_type_error_message::foo().expect("REASON");
+   |                                                        +++++++++++++++++
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr
index 2e11a59..3e5579d 100644
--- a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr
+++ b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr
@@ -8,10 +8,8 @@
 note: cycle used when checking that `Chromosome` is well-formed
   --> $DIR/cycle-trait-supertrait-direct.rs:3:1
    |
-LL | / trait Chromosome: Chromosome {
-LL | |
-LL | | }
-   | |_^
+LL | trait Chromosome: Chromosome {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/cycle-trait/issue-12511.stderr b/tests/ui/cycle-trait/issue-12511.stderr
index 0246bf2..45fc86a 100644
--- a/tests/ui/cycle-trait/issue-12511.stderr
+++ b/tests/ui/cycle-trait/issue-12511.stderr
@@ -13,10 +13,8 @@
 note: cycle used when checking that `T1` is well-formed
   --> $DIR/issue-12511.rs:1:1
    |
-LL | / trait T1 : T2 {
-LL | |
-LL | | }
-   | |_^
+LL | trait T1 : T2 {
+   | ^^^^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/delegation/unsupported.stderr b/tests/ui/delegation/unsupported.stderr
index 53d05c3..f69be60 100644
--- a/tests/ui/delegation/unsupported.stderr
+++ b/tests/ui/delegation/unsupported.stderr
@@ -10,11 +10,11 @@
 LL |         reuse to_reuse::opaque_ret;
    |                         ^^^^^^^^^^
    = note: ...which again requires computing type of `opaque::<impl at $DIR/unsupported.rs:21:5: 21:24>::opaque_ret::{anon_assoc#0}`, completing the cycle
-note: cycle used when checking that `opaque::<impl at $DIR/unsupported.rs:21:5: 21:24>` is well-formed
-  --> $DIR/unsupported.rs:21:5
+note: cycle used when checking assoc item `opaque::<impl at $DIR/unsupported.rs:21:5: 21:24>::opaque_ret` is compatible with trait definition
+  --> $DIR/unsupported.rs:22:25
    |
-LL |     impl ToReuse for u8 {
-   |     ^^^^^^^^^^^^^^^^^^^
+LL |         reuse to_reuse::opaque_ret;
+   |                         ^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error[E0391]: cycle detected when computing type of `opaque::<impl at $DIR/unsupported.rs:24:5: 24:25>::opaque_ret::{anon_assoc#0}`
@@ -29,11 +29,11 @@
 LL |         reuse ToReuse::opaque_ret;
    |                        ^^^^^^^^^^
    = note: ...which again requires computing type of `opaque::<impl at $DIR/unsupported.rs:24:5: 24:25>::opaque_ret::{anon_assoc#0}`, completing the cycle
-note: cycle used when checking that `opaque::<impl at $DIR/unsupported.rs:24:5: 24:25>` is well-formed
-  --> $DIR/unsupported.rs:24:5
+note: cycle used when checking assoc item `opaque::<impl at $DIR/unsupported.rs:24:5: 24:25>::opaque_ret` is compatible with trait definition
+  --> $DIR/unsupported.rs:25:24
    |
-LL |     impl ToReuse for u16 {
-   |     ^^^^^^^^^^^^^^^^^^^^
+LL |         reuse ToReuse::opaque_ret;
+   |                        ^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: recursive delegation is not supported yet
diff --git a/tests/ui/derives/derive-Debug-enum-variants.rs b/tests/ui/derives/derive-Debug-enum-variants.rs
new file mode 100644
index 0000000..26f527f
--- /dev/null
+++ b/tests/ui/derives/derive-Debug-enum-variants.rs
@@ -0,0 +1,30 @@
+//! Test that `#[derive(Debug)]` for enums correctly formats variant names.
+
+//@ run-pass
+
+#[derive(Debug)]
+enum Foo {
+    A(usize),
+    C,
+}
+
+#[derive(Debug)]
+enum Bar {
+    D,
+}
+
+pub fn main() {
+    // Test variant with data
+    let foo_a = Foo::A(22);
+    assert_eq!("A(22)".to_string(), format!("{:?}", foo_a));
+
+    if let Foo::A(value) = foo_a {
+        println!("Value: {}", value); // This needs to remove #[allow(dead_code)]
+    }
+
+    // Test unit variant
+    assert_eq!("C".to_string(), format!("{:?}", Foo::C));
+
+    // Test unit variant from different enum
+    assert_eq!("D".to_string(), format!("{:?}", Bar::D));
+}
diff --git a/tests/ui/did_you_mean/bad-assoc-ty.edition2015.stderr b/tests/ui/did_you_mean/bad-assoc-ty.edition2015.stderr
index fe1ce5a..ed6e5c3 100644
--- a/tests/ui/did_you_mean/bad-assoc-ty.edition2015.stderr
+++ b/tests/ui/did_you_mean/bad-assoc-ty.edition2015.stderr
@@ -302,7 +302,7 @@
 LL | trait P<F> where F: Fn() -> _ {
    |                             ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/bad-assoc-ty.rs:88:38
    |
 LL |     fn foo<F>(_: F) where F: Fn() -> _ {}
diff --git a/tests/ui/did_you_mean/bad-assoc-ty.edition2021.stderr b/tests/ui/did_you_mean/bad-assoc-ty.edition2021.stderr
index 2cf7a15..2ee8ab2 100644
--- a/tests/ui/did_you_mean/bad-assoc-ty.edition2021.stderr
+++ b/tests/ui/did_you_mean/bad-assoc-ty.edition2021.stderr
@@ -284,7 +284,7 @@
 LL | trait P<F> where F: Fn() -> _ {
    |                             ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/bad-assoc-ty.rs:88:38
    |
 LL |     fn foo<F>(_: F) where F: Fn() -> _ {}
diff --git a/tests/ui/did_you_mean/bad-assoc-ty.rs b/tests/ui/did_you_mean/bad-assoc-ty.rs
index 9abda4f..39f0a84 100644
--- a/tests/ui/did_you_mean/bad-assoc-ty.rs
+++ b/tests/ui/did_you_mean/bad-assoc-ty.rs
@@ -86,7 +86,7 @@ trait P<F> where F: Fn() -> _ {
 
 trait Q {
     fn foo<F>(_: F) where F: Fn() -> _ {}
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
 }
 
 fn main() {}
diff --git a/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.fixed b/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.fixed
index db18cf2..0096d3e 100644
--- a/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.fixed
+++ b/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.fixed
@@ -7,7 +7,7 @@
 
 impl Foo<usize> for () {
     fn bar(i: i32, t: usize, s: &()) -> (usize, i32) {
-        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
         //~| ERROR type annotations needed
         (1, 2)
     }
diff --git a/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.rs b/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.rs
index 1217a96..9ebc565 100644
--- a/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.rs
+++ b/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.rs
@@ -7,7 +7,7 @@ trait Foo<T>: Sized {
 
 impl Foo<usize> for () {
     fn bar(i: _, t: _, s: _) -> _ {
-        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
         //~| ERROR type annotations needed
         (1, 2)
     }
diff --git a/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.stderr b/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.stderr
index 6c24a58..3c11ad0 100644
--- a/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.stderr
+++ b/tests/ui/did_you_mean/replace-impl-infer-ty-from-trait.stderr
@@ -1,4 +1,4 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/replace-impl-infer-ty-from-trait.rs:9:15
    |
 LL |     fn bar(i: _, t: _, s: _) -> _ {
diff --git a/tests/ui/drop/field-replace-in-struct-with-drop.rs b/tests/ui/drop/field-replace-in-struct-with-drop.rs
new file mode 100644
index 0000000..8c65a4b
--- /dev/null
+++ b/tests/ui/drop/field-replace-in-struct-with-drop.rs
@@ -0,0 +1,40 @@
+//! Circa 2016-06-05, `fn inline` below issued an
+//! erroneous warning from the elaborate_drops pass about moving out of
+//! a field in `Foo`, which has a destructor (and thus cannot have
+//! content moved out of it). The reason that the warning is erroneous
+//! in this case is that we are doing a *replace*, not a move, of the
+//! content in question, and it is okay to replace fields within `Foo`.
+//!
+//! Another more subtle problem was that the elaborate_drops was
+//! creating a separate drop flag for that internally replaced content,
+//! even though the compiler should enforce an invariant that any drop
+//! flag for such subcontent of `Foo` will always have the same value
+//! as the drop flag for `Foo` itself.
+//!
+//! Regression test for <https://github.com/rust-lang/rust/issues/34101>.
+
+//@ check-pass
+
+struct Foo(String);
+
+impl Drop for Foo {
+    fn drop(&mut self) {}
+}
+
+fn test_inline_replacement() {
+    // dummy variable so `f` gets assigned `var1` in MIR for both functions
+    let _s = ();
+    let mut f = Foo(String::from("foo"));
+    f.0 = String::from("bar"); // This should not warn
+}
+
+fn test_outline_replacement() {
+    let _s = String::from("foo");
+    let mut f = Foo(_s);
+    f.0 = String::from("bar"); // This should not warn either
+}
+
+fn main() {
+    test_inline_replacement();
+    test_outline_replacement();
+}
diff --git a/tests/ui/dropck/explicit-drop-bounds.bad1.stderr b/tests/ui/dropck/explicit-drop-bounds.bad1.stderr
index 28d7546..d898f2f 100644
--- a/tests/ui/dropck/explicit-drop-bounds.bad1.stderr
+++ b/tests/ui/dropck/explicit-drop-bounds.bad1.stderr
@@ -1,8 +1,8 @@
 error[E0277]: the trait bound `T: Copy` is not satisfied
-  --> $DIR/explicit-drop-bounds.rs:27:18
+  --> $DIR/explicit-drop-bounds.rs:32:5
    |
-LL | impl<T> Drop for DropMe<T>
-   |                  ^^^^^^^^^ the trait `Copy` is not implemented for `T`
+LL |     fn drop(&mut self) {}
+   |     ^^^^^^^^^^^^^^^^^^ the trait `Copy` is not implemented for `T`
    |
 note: required by a bound in `DropMe`
   --> $DIR/explicit-drop-bounds.rs:7:18
@@ -15,10 +15,10 @@
    |                   ++++++++++++++++++++
 
 error[E0277]: the trait bound `T: Copy` is not satisfied
-  --> $DIR/explicit-drop-bounds.rs:32:5
+  --> $DIR/explicit-drop-bounds.rs:27:18
    |
-LL |     fn drop(&mut self) {}
-   |     ^^^^^^^^^^^^^^^^^^ the trait `Copy` is not implemented for `T`
+LL | impl<T> Drop for DropMe<T>
+   |                  ^^^^^^^^^ the trait `Copy` is not implemented for `T`
    |
 note: required by a bound in `DropMe`
   --> $DIR/explicit-drop-bounds.rs:7:18
diff --git a/tests/ui/dropck/explicit-drop-bounds.bad2.stderr b/tests/ui/dropck/explicit-drop-bounds.bad2.stderr
index c363676..8155bd4 100644
--- a/tests/ui/dropck/explicit-drop-bounds.bad2.stderr
+++ b/tests/ui/dropck/explicit-drop-bounds.bad2.stderr
@@ -1,8 +1,8 @@
 error[E0277]: the trait bound `T: Copy` is not satisfied
-  --> $DIR/explicit-drop-bounds.rs:38:18
+  --> $DIR/explicit-drop-bounds.rs:41:5
    |
-LL | impl<T> Drop for DropMe<T>
-   |                  ^^^^^^^^^ the trait `Copy` is not implemented for `T`
+LL |     fn drop(&mut self) {}
+   |     ^^^^^^^^^^^^^^^^^^ the trait `Copy` is not implemented for `T`
    |
 note: required by a bound in `DropMe`
   --> $DIR/explicit-drop-bounds.rs:7:18
@@ -15,10 +15,10 @@
    |       +++++++++++++++++++
 
 error[E0277]: the trait bound `T: Copy` is not satisfied
-  --> $DIR/explicit-drop-bounds.rs:41:5
+  --> $DIR/explicit-drop-bounds.rs:38:18
    |
-LL |     fn drop(&mut self) {}
-   |     ^^^^^^^^^^^^^^^^^^ the trait `Copy` is not implemented for `T`
+LL | impl<T> Drop for DropMe<T>
+   |                  ^^^^^^^^^ the trait `Copy` is not implemented for `T`
    |
 note: required by a bound in `DropMe`
   --> $DIR/explicit-drop-bounds.rs:7:18
diff --git a/tests/ui/dropck/unconstrained_const_param_on_drop.rs b/tests/ui/dropck/unconstrained_const_param_on_drop.rs
index de77fa5..839aca0 100644
--- a/tests/ui/dropck/unconstrained_const_param_on_drop.rs
+++ b/tests/ui/dropck/unconstrained_const_param_on_drop.rs
@@ -3,5 +3,6 @@
 impl<const UNUSED: usize> Drop for Foo {}
 //~^ ERROR: `Drop` impl requires `the constant `_` has type `usize``
 //~| ERROR: the const parameter `UNUSED` is not constrained by the impl trait, self type, or predicates
+//~| ERROR: missing: `drop`
 
 fn main() {}
diff --git a/tests/ui/dropck/unconstrained_const_param_on_drop.stderr b/tests/ui/dropck/unconstrained_const_param_on_drop.stderr
index 8518885..515637d 100644
--- a/tests/ui/dropck/unconstrained_const_param_on_drop.stderr
+++ b/tests/ui/dropck/unconstrained_const_param_on_drop.stderr
@@ -10,6 +10,14 @@
 LL | struct Foo {}
    | ^^^^^^^^^^
 
+error[E0046]: not all trait items implemented, missing: `drop`
+  --> $DIR/unconstrained_const_param_on_drop.rs:3:1
+   |
+LL | impl<const UNUSED: usize> Drop for Foo {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `drop` in implementation
+   |
+   = help: implement the missing item: `fn drop(&mut self) { todo!() }`
+
 error[E0207]: the const parameter `UNUSED` is not constrained by the impl trait, self type, or predicates
   --> $DIR/unconstrained_const_param_on_drop.rs:3:6
    |
@@ -19,7 +27,7 @@
    = note: expressions using a const parameter must map each value to a distinct output value
    = note: proving the result of expressions other than the parameter are unique is not supported
 
-error: aborting due to 2 previous errors
+error: aborting due to 3 previous errors
 
-Some errors have detailed explanations: E0207, E0367.
-For more information about an error, try `rustc --explain E0207`.
+Some errors have detailed explanations: E0046, E0207, E0367.
+For more information about an error, try `rustc --explain E0046`.
diff --git a/tests/ui/dyn-star/align.normal.stderr b/tests/ui/dyn-star/align.normal.stderr
deleted file mode 100644
index d3ee0d3..0000000
--- a/tests/ui/dyn-star/align.normal.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/align.rs:3:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-error[E0277]: `AlignedUsize` needs to have the same ABI as a pointer
-  --> $DIR/align.rs:14:13
-   |
-LL |     let x = AlignedUsize(12) as dyn* Debug;
-   |             ^^^^^^^^^^^^^^^^ `AlignedUsize` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `AlignedUsize`
-
-error: aborting due to 1 previous error; 1 warning emitted
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/align.over_aligned.stderr b/tests/ui/dyn-star/align.over_aligned.stderr
deleted file mode 100644
index d3ee0d3..0000000
--- a/tests/ui/dyn-star/align.over_aligned.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/align.rs:3:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-error[E0277]: `AlignedUsize` needs to have the same ABI as a pointer
-  --> $DIR/align.rs:14:13
-   |
-LL |     let x = AlignedUsize(12) as dyn* Debug;
-   |             ^^^^^^^^^^^^^^^^ `AlignedUsize` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `AlignedUsize`
-
-error: aborting due to 1 previous error; 1 warning emitted
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/align.rs b/tests/ui/dyn-star/align.rs
deleted file mode 100644
index f9ef706..0000000
--- a/tests/ui/dyn-star/align.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-//@ revisions: normal over_aligned
-
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-
-use std::fmt::Debug;
-
-#[cfg_attr(over_aligned,      repr(C, align(1024)))]
-#[cfg_attr(not(over_aligned), repr(C))]
-#[derive(Debug)]
-struct AlignedUsize(usize);
-
-fn main() {
-    let x = AlignedUsize(12) as dyn* Debug;
-    //~^ ERROR `AlignedUsize` needs to have the same ABI as a pointer
-}
diff --git a/tests/ui/dyn-star/async-block-dyn-star.rs b/tests/ui/dyn-star/async-block-dyn-star.rs
deleted file mode 100644
index db133d9..0000000
--- a/tests/ui/dyn-star/async-block-dyn-star.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-//@ edition:2018
-
-#![feature(dyn_star, const_async_blocks)]
-//~^ WARN the feature `dyn_star` is incomplete
-
-static S: dyn* Send + Sync = async { 42 };
-//~^ ERROR needs to have the same ABI as a pointer
-
-pub fn main() {}
diff --git a/tests/ui/dyn-star/async-block-dyn-star.stderr b/tests/ui/dyn-star/async-block-dyn-star.stderr
deleted file mode 100644
index f62c85c..0000000
--- a/tests/ui/dyn-star/async-block-dyn-star.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/async-block-dyn-star.rs:3:12
-   |
-LL | #![feature(dyn_star, const_async_blocks)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-error[E0277]: `{async block@$DIR/async-block-dyn-star.rs:6:30: 6:35}` needs to have the same ABI as a pointer
-  --> $DIR/async-block-dyn-star.rs:6:30
-   |
-LL | static S: dyn* Send + Sync = async { 42 };
-   |                              ^^^^^^^^^^^^ `{async block@$DIR/async-block-dyn-star.rs:6:30: 6:35}` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `{async block@$DIR/async-block-dyn-star.rs:6:30: 6:35}`
-
-error: aborting due to 1 previous error; 1 warning emitted
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/auxiliary/dyn-star-foreign.rs b/tests/ui/dyn-star/auxiliary/dyn-star-foreign.rs
deleted file mode 100644
index ce89208..0000000
--- a/tests/ui/dyn-star/auxiliary/dyn-star-foreign.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-#![feature(dyn_star)]
-
-use std::fmt::Display;
-
-pub fn require_dyn_star_display(_: dyn* Display) {}
-
-fn works_locally() {
-    require_dyn_star_display(1usize);
-}
diff --git a/tests/ui/dyn-star/box.rs b/tests/ui/dyn-star/box.rs
deleted file mode 100644
index f1c9fd1..0000000
--- a/tests/ui/dyn-star/box.rs
+++ /dev/null
@@ -1,20 +0,0 @@
-//@ run-pass
-//@ revisions: current next
-//@ ignore-compare-mode-next-solver (explicit revisions)
-//@[current] compile-flags: -C opt-level=0
-//@[next] compile-flags: -Znext-solver -C opt-level=0
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Display;
-
-fn make_dyn_star() -> dyn* Display {
-    Box::new(42) as dyn* Display
-}
-
-fn main() {
-    let x = make_dyn_star();
-
-    println!("{x}");
-}
diff --git a/tests/ui/dyn-star/cell.rs b/tests/ui/dyn-star/cell.rs
deleted file mode 100644
index f4c7927..0000000
--- a/tests/ui/dyn-star/cell.rs
+++ /dev/null
@@ -1,34 +0,0 @@
-// This test with Cell also indirectly exercises UnsafeCell in dyn*.
-//
-//@ run-pass
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::cell::Cell;
-
-trait Rw<T> {
-    fn read(&self) -> T;
-    fn write(&self, v: T);
-}
-
-impl<T: Copy> Rw<T> for Cell<T> {
-    fn read(&self) -> T {
-        self.get()
-    }
-    fn write(&self, v: T) {
-        self.set(v)
-    }
-}
-
-fn make_dyn_star() -> dyn* Rw<usize> {
-    Cell::new(42usize) as dyn* Rw<usize>
-}
-
-fn main() {
-    let x = make_dyn_star();
-
-    assert_eq!(x.read(), 42);
-    x.write(24);
-    assert_eq!(x.read(), 24);
-}
diff --git a/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.current.stderr b/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.current.stderr
deleted file mode 100644
index a0aff69..0000000
--- a/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.current.stderr
+++ /dev/null
@@ -1,18 +0,0 @@
-error[E0277]: `&T` needs to have the same ABI as a pointer
-  --> $DIR/check-size-at-cast-polymorphic-bad.rs:15:15
-   |
-LL | fn polymorphic<T: Debug + ?Sized>(t: &T) {
-   |                - this type parameter needs to be `Sized`
-LL |     dyn_debug(t);
-   |               ^ `&T` needs to be a pointer-like type
-   |
-   = note: required for `&T` to implement `PointerLike`
-help: consider removing the `?Sized` bound to make the type parameter `Sized`
-   |
-LL - fn polymorphic<T: Debug + ?Sized>(t: &T) {
-LL + fn polymorphic<T: Debug>(t: &T) {
-   |
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.next.stderr b/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.next.stderr
deleted file mode 100644
index a0aff69..0000000
--- a/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.next.stderr
+++ /dev/null
@@ -1,18 +0,0 @@
-error[E0277]: `&T` needs to have the same ABI as a pointer
-  --> $DIR/check-size-at-cast-polymorphic-bad.rs:15:15
-   |
-LL | fn polymorphic<T: Debug + ?Sized>(t: &T) {
-   |                - this type parameter needs to be `Sized`
-LL |     dyn_debug(t);
-   |               ^ `&T` needs to be a pointer-like type
-   |
-   = note: required for `&T` to implement `PointerLike`
-help: consider removing the `?Sized` bound to make the type parameter `Sized`
-   |
-LL - fn polymorphic<T: Debug + ?Sized>(t: &T) {
-LL + fn polymorphic<T: Debug>(t: &T) {
-   |
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.rs b/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.rs
deleted file mode 100644
index acc293a..0000000
--- a/tests/ui/dyn-star/check-size-at-cast-polymorphic-bad.rs
+++ /dev/null
@@ -1,19 +0,0 @@
-//@ revisions: current next
-//@ ignore-compare-mode-next-solver (explicit revisions)
-//@[next] compile-flags: -Znext-solver
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-
-fn dyn_debug(_: (dyn* Debug + '_)) {
-
-}
-
-fn polymorphic<T: Debug + ?Sized>(t: &T) {
-    dyn_debug(t);
-    //~^ ERROR `&T` needs to have the same ABI as a pointer
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/check-size-at-cast-polymorphic.rs b/tests/ui/dyn-star/check-size-at-cast-polymorphic.rs
deleted file mode 100644
index ceedbaf..0000000
--- a/tests/ui/dyn-star/check-size-at-cast-polymorphic.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-//@ check-pass
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-
-fn dyn_debug(_: (dyn* Debug + '_)) {
-
-}
-
-fn polymorphic<T: Debug>(t: &T) {
-    dyn_debug(t);
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/check-size-at-cast.rs b/tests/ui/dyn-star/check-size-at-cast.rs
deleted file mode 100644
index e15e090..0000000
--- a/tests/ui/dyn-star/check-size-at-cast.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-
-fn main() {
-    let i = [1, 2, 3, 4] as dyn* Debug;
-    //~^ ERROR `[i32; 4]` needs to have the same ABI as a pointer
-    dbg!(i);
-}
diff --git a/tests/ui/dyn-star/check-size-at-cast.stderr b/tests/ui/dyn-star/check-size-at-cast.stderr
deleted file mode 100644
index b402403..0000000
--- a/tests/ui/dyn-star/check-size-at-cast.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0277]: `[i32; 4]` needs to have the same ABI as a pointer
-  --> $DIR/check-size-at-cast.rs:7:13
-   |
-LL |     let i = [1, 2, 3, 4] as dyn* Debug;
-   |             ^^^^^^^^^^^^ `[i32; 4]` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `[i32; 4]`
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/const-and-static.rs b/tests/ui/dyn-star/const-and-static.rs
deleted file mode 100644
index cbb6426..0000000
--- a/tests/ui/dyn-star/const-and-static.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-//@ check-pass
-
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete
-
-const C: dyn* Send + Sync = &();
-
-static S: dyn* Send + Sync = &();
-
-fn main() {}
diff --git a/tests/ui/dyn-star/const-and-static.stderr b/tests/ui/dyn-star/const-and-static.stderr
deleted file mode 100644
index df8f42f..0000000
--- a/tests/ui/dyn-star/const-and-static.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/const-and-static.rs:3:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/dyn-star/const.rs b/tests/ui/dyn-star/const.rs
deleted file mode 100644
index 036d678..0000000
--- a/tests/ui/dyn-star/const.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-//@ run-pass
-#![feature(dyn_star)]
-#![allow(unused, incomplete_features)]
-
-use std::fmt::Debug;
-
-fn make_dyn_star() {
-    let i = 42usize;
-    let dyn_i: dyn* Debug = i;
-}
-
-fn main() {
-    make_dyn_star();
-}
diff --git a/tests/ui/dyn-star/dispatch-on-pin-mut.rs b/tests/ui/dyn-star/dispatch-on-pin-mut.rs
deleted file mode 100644
index be40fa3..0000000
--- a/tests/ui/dyn-star/dispatch-on-pin-mut.rs
+++ /dev/null
@@ -1,36 +0,0 @@
-//@ run-pass
-//@ edition:2021
-//@ check-run-results
-
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-
-use std::future::Future;
-
-async fn foo(f: dyn* Future<Output = i32>) {
-    println!("value: {}", f.await);
-}
-
-async fn async_main() {
-    foo(Box::pin(async { 1 })).await
-}
-
-// ------------------------------------------------------------------------- //
-// Implementation Details Below...
-
-use std::pin::pin;
-use std::task::*;
-
-fn main() {
-    let mut fut = pin!(async_main());
-
-    // Poll loop, just to test the future...
-    let ctx = &mut Context::from_waker(Waker::noop());
-
-    loop {
-        match fut.as_mut().poll(ctx) {
-            Poll::Pending => {}
-            Poll::Ready(()) => break,
-        }
-    }
-}
diff --git a/tests/ui/dyn-star/dispatch-on-pin-mut.run.stdout b/tests/ui/dyn-star/dispatch-on-pin-mut.run.stdout
deleted file mode 100644
index 96c5ca6..0000000
--- a/tests/ui/dyn-star/dispatch-on-pin-mut.run.stdout
+++ /dev/null
@@ -1 +0,0 @@
-value: 1
diff --git a/tests/ui/dyn-star/dispatch-on-pin-mut.stderr b/tests/ui/dyn-star/dispatch-on-pin-mut.stderr
deleted file mode 100644
index cb9c781..0000000
--- a/tests/ui/dyn-star/dispatch-on-pin-mut.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/dispatch-on-pin-mut.rs:5:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.rs b/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.rs
deleted file mode 100644
index abc66df..0000000
--- a/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.rs
+++ /dev/null
@@ -1,27 +0,0 @@
-//@ run-pass
-//@ check-run-results
-
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-
-trait AddOne {
-    fn add1(&mut self) -> usize;
-}
-
-impl AddOne for usize {
-    fn add1(&mut self) -> usize {
-        *self += 1;
-        *self
-    }
-}
-
-fn add_one(i: &mut (dyn* AddOne + '_)) -> usize {
-    i.add1()
-}
-
-fn main() {
-    let mut x = 42usize as dyn* AddOne;
-
-    println!("{}", add_one(&mut x));
-    println!("{}", add_one(&mut x));
-}
diff --git a/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.run.stdout b/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.run.stdout
deleted file mode 100644
index b4db3ed..0000000
--- a/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.run.stdout
+++ /dev/null
@@ -1,2 +0,0 @@
-43
-44
diff --git a/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.stderr b/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.stderr
deleted file mode 100644
index bcd014f..0000000
--- a/tests/ui/dyn-star/dont-unsize-coerce-dyn-star.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/dont-unsize-coerce-dyn-star.rs:4:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/dyn-star/drop.rs b/tests/ui/dyn-star/drop.rs
deleted file mode 100644
index bc74633..0000000
--- a/tests/ui/dyn-star/drop.rs
+++ /dev/null
@@ -1,28 +0,0 @@
-//@ run-pass
-//@ check-run-results
-#![feature(dyn_star, pointer_like_trait)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-use std::marker::PointerLike;
-
-#[derive(Debug)]
-#[repr(transparent)]
-struct Foo(#[allow(dead_code)] usize);
-
-// FIXME(dyn_star): Make this into a derive.
-impl PointerLike for Foo {}
-
-impl Drop for Foo {
-    fn drop(&mut self) {
-        println!("destructor called");
-    }
-}
-
-fn make_dyn_star(i: Foo) {
-    let _dyn_i: dyn* Debug = i;
-}
-
-fn main() {
-    make_dyn_star(Foo(42));
-}
diff --git a/tests/ui/dyn-star/drop.run.stdout b/tests/ui/dyn-star/drop.run.stdout
deleted file mode 100644
index dadb33c..0000000
--- a/tests/ui/dyn-star/drop.run.stdout
+++ /dev/null
@@ -1 +0,0 @@
-destructor called
diff --git a/tests/ui/dyn-star/dyn-async-trait.rs b/tests/ui/dyn-star/dyn-async-trait.rs
deleted file mode 100644
index a673b26..0000000
--- a/tests/ui/dyn-star/dyn-async-trait.rs
+++ /dev/null
@@ -1,36 +0,0 @@
-//@ check-pass
-//@ edition: 2021
-
-// This test case is meant to demonstrate how close we can get to async
-// functions in dyn traits with the current level of dyn* support.
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::future::Future;
-
-trait DynAsyncCounter {
-    fn increment<'a>(&'a mut self) -> dyn* Future<Output = usize> + 'a;
-}
-
-struct MyCounter {
-    count: usize,
-}
-
-impl DynAsyncCounter for MyCounter {
-    fn increment<'a>(&'a mut self) -> dyn* Future<Output = usize> + 'a {
-        Box::pin(async {
-            self.count += 1;
-            self.count
-        })
-    }
-}
-
-async fn do_counter(counter: &mut dyn DynAsyncCounter) -> usize {
-    counter.increment().await
-}
-
-fn main() {
-    let mut counter = MyCounter { count: 0 };
-    let _ = do_counter(&mut counter);
-}
diff --git a/tests/ui/dyn-star/dyn-pointer-like.rs b/tests/ui/dyn-star/dyn-pointer-like.rs
deleted file mode 100644
index f26fa90..0000000
--- a/tests/ui/dyn-star/dyn-pointer-like.rs
+++ /dev/null
@@ -1,23 +0,0 @@
-// Test that `dyn PointerLike` and `dyn* PointerLike` do not implement `PointerLike`.
-// This used to ICE during codegen.
-
-#![crate_type = "lib"]
-
-#![feature(pointer_like_trait, dyn_star)]
-#![feature(unsized_fn_params)]
-#![expect(incomplete_features)]
-#![expect(internal_features)]
-
-use std::marker::PointerLike;
-
-pub fn lol(x: dyn* PointerLike) {
-    foo(x); //~ ERROR `dyn* PointerLike` needs to have the same ABI as a pointer
-}
-
-pub fn uwu(x: dyn PointerLike) {
-    foo(x); //~ ERROR `dyn PointerLike` needs to have the same ABI as a pointer
-}
-
-fn foo<T: PointerLike + ?Sized>(x: T) {
-    let _: dyn* PointerLike = x;
-}
diff --git a/tests/ui/dyn-star/dyn-pointer-like.stderr b/tests/ui/dyn-star/dyn-pointer-like.stderr
deleted file mode 100644
index 4c558e9..0000000
--- a/tests/ui/dyn-star/dyn-pointer-like.stderr
+++ /dev/null
@@ -1,39 +0,0 @@
-error[E0277]: `dyn* PointerLike` needs to have the same ABI as a pointer
-  --> $DIR/dyn-pointer-like.rs:14:9
-   |
-LL |     foo(x);
-   |     --- ^ the trait `PointerLike` is not implemented for `dyn* PointerLike`
-   |     |
-   |     required by a bound introduced by this call
-   |
-   = note: the trait bound `dyn* PointerLike: PointerLike` is not satisfied
-note: required by a bound in `foo`
-  --> $DIR/dyn-pointer-like.rs:21:11
-   |
-LL | fn foo<T: PointerLike + ?Sized>(x: T) {
-   |           ^^^^^^^^^^^ required by this bound in `foo`
-help: consider borrowing here
-   |
-LL |     foo(&x);
-   |         +
-LL |     foo(&mut x);
-   |         ++++
-
-error[E0277]: `dyn PointerLike` needs to have the same ABI as a pointer
-  --> $DIR/dyn-pointer-like.rs:18:9
-   |
-LL |     foo(x);
-   |     --- ^ `dyn PointerLike` needs to be a pointer-like type
-   |     |
-   |     required by a bound introduced by this call
-   |
-   = help: the trait `PointerLike` is not implemented for `dyn PointerLike`
-note: required by a bound in `foo`
-  --> $DIR/dyn-pointer-like.rs:21:11
-   |
-LL | fn foo<T: PointerLike + ?Sized>(x: T) {
-   |           ^^^^^^^^^^^ required by this bound in `foo`
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/dyn-star-to-dyn.rs b/tests/ui/dyn-star/dyn-star-to-dyn.rs
deleted file mode 100644
index 99f673d..0000000
--- a/tests/ui/dyn-star/dyn-star-to-dyn.rs
+++ /dev/null
@@ -1,17 +0,0 @@
-//@ run-pass
-
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-
-use std::fmt::Debug;
-
-fn main() {
-    let x: dyn* Debug = &42;
-    let x = Box::new(x) as Box<dyn Debug>;
-    assert_eq!("42", format!("{x:?}"));
-
-    // Also test opposite direction.
-    let x: Box<dyn Debug> = Box::new(42);
-    let x = &x as dyn* Debug;
-    assert_eq!("42", format!("{x:?}"));
-}
diff --git a/tests/ui/dyn-star/dyn-star-to-dyn.stderr b/tests/ui/dyn-star/dyn-star-to-dyn.stderr
deleted file mode 100644
index 03aedf5..0000000
--- a/tests/ui/dyn-star/dyn-star-to-dyn.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/dyn-star-to-dyn.rs:3:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/dyn-star/dyn-to-rigid.rs b/tests/ui/dyn-star/dyn-to-rigid.rs
deleted file mode 100644
index dc33e28..0000000
--- a/tests/ui/dyn-star/dyn-to-rigid.rs
+++ /dev/null
@@ -1,11 +0,0 @@
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-trait Tr {}
-
-fn f(x: dyn* Tr) -> usize {
-    x as usize
-    //~^ ERROR non-primitive cast: `(dyn* Tr + 'static)` as `usize`
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/dyn-to-rigid.stderr b/tests/ui/dyn-star/dyn-to-rigid.stderr
deleted file mode 100644
index 49b8f26..0000000
--- a/tests/ui/dyn-star/dyn-to-rigid.stderr
+++ /dev/null
@@ -1,9 +0,0 @@
-error[E0605]: non-primitive cast: `(dyn* Tr + 'static)` as `usize`
-  --> $DIR/dyn-to-rigid.rs:7:5
-   |
-LL |     x as usize
-   |     ^^^^^^^^^^ an `as` expression can only be used to convert between primitive types or to coerce to a specific trait object
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0605`.
diff --git a/tests/ui/dyn-star/enum-cast.rs b/tests/ui/dyn-star/enum-cast.rs
deleted file mode 100644
index 3cc7390..0000000
--- a/tests/ui/dyn-star/enum-cast.rs
+++ /dev/null
@@ -1,23 +0,0 @@
-//@ check-pass
-
-// This used to ICE, because the compiler confused a pointer-like to dyn* coercion
-// with a c-like enum to integer cast.
-
-#![feature(dyn_star, pointer_like_trait)]
-#![expect(incomplete_features)]
-
-use std::marker::PointerLike;
-
-#[repr(transparent)]
-enum E {
-    Num(usize),
-}
-
-impl PointerLike for E {}
-
-trait Trait {}
-impl Trait for E {}
-
-fn main() {
-    let _ = E::Num(42) as dyn* Trait;
-}
diff --git a/tests/ui/dyn-star/error.rs b/tests/ui/dyn-star/error.rs
deleted file mode 100644
index 1d252d2..0000000
--- a/tests/ui/dyn-star/error.rs
+++ /dev/null
@@ -1,13 +0,0 @@
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-
-trait Foo {}
-
-fn make_dyn_star() {
-    let i = 42usize;
-    let dyn_i: dyn* Foo = i; //~ ERROR trait bound `usize: Foo` is not satisfied
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/error.stderr b/tests/ui/dyn-star/error.stderr
deleted file mode 100644
index 55981c0..0000000
--- a/tests/ui/dyn-star/error.stderr
+++ /dev/null
@@ -1,15 +0,0 @@
-error[E0277]: the trait bound `usize: Foo` is not satisfied
-  --> $DIR/error.rs:10:27
-   |
-LL |     let dyn_i: dyn* Foo = i;
-   |                           ^ the trait `Foo` is not implemented for `usize`
-   |
-help: this trait has no implementations, consider adding one
-  --> $DIR/error.rs:6:1
-   |
-LL | trait Foo {}
-   | ^^^^^^^^^
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/feature-gate-dyn_star.rs b/tests/ui/dyn-star/feature-gate-dyn_star.rs
deleted file mode 100644
index b12fd77..0000000
--- a/tests/ui/dyn-star/feature-gate-dyn_star.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-// Feature gate test for dyn_star
-
-/// dyn* is not necessarily the final surface syntax (if we have one at all),
-/// but for now we will support it to aid in writing tests independently.
-pub fn dyn_star_parameter(_: &dyn* Send) {
-    //~^ ERROR `dyn*` trait objects are experimental
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/feature-gate-dyn_star.stderr b/tests/ui/dyn-star/feature-gate-dyn_star.stderr
deleted file mode 100644
index c3e99b2..0000000
--- a/tests/ui/dyn-star/feature-gate-dyn_star.stderr
+++ /dev/null
@@ -1,13 +0,0 @@
-error[E0658]: `dyn*` trait objects are experimental
-  --> $DIR/feature-gate-dyn_star.rs:5:31
-   |
-LL | pub fn dyn_star_parameter(_: &dyn* Send) {
-   |                               ^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = help: add `#![feature(dyn_star)]` to the crate attributes to enable
-   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/dyn-star/float-as-dyn-star.rs b/tests/ui/dyn-star/float-as-dyn-star.rs
deleted file mode 100644
index 1b629c6..0000000
--- a/tests/ui/dyn-star/float-as-dyn-star.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-//@ only-x86_64
-
-#![feature(dyn_star, pointer_like_trait)]
-//~^ WARN the feature `dyn_star` is incomplete
-
-use std::fmt::Debug;
-use std::marker::PointerLike;
-
-fn make_dyn_star() -> dyn* Debug + 'static {
-    f32::from_bits(0x1) as f64
-    //~^ ERROR `f64` needs to have the same ABI as a pointer
-}
-
-fn main() {
-    println!("{:?}", make_dyn_star());
-}
diff --git a/tests/ui/dyn-star/float-as-dyn-star.stderr b/tests/ui/dyn-star/float-as-dyn-star.stderr
deleted file mode 100644
index 06071a2..0000000
--- a/tests/ui/dyn-star/float-as-dyn-star.stderr
+++ /dev/null
@@ -1,23 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/float-as-dyn-star.rs:3:12
-   |
-LL | #![feature(dyn_star, pointer_like_trait)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-error[E0277]: `f64` needs to have the same ABI as a pointer
-  --> $DIR/float-as-dyn-star.rs:10:5
-   |
-LL |     f32::from_bits(0x1) as f64
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^ `f64` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `f64`
-   = help: the following other types implement trait `PointerLike`:
-             isize
-             usize
-
-error: aborting due to 1 previous error; 1 warning emitted
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/gated-span.rs b/tests/ui/dyn-star/gated-span.rs
deleted file mode 100644
index a747987..0000000
--- a/tests/ui/dyn-star/gated-span.rs
+++ /dev/null
@@ -1,8 +0,0 @@
-macro_rules! t {
-    ($t:ty) => {}
-}
-
-t!(dyn* Send);
-//~^ ERROR `dyn*` trait objects are experimental
-
-fn main() {}
diff --git a/tests/ui/dyn-star/gated-span.stderr b/tests/ui/dyn-star/gated-span.stderr
deleted file mode 100644
index 8ba6d79..0000000
--- a/tests/ui/dyn-star/gated-span.stderr
+++ /dev/null
@@ -1,13 +0,0 @@
-error[E0658]: `dyn*` trait objects are experimental
-  --> $DIR/gated-span.rs:5:4
-   |
-LL | t!(dyn* Send);
-   |    ^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = help: add `#![feature(dyn_star)]` to the crate attributes to enable
-   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0658`.
diff --git a/tests/ui/dyn-star/illegal.rs b/tests/ui/dyn-star/illegal.rs
deleted file mode 100644
index ce0d784..0000000
--- a/tests/ui/dyn-star/illegal.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete
-
-trait Foo {}
-
-pub fn lol(x: dyn* Foo + Send) {
-    x as dyn* Foo;
-    //~^ ERROR casting `(dyn* Foo + Send + 'static)` as `dyn* Foo` is invalid
-}
-
-fn lol2(x: &dyn Foo) {
-    *x as dyn* Foo;
-    //~^ ERROR `dyn Foo` needs to have the same ABI as a pointer
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/illegal.stderr b/tests/ui/dyn-star/illegal.stderr
deleted file mode 100644
index fdf3c81..0000000
--- a/tests/ui/dyn-star/illegal.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/illegal.rs:1:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-error[E0606]: casting `(dyn* Foo + Send + 'static)` as `dyn* Foo` is invalid
-  --> $DIR/illegal.rs:7:5
-   |
-LL |     x as dyn* Foo;
-   |     ^^^^^^^^^^^^^
-
-error[E0277]: `dyn Foo` needs to have the same ABI as a pointer
-  --> $DIR/illegal.rs:12:5
-   |
-LL |     *x as dyn* Foo;
-   |     ^^ `dyn Foo` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `dyn Foo`
-
-error: aborting due to 2 previous errors; 1 warning emitted
-
-Some errors have detailed explanations: E0277, E0606.
-For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/issue-102430.rs b/tests/ui/dyn-star/issue-102430.rs
deleted file mode 100644
index 4e48d5e..0000000
--- a/tests/ui/dyn-star/issue-102430.rs
+++ /dev/null
@@ -1,32 +0,0 @@
-//@ check-pass
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-trait AddOne {
-    fn add1(&mut self) -> usize;
-}
-
-impl AddOne for usize {
-    fn add1(&mut self) -> usize {
-        *self += 1;
-        *self
-    }
-}
-
-impl AddOne for &mut usize {
-    fn add1(&mut self) -> usize {
-        (*self).add1()
-    }
-}
-
-fn add_one(mut i: dyn* AddOne + '_) -> usize {
-    i.add1()
-}
-
-fn main() {
-    let mut x = 42usize;
-    let y = &mut x as (dyn* AddOne + '_);
-
-    println!("{}", add_one(y));
-}
diff --git a/tests/ui/dyn-star/make-dyn-star.rs b/tests/ui/dyn-star/make-dyn-star.rs
deleted file mode 100644
index 2400433..0000000
--- a/tests/ui/dyn-star/make-dyn-star.rs
+++ /dev/null
@@ -1,18 +0,0 @@
-//@ run-pass
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-
-fn make_dyn_star(i: usize) {
-    let _dyn_i: dyn* Debug = i;
-}
-
-fn make_dyn_star_explicit(i: usize) {
-    let _dyn_i: dyn* Debug = i as dyn* Debug;
-}
-
-fn main() {
-    make_dyn_star(42);
-    make_dyn_star_explicit(42);
-}
diff --git a/tests/ui/dyn-star/method.rs b/tests/ui/dyn-star/method.rs
deleted file mode 100644
index 0d0855e..0000000
--- a/tests/ui/dyn-star/method.rs
+++ /dev/null
@@ -1,27 +0,0 @@
-//@ run-pass
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-trait Foo {
-    fn get(&self) -> usize;
-}
-
-impl Foo for usize {
-    fn get(&self) -> usize {
-        *self
-    }
-}
-
-fn invoke_dyn_star(i: dyn* Foo) -> usize {
-    i.get()
-}
-
-fn make_and_invoke_dyn_star(i: usize) -> usize {
-    let dyn_i: dyn* Foo = i;
-    invoke_dyn_star(dyn_i)
-}
-
-fn main() {
-    println!("{}", make_and_invoke_dyn_star(42));
-}
diff --git a/tests/ui/dyn-star/no-explicit-dyn-star-cast.rs b/tests/ui/dyn-star/no-explicit-dyn-star-cast.rs
deleted file mode 100644
index 2d28f51..0000000
--- a/tests/ui/dyn-star/no-explicit-dyn-star-cast.rs
+++ /dev/null
@@ -1,13 +0,0 @@
-use std::fmt::Debug;
-
-fn make_dyn_star() {
-    let i = 42usize;
-    let dyn_i: dyn* Debug = i as dyn* Debug;
-    //~^ ERROR casting `usize` as `dyn* Debug` is invalid
-    //~| ERROR `dyn*` trait objects are experimental
-    //~| ERROR `dyn*` trait objects are experimental
-}
-
-fn main() {
-    make_dyn_star();
-}
diff --git a/tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr b/tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr
deleted file mode 100644
index bb4c612..0000000
--- a/tests/ui/dyn-star/no-explicit-dyn-star-cast.stderr
+++ /dev/null
@@ -1,30 +0,0 @@
-error[E0658]: `dyn*` trait objects are experimental
-  --> $DIR/no-explicit-dyn-star-cast.rs:5:16
-   |
-LL |     let dyn_i: dyn* Debug = i as dyn* Debug;
-   |                ^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = help: add `#![feature(dyn_star)]` to the crate attributes to enable
-   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
-
-error[E0658]: `dyn*` trait objects are experimental
-  --> $DIR/no-explicit-dyn-star-cast.rs:5:34
-   |
-LL |     let dyn_i: dyn* Debug = i as dyn* Debug;
-   |                                  ^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = help: add `#![feature(dyn_star)]` to the crate attributes to enable
-   = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
-
-error[E0606]: casting `usize` as `dyn* Debug` is invalid
-  --> $DIR/no-explicit-dyn-star-cast.rs:5:29
-   |
-LL |     let dyn_i: dyn* Debug = i as dyn* Debug;
-   |                             ^^^^^^^^^^^^^^^
-
-error: aborting due to 3 previous errors
-
-Some errors have detailed explanations: E0606, E0658.
-For more information about an error, try `rustc --explain E0606`.
diff --git a/tests/ui/dyn-star/no-explicit-dyn-star.rs b/tests/ui/dyn-star/no-explicit-dyn-star.rs
deleted file mode 100644
index 0847597..0000000
--- a/tests/ui/dyn-star/no-explicit-dyn-star.rs
+++ /dev/null
@@ -1,8 +0,0 @@
-//@ aux-build:dyn-star-foreign.rs
-
-extern crate dyn_star_foreign;
-
-fn main() {
-    dyn_star_foreign::require_dyn_star_display(1usize as _);
-    //~^ ERROR casting `usize` as `dyn* std::fmt::Display` is invalid
-}
diff --git a/tests/ui/dyn-star/no-explicit-dyn-star.stderr b/tests/ui/dyn-star/no-explicit-dyn-star.stderr
deleted file mode 100644
index 641404a..0000000
--- a/tests/ui/dyn-star/no-explicit-dyn-star.stderr
+++ /dev/null
@@ -1,9 +0,0 @@
-error[E0606]: casting `usize` as `dyn* std::fmt::Display` is invalid
-  --> $DIR/no-explicit-dyn-star.rs:6:48
-   |
-LL |     dyn_star_foreign::require_dyn_star_display(1usize as _);
-   |                                                ^^^^^^^^^^^
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0606`.
diff --git a/tests/ui/dyn-star/no-implicit-dyn-star.rs b/tests/ui/dyn-star/no-implicit-dyn-star.rs
deleted file mode 100644
index 7af3f9a..0000000
--- a/tests/ui/dyn-star/no-implicit-dyn-star.rs
+++ /dev/null
@@ -1,8 +0,0 @@
-//@ aux-build:dyn-star-foreign.rs
-
-extern crate dyn_star_foreign;
-
-fn main() {
-    dyn_star_foreign::require_dyn_star_display(1usize);
-    //~^ ERROR mismatched types
-}
diff --git a/tests/ui/dyn-star/no-implicit-dyn-star.stderr b/tests/ui/dyn-star/no-implicit-dyn-star.stderr
deleted file mode 100644
index d1d3da9..0000000
--- a/tests/ui/dyn-star/no-implicit-dyn-star.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-error[E0308]: mismatched types
-  --> $DIR/no-implicit-dyn-star.rs:6:48
-   |
-LL |     dyn_star_foreign::require_dyn_star_display(1usize);
-   |     ------------------------------------------ ^^^^^^ expected `dyn Display`, found `usize`
-   |     |
-   |     arguments to this function are incorrect
-   |
-   = note: expected trait object `(dyn* std::fmt::Display + 'static)`
-                      found type `usize`
-   = help: `usize` implements `Display`, `#[feature(dyn_star)]` is likely not enabled; that feature it is currently incomplete
-note: function defined here
-  --> $DIR/auxiliary/dyn-star-foreign.rs:5:8
-   |
-LL | pub fn require_dyn_star_display(_: dyn* Display) {}
-   |        ^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/dyn-star/no-unsize-coerce-dyn-trait.rs b/tests/ui/dyn-star/no-unsize-coerce-dyn-trait.rs
deleted file mode 100644
index 1702fc1..0000000
--- a/tests/ui/dyn-star/no-unsize-coerce-dyn-trait.rs
+++ /dev/null
@@ -1,13 +0,0 @@
-#![expect(incomplete_features)]
-#![feature(dyn_star)]
-
-trait A: B {}
-trait B {}
-impl A for usize {}
-impl B for usize {}
-
-fn main() {
-    let x: Box<dyn* A> = Box::new(1usize as dyn* A);
-    let y: Box<dyn* B> = x;
-    //~^ ERROR mismatched types
-}
diff --git a/tests/ui/dyn-star/no-unsize-coerce-dyn-trait.stderr b/tests/ui/dyn-star/no-unsize-coerce-dyn-trait.stderr
deleted file mode 100644
index 289d850..0000000
--- a/tests/ui/dyn-star/no-unsize-coerce-dyn-trait.stderr
+++ /dev/null
@@ -1,14 +0,0 @@
-error[E0308]: mismatched types
-  --> $DIR/no-unsize-coerce-dyn-trait.rs:11:26
-   |
-LL |     let y: Box<dyn* B> = x;
-   |            -----------   ^ expected trait `B`, found trait `A`
-   |            |
-   |            expected due to this
-   |
-   = note: expected struct `Box<dyn* B>`
-              found struct `Box<dyn* A>`
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/dyn-star/param-env-region-infer.current.stderr b/tests/ui/dyn-star/param-env-region-infer.current.stderr
deleted file mode 100644
index 6e464c1..0000000
--- a/tests/ui/dyn-star/param-env-region-infer.current.stderr
+++ /dev/null
@@ -1,9 +0,0 @@
-error[E0282]: type annotations needed
-  --> $DIR/param-env-region-infer.rs:20:10
-   |
-LL |     t as _
-   |          ^ cannot infer type
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0282`.
diff --git a/tests/ui/dyn-star/param-env-region-infer.rs b/tests/ui/dyn-star/param-env-region-infer.rs
deleted file mode 100644
index 842964a..0000000
--- a/tests/ui/dyn-star/param-env-region-infer.rs
+++ /dev/null
@@ -1,24 +0,0 @@
-//@ revisions: current
-//@ incremental
-
-// FIXME(-Znext-solver): This currently results in unstable query results:
-// `normalizes-to(opaque, opaque)` changes from `Maybe(Ambiguous)` to `Maybe(Overflow)`
-// once the hidden type of the opaque is already defined to be itself.
-//@ unused-revision-names: next
-
-// checks that we don't ICE if there are region inference variables in the environment
-// when computing `PointerLike` builtin candidates.
-
-#![feature(dyn_star, pointer_like_trait)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-use std::marker::PointerLike;
-
-fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a {
-    //[next]~^ ERROR cycle detected when computing
-    t as _
-    //[current]~^ ERROR type annotations needed
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/pointer-like-impl-rules.rs b/tests/ui/dyn-star/pointer-like-impl-rules.rs
deleted file mode 100644
index c234e86..0000000
--- a/tests/ui/dyn-star/pointer-like-impl-rules.rs
+++ /dev/null
@@ -1,82 +0,0 @@
-//@ check-fail
-
-#![feature(extern_types)]
-#![feature(pointer_like_trait)]
-
-use std::marker::PointerLike;
-
-struct NotReprTransparent;
-impl PointerLike for NotReprTransparent {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: the struct `NotReprTransparent` is not `repr(transparent)`
-
-#[repr(transparent)]
-struct FieldIsPl(usize);
-impl PointerLike for FieldIsPl {}
-
-#[repr(transparent)]
-struct FieldIsPlAndHasOtherField(usize, ());
-impl PointerLike for FieldIsPlAndHasOtherField {}
-
-#[repr(transparent)]
-struct FieldIsNotPl(u8);
-impl PointerLike for FieldIsNotPl {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: the field `0` of struct `FieldIsNotPl` does not implement `PointerLike`
-
-#[repr(transparent)]
-struct GenericFieldIsNotPl<T>(T);
-impl<T> PointerLike for GenericFieldIsNotPl<T> {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: the field `0` of struct `GenericFieldIsNotPl<T>` does not implement `PointerLike`
-
-#[repr(transparent)]
-struct GenericFieldIsPl<T>(T);
-impl<T: PointerLike> PointerLike for GenericFieldIsPl<T> {}
-
-#[repr(transparent)]
-struct IsZeroSized(());
-impl PointerLike for IsZeroSized {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: the struct `IsZeroSized` is `repr(transparent)`, but does not have a non-trivial field
-
-trait SomeTrait {}
-impl PointerLike for dyn SomeTrait {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: types of dynamic or unknown size
-
-extern "C" {
-    type ExternType;
-}
-impl PointerLike for ExternType {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: types of dynamic or unknown size
-
-struct LocalSizedType(&'static str);
-struct LocalUnsizedType(str);
-
-// This is not a special error but a normal coherence error,
-// which should still happen.
-impl PointerLike for &LocalSizedType {}
-//~^ ERROR: conflicting implementations of trait `PointerLike`
-//~| NOTE: conflicting implementation in crate `core`
-
-impl PointerLike for &LocalUnsizedType {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: references to dynamically-sized types are too large to be `PointerLike`
-
-impl PointerLike for Box<LocalSizedType> {}
-//~^ ERROR: conflicting implementations of trait `PointerLike`
-//~| NOTE: conflicting implementation in crate `alloc`
-
-impl PointerLike for Box<LocalUnsizedType> {}
-//~^ ERROR: implementation must be applied to type that
-//~| NOTE: boxes of dynamically-sized types are too large to be `PointerLike`
-
-fn expects_pointer_like(x: impl PointerLike) {}
-
-fn main() {
-    expects_pointer_like(FieldIsPl(1usize));
-    expects_pointer_like(FieldIsPlAndHasOtherField(1usize, ()));
-    expects_pointer_like(GenericFieldIsPl(1usize));
-}
diff --git a/tests/ui/dyn-star/pointer-like-impl-rules.stderr b/tests/ui/dyn-star/pointer-like-impl-rules.stderr
deleted file mode 100644
index 39f08f4..0000000
--- a/tests/ui/dyn-star/pointer-like-impl-rules.stderr
+++ /dev/null
@@ -1,85 +0,0 @@
-error[E0119]: conflicting implementations of trait `PointerLike` for type `&LocalSizedType`
-  --> $DIR/pointer-like-impl-rules.rs:60:1
-   |
-LL | impl PointerLike for &LocalSizedType {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: conflicting implementation in crate `core`:
-           - impl<T> PointerLike for &T;
-
-error[E0119]: conflicting implementations of trait `PointerLike` for type `Box<LocalSizedType>`
-  --> $DIR/pointer-like-impl-rules.rs:68:1
-   |
-LL | impl PointerLike for Box<LocalSizedType> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: conflicting implementation in crate `alloc`:
-           - impl<T> PointerLike for Box<T>;
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:9:1
-   |
-LL | impl PointerLike for NotReprTransparent {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: the struct `NotReprTransparent` is not `repr(transparent)`
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:23:1
-   |
-LL | impl PointerLike for FieldIsNotPl {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: the field `0` of struct `FieldIsNotPl` does not implement `PointerLike`
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:29:1
-   |
-LL | impl<T> PointerLike for GenericFieldIsNotPl<T> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: the field `0` of struct `GenericFieldIsNotPl<T>` does not implement `PointerLike`
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:39:1
-   |
-LL | impl PointerLike for IsZeroSized {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: the struct `IsZeroSized` is `repr(transparent)`, but does not have a non-trivial field (it is zero-sized)
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:44:1
-   |
-LL | impl PointerLike for dyn SomeTrait {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: types of dynamic or unknown size may not implement `PointerLike`
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:51:1
-   |
-LL | impl PointerLike for ExternType {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: types of dynamic or unknown size may not implement `PointerLike`
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:64:1
-   |
-LL | impl PointerLike for &LocalUnsizedType {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: references to dynamically-sized types are too large to be `PointerLike`
-
-error: implementation must be applied to type that has the same ABI as a pointer, or is `repr(transparent)` and whose field is `PointerLike`
-  --> $DIR/pointer-like-impl-rules.rs:72:1
-   |
-LL | impl PointerLike for Box<LocalUnsizedType> {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: boxes of dynamically-sized types are too large to be `PointerLike`
-
-error: aborting due to 10 previous errors
-
-For more information about this error, try `rustc --explain E0119`.
diff --git a/tests/ui/dyn-star/return.rs b/tests/ui/dyn-star/return.rs
deleted file mode 100644
index 47d95d1..0000000
--- a/tests/ui/dyn-star/return.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-//@ check-pass
-
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-
-fn _foo() -> dyn* Unpin {
-    4usize
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/return.stderr b/tests/ui/dyn-star/return.stderr
deleted file mode 100644
index 9c26568..0000000
--- a/tests/ui/dyn-star/return.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/return.rs:3:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/dyn-star/syntax.rs b/tests/ui/dyn-star/syntax.rs
deleted file mode 100644
index d498340..0000000
--- a/tests/ui/dyn-star/syntax.rs
+++ /dev/null
@@ -1,11 +0,0 @@
-// Make sure we can parse the `dyn* Trait` syntax
-//
-//@ check-pass
-
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-pub fn dyn_star_parameter(_: dyn* Send) {
-}
-
-fn main() {}
diff --git a/tests/ui/dyn-star/thin.next.stderr b/tests/ui/dyn-star/thin.next.stderr
deleted file mode 100644
index ef25106..0000000
--- a/tests/ui/dyn-star/thin.next.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/thin.rs:6:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/dyn-star/thin.old.stderr b/tests/ui/dyn-star/thin.old.stderr
deleted file mode 100644
index ef25106..0000000
--- a/tests/ui/dyn-star/thin.old.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/thin.rs:6:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-warning: 1 warning emitted
-
diff --git a/tests/ui/dyn-star/thin.rs b/tests/ui/dyn-star/thin.rs
deleted file mode 100644
index 6df70f5..0000000
--- a/tests/ui/dyn-star/thin.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-//@check-pass
-//@revisions: old next
-//@[next] compile-flags: -Znext-solver
-
-#![feature(ptr_metadata)]
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-
-use std::fmt::Debug;
-use std::ptr::Thin;
-
-fn check_thin<T: ?Sized + Thin>() {}
-
-fn main() {
-    check_thin::<dyn* Debug>();
-}
diff --git a/tests/ui/dyn-star/union.rs b/tests/ui/dyn-star/union.rs
deleted file mode 100644
index ad3a85a..0000000
--- a/tests/ui/dyn-star/union.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-#![feature(dyn_star)]
-//~^ WARN the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-
-union Union {
-    x: usize,
-}
-
-trait Trait {}
-impl Trait for Union {}
-
-fn bar(_: dyn* Trait) {}
-
-fn main() {
-    bar(Union { x: 0usize });
-    //~^ ERROR `Union` needs to have the same ABI as a pointer
-}
diff --git a/tests/ui/dyn-star/union.stderr b/tests/ui/dyn-star/union.stderr
deleted file mode 100644
index 906eb4f..0000000
--- a/tests/ui/dyn-star/union.stderr
+++ /dev/null
@@ -1,20 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/union.rs:1:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-error[E0277]: `Union` needs to have the same ABI as a pointer
-  --> $DIR/union.rs:14:9
-   |
-LL |     bar(Union { x: 0usize });
-   |         ^^^^^^^^^^^^^^^^^^^ `Union` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `Union`
-
-error: aborting due to 1 previous error; 1 warning emitted
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/dyn-star/unsize-into-ref-dyn-star.rs b/tests/ui/dyn-star/unsize-into-ref-dyn-star.rs
deleted file mode 100644
index 1e8cafe..0000000
--- a/tests/ui/dyn-star/unsize-into-ref-dyn-star.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-use std::fmt::Debug;
-
-fn main() {
-    let i = 42 as &dyn* Debug;
-    //~^ ERROR non-primitive cast: `i32` as `&dyn* Debug`
-}
diff --git a/tests/ui/dyn-star/unsize-into-ref-dyn-star.stderr b/tests/ui/dyn-star/unsize-into-ref-dyn-star.stderr
deleted file mode 100644
index b327458..0000000
--- a/tests/ui/dyn-star/unsize-into-ref-dyn-star.stderr
+++ /dev/null
@@ -1,9 +0,0 @@
-error[E0605]: non-primitive cast: `i32` as `&dyn* Debug`
-  --> $DIR/unsize-into-ref-dyn-star.rs:7:13
-   |
-LL |     let i = 42 as &dyn* Debug;
-   |             ^^^^^^^^^^^^^^^^^ an `as` expression can only be used to convert between primitive types or to coerce to a specific trait object
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0605`.
diff --git a/tests/ui/dyn-star/upcast.rs b/tests/ui/dyn-star/upcast.rs
deleted file mode 100644
index 01e1b94..0000000
--- a/tests/ui/dyn-star/upcast.rs
+++ /dev/null
@@ -1,32 +0,0 @@
-//@ known-bug: #104800
-
-#![feature(dyn_star)]
-
-trait Foo: Bar {
-    fn hello(&self);
-}
-
-trait Bar {
-    fn world(&self);
-}
-
-struct W(usize);
-
-impl Foo for W {
-    fn hello(&self) {
-        println!("hello!");
-    }
-}
-
-impl Bar for W {
-    fn world(&self) {
-        println!("world!");
-    }
-}
-
-fn main() {
-    let w: dyn* Foo = W(0);
-    w.hello();
-    let w: dyn* Bar = w;
-    w.world();
-}
diff --git a/tests/ui/dyn-star/upcast.stderr b/tests/ui/dyn-star/upcast.stderr
deleted file mode 100644
index 3f244d4..0000000
--- a/tests/ui/dyn-star/upcast.stderr
+++ /dev/null
@@ -1,28 +0,0 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/upcast.rs:3:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
-error[E0277]: `W` needs to have the same ABI as a pointer
-  --> $DIR/upcast.rs:28:23
-   |
-LL |     let w: dyn* Foo = W(0);
-   |                       ^^^^ `W` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `W`
-
-error[E0277]: `dyn* Foo` needs to have the same ABI as a pointer
-  --> $DIR/upcast.rs:30:23
-   |
-LL |     let w: dyn* Bar = w;
-   |                       ^ `dyn* Foo` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `dyn* Foo`
-
-error: aborting due to 2 previous errors; 1 warning emitted
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/enum-discriminant/eval-error.stderr b/tests/ui/enum-discriminant/eval-error.stderr
index c29d258..7744965 100644
--- a/tests/ui/enum-discriminant/eval-error.stderr
+++ b/tests/ui/enum-discriminant/eval-error.stderr
@@ -15,6 +15,18 @@
 LL | | }
    | |_- not a struct or union
 
+error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
+  --> $DIR/eval-error.rs:2:5
+   |
+LL |     a: str,
+   |     ^^^^^^
+   |
+   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
+help: wrap the field type in `ManuallyDrop<...>`
+   |
+LL |     a: std::mem::ManuallyDrop<str>,
+   |        +++++++++++++++++++++++   +
+
 error[E0277]: the size for values of type `str` cannot be known at compilation time
   --> $DIR/eval-error.rs:2:8
    |
@@ -33,18 +45,6 @@
 LL |     a: Box<str>,
    |        ++++   +
 
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/eval-error.rs:2:5
-   |
-LL |     a: str,
-   |     ^^^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     a: std::mem::ManuallyDrop<str>,
-   |        +++++++++++++++++++++++   +
-
 error[E0080]: the type `Foo` has an unknown layout
   --> $DIR/eval-error.rs:9:30
    |
diff --git a/tests/ui/extern/issue-36122-accessing-externed-dst.stderr b/tests/ui/extern/issue-36122-accessing-externed-dst.stderr
index 6f805ae..8007c3f 100644
--- a/tests/ui/extern/issue-36122-accessing-externed-dst.stderr
+++ b/tests/ui/extern/issue-36122-accessing-externed-dst.stderr
@@ -1,8 +1,8 @@
 error[E0277]: the size for values of type `[usize]` cannot be known at compilation time
-  --> $DIR/issue-36122-accessing-externed-dst.rs:3:24
+  --> $DIR/issue-36122-accessing-externed-dst.rs:3:9
    |
 LL |         static symbol: [usize];
-   |                        ^^^^^^^ doesn't have a size known at compile-time
+   |         ^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `Sized` is not implemented for `[usize]`
    = note: statics and constants must have a statically known size
diff --git a/tests/ui/extern/issue-47725.rs b/tests/ui/extern/issue-47725.rs
index 012673b..60d0cd6 100644
--- a/tests/ui/extern/issue-47725.rs
+++ b/tests/ui/extern/issue-47725.rs
@@ -17,7 +17,6 @@
 #[link_name]
 //~^ ERROR malformed `link_name` attribute input
 //~| HELP must be of the form
-//~| NOTE expected this to be of the form `link_name = "..."
 extern "C" {
     fn bar() -> u32;
 }
diff --git a/tests/ui/extern/issue-47725.stderr b/tests/ui/extern/issue-47725.stderr
index 53d6b49..4fd02a1 100644
--- a/tests/ui/extern/issue-47725.stderr
+++ b/tests/ui/extern/issue-47725.stderr
@@ -2,10 +2,7 @@
   --> $DIR/issue-47725.rs:17:1
    |
 LL | #[link_name]
-   | ^^^^^^^^^^^^
-   | |
-   | expected this to be of the form `link_name = "..."`
-   | help: must be of the form: `#[link_name = "name"]`
+   | ^^^^^^^^^^^^ help: must be of the form: `#[link_name = "name"]`
 
 warning: attribute should be applied to a foreign function or static
   --> $DIR/issue-47725.rs:3:1
diff --git a/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr b/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
index 7768c25..334bc63 100644
--- a/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
+++ b/tests/ui/feature-gates/feature-gate-unboxed-closures-manual-impls.stderr
@@ -56,6 +56,19 @@
    |
    = help: add `#![feature(unboxed_closures)]` to the crate attributes to enable
 
+error[E0053]: method `call` has an incompatible type for trait
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:13:32
+   |
+LL |     extern "rust-call" fn call(self, args: ()) -> () {}
+   |                                ^^^^ expected `&Foo`, found `Foo`
+   |
+   = note: expected signature `extern "rust-call" fn(&Foo, ()) -> _`
+              found signature `extern "rust-call" fn(Foo, ()) -> ()`
+help: change the self-receiver type to match the trait
+   |
+LL |     extern "rust-call" fn call(&self, args: ()) -> () {}
+   |                                +
+
 error[E0658]: the precise format of `Fn`-family traits' type parameters is subject to change
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:26:6
    |
@@ -85,19 +98,6 @@
 note: required by a bound in `Fn`
   --> $SRC_DIR/core/src/ops/function.rs:LL:COL
 
-error[E0053]: method `call` has an incompatible type for trait
-  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:13:32
-   |
-LL |     extern "rust-call" fn call(self, args: ()) -> () {}
-   |                                ^^^^ expected `&Foo`, found `Foo`
-   |
-   = note: expected signature `extern "rust-call" fn(&Foo, ()) -> _`
-              found signature `extern "rust-call" fn(Foo, ()) -> ()`
-help: change the self-receiver type to match the trait
-   |
-LL |     extern "rust-call" fn call(&self, args: ()) -> () {}
-   |                                +
-
 error[E0183]: manual implementations of `FnOnce` are experimental
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:18:6
    |
@@ -144,17 +144,6 @@
    |
    = help: implement the missing item: `type Output = /* Type */;`
 
-error[E0277]: expected a `FnOnce()` closure, found `Bar`
-  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:26:20
-   |
-LL | impl FnMut<()> for Bar {
-   |                    ^^^ expected an `FnOnce()` closure, found `Bar`
-   |
-   = help: the trait `FnOnce()` is not implemented for `Bar`
-   = note: wrap the `Bar` in a closure with no arguments: `|| { /* code */ }`
-note: required by a bound in `FnMut`
-  --> $SRC_DIR/core/src/ops/function.rs:LL:COL
-
 error[E0053]: method `call_mut` has an incompatible type for trait
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:30:36
    |
@@ -168,6 +157,17 @@
 LL |     extern "rust-call" fn call_mut(&mut self, args: ()) -> () {}
    |                                     +++
 
+error[E0277]: expected a `FnOnce()` closure, found `Bar`
+  --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:26:20
+   |
+LL | impl FnMut<()> for Bar {
+   |                    ^^^ expected an `FnOnce()` closure, found `Bar`
+   |
+   = help: the trait `FnOnce()` is not implemented for `Bar`
+   = note: wrap the `Bar` in a closure with no arguments: `|| { /* code */ }`
+note: required by a bound in `FnMut`
+  --> $SRC_DIR/core/src/ops/function.rs:LL:COL
+
 error[E0046]: not all trait items implemented, missing: `Output`
   --> $DIR/feature-gate-unboxed-closures-manual-impls.rs:35:1
    |
diff --git a/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs.stderr b/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs.stderr
index 1243ed5..02b9e2f 100644
--- a/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs.stderr
+++ b/tests/ui/feature-gates/issue-43106-gating-of-builtin-attrs.stderr
@@ -387,14 +387,6 @@
    |
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
 
-warning: attribute should be applied to a function or static
-  --> $DIR/issue-43106-gating-of-builtin-attrs.rs:69:1
-   |
-LL | #![link_section = "1800"]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^ not a function or static
-   |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
-
 warning: attribute should be applied to a function definition
   --> $DIR/issue-43106-gating-of-builtin-attrs.rs:62:1
    |
@@ -411,6 +403,14 @@
    |
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
 
+warning: attribute should be applied to a function or static
+  --> $DIR/issue-43106-gating-of-builtin-attrs.rs:69:1
+   |
+LL | #![link_section = "1800"]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^ not a function or static
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+
 warning: `#[must_use]` has no effect when applied to a module
   --> $DIR/issue-43106-gating-of-builtin-attrs.rs:72:1
    |
diff --git a/tests/ui/logging-only-prints-once.rs b/tests/ui/fmt/debug-single-call.rs
similarity index 73%
rename from tests/ui/logging-only-prints-once.rs
rename to tests/ui/fmt/debug-single-call.rs
index bb8c296..b59a766 100644
--- a/tests/ui/logging-only-prints-once.rs
+++ b/tests/ui/fmt/debug-single-call.rs
@@ -1,9 +1,12 @@
+//! Test that Debug::fmt is called exactly once during formatting.
+//!
+//! This is a regression test for PR https://github.com/rust-lang/rust/pull/10715
+
 //@ run-pass
 //@ needs-threads
 
 use std::cell::Cell;
-use std::fmt;
-use std::thread;
+use std::{fmt, thread};
 
 struct Foo(Cell<isize>);
 
diff --git a/tests/ui/fn/error-recovery-mismatch.stderr b/tests/ui/fn/error-recovery-mismatch.stderr
index c046302..10dab30 100644
--- a/tests/ui/fn/error-recovery-mismatch.stderr
+++ b/tests/ui/fn/error-recovery-mismatch.stderr
@@ -29,7 +29,7 @@
    = note: for more information, see issue #41686 <https://github.com/rust-lang/rust/issues/41686>
    = note: `#[warn(anonymous_parameters)]` on by default
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/error-recovery-mismatch.rs:11:35
    |
 LL |     fn fold<T>(&self, _: T, &self._) {}
diff --git a/tests/ui/fn/issue-39259.stderr b/tests/ui/fn/issue-39259.stderr
index a923d7b..90e305c 100644
--- a/tests/ui/fn/issue-39259.stderr
+++ b/tests/ui/fn/issue-39259.stderr
@@ -10,6 +10,14 @@
 LL | impl Fn(u32) -> u32 for S {
    |      ^^^^^^^^^^^^^^
 
+error[E0050]: method `call` has 1 parameter but the declaration in trait `call` has 2
+  --> $DIR/issue-39259.rs:9:13
+   |
+LL |     fn call(&self) -> u32 {
+   |             ^^^^^ expected 2 parameters, found 1
+   |
+   = note: `call` from trait: `extern "rust-call" fn(&Self, Args) -> <Self as FnOnce<Args>>::Output`
+
 error[E0277]: expected a `FnMut(u32)` closure, found `S`
   --> $DIR/issue-39259.rs:6:25
    |
@@ -20,14 +28,6 @@
 note: required by a bound in `Fn`
   --> $SRC_DIR/core/src/ops/function.rs:LL:COL
 
-error[E0050]: method `call` has 1 parameter but the declaration in trait `call` has 2
-  --> $DIR/issue-39259.rs:9:13
-   |
-LL |     fn call(&self) -> u32 {
-   |             ^^^^^ expected 2 parameters, found 1
-   |
-   = note: `call` from trait: `extern "rust-call" fn(&Self, Args) -> <Self as FnOnce<Args>>::Output`
-
 error: aborting due to 3 previous errors
 
 Some errors have detailed explanations: E0050, E0229, E0277.
diff --git a/tests/ui/generic-associated-types/bugs/issue-87735.stderr b/tests/ui/generic-associated-types/bugs/issue-87735.stderr
index 1b95543..c3f4f7a 100644
--- a/tests/ui/generic-associated-types/bugs/issue-87735.stderr
+++ b/tests/ui/generic-associated-types/bugs/issue-87735.stderr
@@ -5,12 +5,13 @@
    |             ^ unconstrained type parameter
 
 error[E0309]: the parameter type `U` may not live long enough
-  --> $DIR/issue-87735.rs:34:21
+  --> $DIR/issue-87735.rs:34:3
    |
 LL |   type Output<'a> = FooRef<'a, U> where Self: 'a;
-   |               --    ^^^^^^^^^^^^^ ...so that the type `U` will meet its required lifetime bounds...
-   |               |
-   |               the parameter type `U` must be valid for the lifetime `'a` as defined here...
+   |   ^^^^^^^^^^^^--^
+   |   |           |
+   |   |           the parameter type `U` must be valid for the lifetime `'a` as defined here...
+   |   ...so that the type `U` will meet its required lifetime bounds...
    |
 note: ...that is required by this bound
   --> $DIR/issue-87735.rs:23:22
diff --git a/tests/ui/generic-associated-types/bugs/issue-88526.stderr b/tests/ui/generic-associated-types/bugs/issue-88526.stderr
index 5da3e3f..5e39eb7 100644
--- a/tests/ui/generic-associated-types/bugs/issue-88526.stderr
+++ b/tests/ui/generic-associated-types/bugs/issue-88526.stderr
@@ -5,12 +5,13 @@
    |             ^ unconstrained type parameter
 
 error[E0309]: the parameter type `F` may not live long enough
-  --> $DIR/issue-88526.rs:16:18
+  --> $DIR/issue-88526.rs:16:5
    |
 LL |     type I<'a> = &'a F;
-   |            --    ^^^^^ ...so that the reference type `&'a F` does not outlive the data it points at
-   |            |
-   |            the parameter type `F` must be valid for the lifetime `'a` as defined here...
+   |     ^^^^^^^--^
+   |     |      |
+   |     |      the parameter type `F` must be valid for the lifetime `'a` as defined here...
+   |     ...so that the reference type `&'a F` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |
diff --git a/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.rs b/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.rs
index d00c036..81e2db1 100644
--- a/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.rs
+++ b/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.rs
@@ -9,6 +9,7 @@ impl <T, T1> Foo for T {
     type F<T1> = &[u8];
       //~^ ERROR: the name `T1` is already used for
       //~| ERROR: `&` without an explicit lifetime name cannot be used here
+      //~| ERROR: has 1 type parameter but its trait declaration has 0 type parameters
 }
 
 fn main() {}
diff --git a/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.stderr b/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.stderr
index cb2b9f3..42aa83c 100644
--- a/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.stderr
+++ b/tests/ui/generic-associated-types/gat-trait-path-generic-type-arg.stderr
@@ -13,13 +13,22 @@
 LL |     type F<T1> = &[u8];
    |                  ^ explicit lifetime name needed here
 
+error[E0049]: associated type `F` has 1 type parameter but its trait declaration has 0 type parameters
+  --> $DIR/gat-trait-path-generic-type-arg.rs:9:12
+   |
+LL |     type F<'a>;
+   |            -- expected 0 type parameters
+...
+LL |     type F<T1> = &[u8];
+   |            ^^ found 1 type parameter
+
 error[E0207]: the type parameter `T1` is not constrained by the impl trait, self type, or predicates
   --> $DIR/gat-trait-path-generic-type-arg.rs:7:10
    |
 LL | impl <T, T1> Foo for T {
    |          ^^ unconstrained type parameter
 
-error: aborting due to 3 previous errors
+error: aborting due to 4 previous errors
 
-Some errors have detailed explanations: E0207, E0403, E0637.
-For more information about an error, try `rustc --explain E0207`.
+Some errors have detailed explanations: E0049, E0207, E0403, E0637.
+For more information about an error, try `rustc --explain E0049`.
diff --git a/tests/ui/generic-associated-types/issue-84931.stderr b/tests/ui/generic-associated-types/issue-84931.stderr
index 71d1122..0181948 100644
--- a/tests/ui/generic-associated-types/issue-84931.stderr
+++ b/tests/ui/generic-associated-types/issue-84931.stderr
@@ -18,12 +18,13 @@
    |                               ++++++++++++++
 
 error[E0309]: the parameter type `T` may not live long enough
-  --> $DIR/issue-84931.rs:14:21
+  --> $DIR/issue-84931.rs:14:5
    |
 LL |     type Item<'a> = &'a mut T;
-   |               --    ^^^^^^^^^ ...so that the reference type `&'a mut T` does not outlive the data it points at
-   |               |
-   |               the parameter type `T` must be valid for the lifetime `'a` as defined here...
+   |     ^^^^^^^^^^--^
+   |     |         |
+   |     |         the parameter type `T` must be valid for the lifetime `'a` as defined here...
+   |     ...so that the reference type `&'a mut T` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |
diff --git a/tests/ui/generic-associated-types/static-lifetime-tip-with-default-type.stderr b/tests/ui/generic-associated-types/static-lifetime-tip-with-default-type.stderr
index 7d985a9..786aa00 100644
--- a/tests/ui/generic-associated-types/static-lifetime-tip-with-default-type.stderr
+++ b/tests/ui/generic-associated-types/static-lifetime-tip-with-default-type.stderr
@@ -82,6 +82,14 @@
 LL | struct Far<T: 'static
    |             +++++++++
 
+error[E0392]: lifetime parameter `'a` is never used
+  --> $DIR/static-lifetime-tip-with-default-type.rs:22:10
+   |
+LL | struct S<'a, K: 'a = i32>(&'static K);
+   |          ^^ unused lifetime parameter
+   |
+   = help: consider removing `'a`, referring to it in a field, or using a marker such as `PhantomData`
+
 error[E0310]: the parameter type `K` may not live long enough
   --> $DIR/static-lifetime-tip-with-default-type.rs:22:27
    |
@@ -96,14 +104,6 @@
 LL | struct S<'a, K: 'a + 'static = i32>(&'static K);
    |                    +++++++++
 
-error[E0392]: lifetime parameter `'a` is never used
-  --> $DIR/static-lifetime-tip-with-default-type.rs:22:10
-   |
-LL | struct S<'a, K: 'a = i32>(&'static K);
-   |          ^^ unused lifetime parameter
-   |
-   = help: consider removing `'a`, referring to it in a field, or using a marker such as `PhantomData`
-
 error: aborting due to 8 previous errors
 
 Some errors have detailed explanations: E0310, E0392.
diff --git a/tests/ui/generic-const-items/evaluatable-bounds.stderr b/tests/ui/generic-const-items/evaluatable-bounds.stderr
index ca26d63..8bc4a3d 100644
--- a/tests/ui/generic-const-items/evaluatable-bounds.stderr
+++ b/tests/ui/generic-const-items/evaluatable-bounds.stderr
@@ -2,7 +2,7 @@
   --> $DIR/evaluatable-bounds.rs:14:5
    |
 LL |     const ARRAY: [i32; Self::LEN];
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
 help: try adding a `where` bound
    |
diff --git a/tests/ui/generics/newtype-with-generics.rs b/tests/ui/generics/newtype-with-generics.rs
new file mode 100644
index 0000000..c5e200e
--- /dev/null
+++ b/tests/ui/generics/newtype-with-generics.rs
@@ -0,0 +1,32 @@
+//! Test newtype pattern with generic parameters.
+
+//@ run-pass
+
+#[derive(Clone)]
+struct MyVec<T>(Vec<T>);
+
+fn extract_inner_vec<T: Clone>(wrapper: MyVec<T>) -> Vec<T> {
+    let MyVec(inner_vec) = wrapper;
+    inner_vec.clone()
+}
+
+fn get_first_element<T>(wrapper: MyVec<T>) -> T {
+    let MyVec(inner_vec) = wrapper;
+    inner_vec.into_iter().next().unwrap()
+}
+
+pub fn main() {
+    let my_vec = MyVec(vec![1, 2, 3]);
+    let cloned_vec = my_vec.clone();
+
+    // Test extracting inner vector
+    let extracted = extract_inner_vec(cloned_vec);
+    assert_eq!(extracted[1], 2);
+
+    // Test getting first element
+    assert_eq!(get_first_element(my_vec.clone()), 1);
+
+    // Test direct destructuring
+    let MyVec(inner) = my_vec;
+    assert_eq!(inner[2], 3);
+}
diff --git a/tests/ui/higher-ranked/trait-bounds/normalize-under-binder/issue-89118.stderr b/tests/ui/higher-ranked/trait-bounds/normalize-under-binder/issue-89118.stderr
index 7fe8035..5ded3a5 100644
--- a/tests/ui/higher-ranked/trait-bounds/normalize-under-binder/issue-89118.stderr
+++ b/tests/ui/higher-ranked/trait-bounds/normalize-under-binder/issue-89118.stderr
@@ -53,10 +53,10 @@
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `EthernetWorker`
 
 error[E0277]: the trait bound `for<'a> &'a (): BufferMut` is not satisfied
-  --> $DIR/issue-89118.rs:22:20
+  --> $DIR/issue-89118.rs:22:5
    |
 LL |     type Handler = Ctx<C::Dispatcher>;
-   |                    ^^^^^^^^^^^^^^^^^^ the trait `for<'a> BufferMut` is not implemented for `&'a ()`
+   |     ^^^^^^^^^^^^ the trait `for<'a> BufferMut` is not implemented for `&'a ()`
    |
 help: this trait has no implementations, consider adding one
   --> $DIR/issue-89118.rs:1:1
diff --git a/tests/ui/new-impl-syntax.rs b/tests/ui/impl-trait/basic-trait-impl.rs
similarity index 74%
rename from tests/ui/new-impl-syntax.rs
rename to tests/ui/impl-trait/basic-trait-impl.rs
index 124d604..2706c9c 100644
--- a/tests/ui/new-impl-syntax.rs
+++ b/tests/ui/impl-trait/basic-trait-impl.rs
@@ -1,10 +1,12 @@
+//! Test basic trait implementation syntax for both simple and generic types.
+
 //@ run-pass
 
 use std::fmt;
 
 struct Thingy {
     x: isize,
-    y: isize
+    y: isize,
 }
 
 impl fmt::Debug for Thingy {
@@ -14,10 +16,10 @@ fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
 }
 
 struct PolymorphicThingy<T> {
-    x: T
+    x: T,
 }
 
-impl<T:fmt::Debug> fmt::Debug for PolymorphicThingy<T> {
+impl<T: fmt::Debug> fmt::Debug for PolymorphicThingy<T> {
     fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
         write!(f, "{:?}", self.x)
     }
diff --git a/tests/ui/impl-trait/in-trait/false-positive-predicate-entailment-error.current.stderr b/tests/ui/impl-trait/in-trait/false-positive-predicate-entailment-error.current.stderr
index b6e7e02..2351b18 100644
--- a/tests/ui/impl-trait/in-trait/false-positive-predicate-entailment-error.current.stderr
+++ b/tests/ui/impl-trait/in-trait/false-positive-predicate-entailment-error.current.stderr
@@ -19,6 +19,28 @@
 LL |         F: Callback<Self::CallbackArg> + MyFn<i32>,
    |                                        +++++++++++
 
+error[E0277]: the trait bound `F: MyFn<i32>` is not satisfied
+  --> $DIR/false-positive-predicate-entailment-error.rs:36:5
+   |
+LL | /     fn autobatch<F>(self) -> impl Trait
+...  |
+LL | |     where
+LL | |         F: Callback<Self::CallbackArg>,
+   | |_______________________________________^ the trait `MyFn<i32>` is not implemented for `F`
+   |
+note: required for `F` to implement `Callback<i32>`
+  --> $DIR/false-positive-predicate-entailment-error.rs:14:21
+   |
+LL | impl<A, F: MyFn<A>> Callback<A> for F {
+   |            -------  ^^^^^^^^^^^     ^
+   |            |
+   |            unsatisfied trait bound introduced here
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+help: consider further restricting type parameter `F` with trait `MyFn`
+   |
+LL |         F: Callback<Self::CallbackArg> + MyFn<i32>,
+   |                                        +++++++++++
+
 error[E0277]: the trait bound `F: Callback<i32>` is not satisfied
   --> $DIR/false-positive-predicate-entailment-error.rs:42:12
    |
@@ -46,28 +68,6 @@
    |                                        +++++++++++
 
 error[E0277]: the trait bound `F: MyFn<i32>` is not satisfied
-  --> $DIR/false-positive-predicate-entailment-error.rs:36:5
-   |
-LL | /     fn autobatch<F>(self) -> impl Trait
-...  |
-LL | |     where
-LL | |         F: Callback<Self::CallbackArg>,
-   | |_______________________________________^ the trait `MyFn<i32>` is not implemented for `F`
-   |
-note: required for `F` to implement `Callback<i32>`
-  --> $DIR/false-positive-predicate-entailment-error.rs:14:21
-   |
-LL | impl<A, F: MyFn<A>> Callback<A> for F {
-   |            -------  ^^^^^^^^^^^     ^
-   |            |
-   |            unsatisfied trait bound introduced here
-   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
-help: consider further restricting type parameter `F` with trait `MyFn`
-   |
-LL |         F: Callback<Self::CallbackArg> + MyFn<i32>,
-   |                                        +++++++++++
-
-error[E0277]: the trait bound `F: MyFn<i32>` is not satisfied
   --> $DIR/false-positive-predicate-entailment-error.rs:36:30
    |
 LL |     fn autobatch<F>(self) -> impl Trait
diff --git a/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.current.stderr b/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.current.stderr
index 5d65124..ff3a726 100644
--- a/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.current.stderr
+++ b/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.current.stderr
@@ -46,11 +46,11 @@
 LL |     fn foo(b: bool) -> impl Sized {
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: ...which again requires computing type of `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>::foo::{anon_assoc#0}`, completing the cycle
-note: cycle used when checking that `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>` is well-formed
-  --> $DIR/method-compatability-via-leakage-cycle.rs:17:1
+note: cycle used when checking assoc item `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>::foo` is compatible with trait definition
+  --> $DIR/method-compatability-via-leakage-cycle.rs:21:5
    |
-LL | impl Trait for u32 {
-   | ^^^^^^^^^^^^^^^^^^
+LL |     fn foo(b: bool) -> impl Sized {
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.next.stderr b/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.next.stderr
index 4bbba62..f0a2036 100644
--- a/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.next.stderr
+++ b/tests/ui/impl-trait/in-trait/method-compatability-via-leakage-cycle.next.stderr
@@ -50,11 +50,11 @@
 LL |     fn foo(b: bool) -> impl Sized {
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: ...which again requires computing type of `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>::foo::{anon_assoc#0}`, completing the cycle
-note: cycle used when checking that `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>` is well-formed
-  --> $DIR/method-compatability-via-leakage-cycle.rs:17:1
+note: cycle used when checking assoc item `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>::foo` is compatible with trait definition
+  --> $DIR/method-compatability-via-leakage-cycle.rs:21:5
    |
-LL | impl Trait for u32 {
-   | ^^^^^^^^^^^^^^^^^^
+LL |     fn foo(b: bool) -> impl Sized {
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error[E0391]: cycle detected when computing type of `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>::foo::{anon_assoc#0}`
@@ -109,11 +109,11 @@
 LL |     fn foo(b: bool) -> impl Sized {
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: ...which again requires computing type of `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>::foo::{anon_assoc#0}`, completing the cycle
-note: cycle used when checking that `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>` is well-formed
-  --> $DIR/method-compatability-via-leakage-cycle.rs:17:1
+note: cycle used when checking assoc item `<impl at $DIR/method-compatability-via-leakage-cycle.rs:17:1: 17:19>::foo` is compatible with trait definition
+  --> $DIR/method-compatability-via-leakage-cycle.rs:21:5
    |
-LL | impl Trait for u32 {
-   | ^^^^^^^^^^^^^^^^^^
+LL |     fn foo(b: bool) -> impl Sized {
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
diff --git a/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs b/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs
index 894f592..8433fb7 100644
--- a/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs
+++ b/tests/ui/impl-trait/in-trait/refine-resolution-errors.rs
@@ -9,6 +9,7 @@ pub trait Mirror {
 impl<T: ?Sized> Mirror for () {
     //~^ ERROR the type parameter `T` is not constrained
     type Assoc = T;
+    //~^ ERROR the size for values of type `T` cannot be known at compilation time
 }
 
 pub trait First {
diff --git a/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr b/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr
index 10ebad2..fd53c9f 100644
--- a/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr
+++ b/tests/ui/impl-trait/in-trait/refine-resolution-errors.stderr
@@ -4,6 +4,31 @@
 LL | impl<T: ?Sized> Mirror for () {
    |      ^ unconstrained type parameter
 
-error: aborting due to 1 previous error
+error[E0277]: the size for values of type `T` cannot be known at compilation time
+  --> $DIR/refine-resolution-errors.rs:11:18
+   |
+LL | impl<T: ?Sized> Mirror for () {
+   |      - this type parameter needs to be `Sized`
+LL |
+LL |     type Assoc = T;
+   |                  ^ doesn't have a size known at compile-time
+   |
+note: required by a bound in `Mirror::Assoc`
+  --> $DIR/refine-resolution-errors.rs:7:5
+   |
+LL |     type Assoc;
+   |     ^^^^^^^^^^^ required by this bound in `Mirror::Assoc`
+help: consider removing the `?Sized` bound to make the type parameter `Sized`
+   |
+LL - impl<T: ?Sized> Mirror for () {
+LL + impl<T> Mirror for () {
+   |
+help: consider relaxing the implicit `Sized` restriction
+   |
+LL |     type Assoc: ?Sized;
+   |               ++++++++
 
-For more information about this error, try `rustc --explain E0207`.
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0207, E0277.
+For more information about an error, try `rustc --explain E0207`.
diff --git a/tests/ui/impl-trait/in-trait/span-bug-issue-121457.stderr b/tests/ui/impl-trait/in-trait/span-bug-issue-121457.stderr
index eaa3204..f95f6fa 100644
--- a/tests/ui/impl-trait/in-trait/span-bug-issue-121457.stderr
+++ b/tests/ui/impl-trait/in-trait/span-bug-issue-121457.stderr
@@ -1,3 +1,15 @@
+error[E0195]: lifetime parameters or bounds on associated type `Item` do not match the trait declaration
+  --> $DIR/span-bug-issue-121457.rs:10:14
+   |
+LL |     type Item<'a>
+   |              ---- lifetimes in impl do not match this associated type in trait
+LL |     where
+LL |         Self: 'a;
+   |               -- this bound might be missing in the impl
+...
+LL |     type Item = u32;
+   |              ^ lifetimes do not match associated type in trait
+
 error[E0582]: binding for associated type `Item` references lifetime `'missing`, which does not appear in the trait input types
   --> $DIR/span-bug-issue-121457.rs:13:51
    |
@@ -12,18 +24,6 @@
    |
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
-error[E0195]: lifetime parameters or bounds on associated type `Item` do not match the trait declaration
-  --> $DIR/span-bug-issue-121457.rs:10:14
-   |
-LL |     type Item<'a>
-   |              ---- lifetimes in impl do not match this associated type in trait
-LL |     where
-LL |         Self: 'a;
-   |               -- this bound might be missing in the impl
-...
-LL |     type Item = u32;
-   |              ^ lifetimes do not match associated type in trait
-
 error[E0277]: `()` is not an iterator
   --> $DIR/span-bug-issue-121457.rs:13:23
    |
diff --git a/tests/ui/impl-trait/in-trait/unconstrained-lt.rs b/tests/ui/impl-trait/in-trait/unconstrained-lt.rs
index ff3753d..12e0a42 100644
--- a/tests/ui/impl-trait/in-trait/unconstrained-lt.rs
+++ b/tests/ui/impl-trait/in-trait/unconstrained-lt.rs
@@ -6,6 +6,7 @@ impl<'a, T> Foo for T {
     //~^ ERROR the lifetime parameter `'a` is not constrained by the impl trait, self type, or predicates
 
     fn test() -> &'a () {
+        //~^ WARN: does not match trait method signature
         &()
     }
 }
diff --git a/tests/ui/impl-trait/in-trait/unconstrained-lt.stderr b/tests/ui/impl-trait/in-trait/unconstrained-lt.stderr
index 4c5a42c..27340c5 100644
--- a/tests/ui/impl-trait/in-trait/unconstrained-lt.stderr
+++ b/tests/ui/impl-trait/in-trait/unconstrained-lt.stderr
@@ -1,9 +1,27 @@
+warning: impl trait in impl method signature does not match trait method signature
+  --> $DIR/unconstrained-lt.rs:8:18
+   |
+LL |     fn test() -> impl Sized;
+   |                  ---------- return type from trait method defined here
+...
+LL |     fn test() -> &'a () {
+   |                  ^^^^^^
+   |
+   = note: add `#[allow(refining_impl_trait)]` if it is intended for this to be part of the public API of this crate
+   = note: we are soliciting feedback, see issue #121718 <https://github.com/rust-lang/rust/issues/121718> for more information
+   = note: `#[warn(refining_impl_trait_internal)]` on by default
+help: replace the return type so that it matches the trait
+   |
+LL -     fn test() -> &'a () {
+LL +     fn test() -> impl Sized {
+   |
+
 error[E0207]: the lifetime parameter `'a` is not constrained by the impl trait, self type, or predicates
   --> $DIR/unconstrained-lt.rs:5:6
    |
 LL | impl<'a, T> Foo for T {
    |      ^^ unconstrained lifetime parameter
 
-error: aborting due to 1 previous error
+error: aborting due to 1 previous error; 1 warning emitted
 
 For more information about this error, try `rustc --explain E0207`.
diff --git a/tests/ui/implied-bounds/impl-header-unnormalized-types.stderr b/tests/ui/implied-bounds/impl-header-unnormalized-types.stderr
index 07cb0ae..dcb68fb 100644
--- a/tests/ui/implied-bounds/impl-header-unnormalized-types.stderr
+++ b/tests/ui/implied-bounds/impl-header-unnormalized-types.stderr
@@ -1,8 +1,8 @@
 error[E0491]: in type `&'a &'b ()`, reference has a longer lifetime than the data it references
-  --> $DIR/impl-header-unnormalized-types.rs:15:18
+  --> $DIR/impl-header-unnormalized-types.rs:15:5
    |
 LL |     type Assoc = &'a &'b ();
-   |                  ^^^^^^^^^^
+   |     ^^^^^^^^^^
    |
 note: the pointer is valid for the lifetime `'a` as defined here
   --> $DIR/impl-header-unnormalized-types.rs:14:6
diff --git a/tests/ui/indexing/indexing-integral-types.rs b/tests/ui/indexing/indexing-integral-types.rs
new file mode 100644
index 0000000..a91696a
--- /dev/null
+++ b/tests/ui/indexing/indexing-integral-types.rs
@@ -0,0 +1,20 @@
+//! Test that only usize can be used for indexing arrays and slices.
+
+pub fn main() {
+    let v: Vec<isize> = vec![0, 1, 2, 3, 4, 5];
+    let s: String = "abcdef".to_string();
+
+    // Valid indexing with usize
+    v[3_usize];
+    v[3];
+    v[3u8]; //~ ERROR the type `[isize]` cannot be indexed by `u8`
+    v[3i8]; //~ ERROR the type `[isize]` cannot be indexed by `i8`
+    v[3u32]; //~ ERROR the type `[isize]` cannot be indexed by `u32`
+    v[3i32]; //~ ERROR the type `[isize]` cannot be indexed by `i32`
+    s.as_bytes()[3_usize];
+    s.as_bytes()[3];
+    s.as_bytes()[3u8]; //~ ERROR the type `[u8]` cannot be indexed by `u8`
+    s.as_bytes()[3i8]; //~ ERROR the type `[u8]` cannot be indexed by `i8`
+    s.as_bytes()[3u32]; //~ ERROR the type `[u8]` cannot be indexed by `u32`
+    s.as_bytes()[3i32]; //~ ERROR the type `[u8]` cannot be indexed by `i32`
+}
diff --git a/tests/ui/integral-indexing.stderr b/tests/ui/indexing/indexing-integral-types.stderr
similarity index 91%
rename from tests/ui/integral-indexing.stderr
rename to tests/ui/indexing/indexing-integral-types.stderr
index 26253e0..b63991e 100644
--- a/tests/ui/integral-indexing.stderr
+++ b/tests/ui/indexing/indexing-integral-types.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the type `[isize]` cannot be indexed by `u8`
-  --> $DIR/integral-indexing.rs:6:7
+  --> $DIR/indexing-integral-types.rs:10:7
    |
 LL |     v[3u8];
    |       ^^^ slice indices are of type `usize` or ranges of `usize`
@@ -11,7 +11,7 @@
    = note: required for `Vec<isize>` to implement `Index<u8>`
 
 error[E0277]: the type `[isize]` cannot be indexed by `i8`
-  --> $DIR/integral-indexing.rs:7:7
+  --> $DIR/indexing-integral-types.rs:11:7
    |
 LL |     v[3i8];
    |       ^^^ slice indices are of type `usize` or ranges of `usize`
@@ -23,7 +23,7 @@
    = note: required for `Vec<isize>` to implement `Index<i8>`
 
 error[E0277]: the type `[isize]` cannot be indexed by `u32`
-  --> $DIR/integral-indexing.rs:8:7
+  --> $DIR/indexing-integral-types.rs:12:7
    |
 LL |     v[3u32];
    |       ^^^^ slice indices are of type `usize` or ranges of `usize`
@@ -35,7 +35,7 @@
    = note: required for `Vec<isize>` to implement `Index<u32>`
 
 error[E0277]: the type `[isize]` cannot be indexed by `i32`
-  --> $DIR/integral-indexing.rs:9:7
+  --> $DIR/indexing-integral-types.rs:13:7
    |
 LL |     v[3i32];
    |       ^^^^ slice indices are of type `usize` or ranges of `usize`
@@ -47,7 +47,7 @@
    = note: required for `Vec<isize>` to implement `Index<i32>`
 
 error[E0277]: the type `[u8]` cannot be indexed by `u8`
-  --> $DIR/integral-indexing.rs:12:18
+  --> $DIR/indexing-integral-types.rs:16:18
    |
 LL |     s.as_bytes()[3u8];
    |                  ^^^ slice indices are of type `usize` or ranges of `usize`
@@ -59,7 +59,7 @@
    = note: required for `[u8]` to implement `Index<u8>`
 
 error[E0277]: the type `[u8]` cannot be indexed by `i8`
-  --> $DIR/integral-indexing.rs:13:18
+  --> $DIR/indexing-integral-types.rs:17:18
    |
 LL |     s.as_bytes()[3i8];
    |                  ^^^ slice indices are of type `usize` or ranges of `usize`
@@ -71,7 +71,7 @@
    = note: required for `[u8]` to implement `Index<i8>`
 
 error[E0277]: the type `[u8]` cannot be indexed by `u32`
-  --> $DIR/integral-indexing.rs:14:18
+  --> $DIR/indexing-integral-types.rs:18:18
    |
 LL |     s.as_bytes()[3u32];
    |                  ^^^^ slice indices are of type `usize` or ranges of `usize`
@@ -83,7 +83,7 @@
    = note: required for `[u8]` to implement `Index<u32>`
 
 error[E0277]: the type `[u8]` cannot be indexed by `i32`
-  --> $DIR/integral-indexing.rs:15:18
+  --> $DIR/indexing-integral-types.rs:19:18
    |
 LL |     s.as_bytes()[3i32];
    |                  ^^^^ slice indices are of type `usize` or ranges of `usize`
diff --git a/tests/ui/infinite/infinite-trait-alias-recursion.stderr b/tests/ui/infinite/infinite-trait-alias-recursion.stderr
index 5b0cbd5..fa51914 100644
--- a/tests/ui/infinite/infinite-trait-alias-recursion.stderr
+++ b/tests/ui/infinite/infinite-trait-alias-recursion.stderr
@@ -20,7 +20,7 @@
   --> $DIR/infinite-trait-alias-recursion.rs:3:1
    |
 LL | trait T1 = T2;
-   | ^^^^^^^^^^^^^^
+   | ^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/infinite/infinite-type-alias-mutual-recursion.feature.stderr b/tests/ui/infinite/infinite-type-alias-mutual-recursion.feature.stderr
index 3dec2c3..e586248 100644
--- a/tests/ui/infinite/infinite-type-alias-mutual-recursion.feature.stderr
+++ b/tests/ui/infinite/infinite-type-alias-mutual-recursion.feature.stderr
@@ -1,24 +1,24 @@
 error[E0275]: overflow normalizing the type alias `X2`
-  --> $DIR/infinite-type-alias-mutual-recursion.rs:6:11
+  --> $DIR/infinite-type-alias-mutual-recursion.rs:6:1
    |
 LL | type X1 = X2;
-   |           ^^
+   | ^^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
 error[E0275]: overflow normalizing the type alias `X3`
-  --> $DIR/infinite-type-alias-mutual-recursion.rs:9:11
+  --> $DIR/infinite-type-alias-mutual-recursion.rs:9:1
    |
 LL | type X2 = X3;
-   |           ^^
+   | ^^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
 error[E0275]: overflow normalizing the type alias `X1`
-  --> $DIR/infinite-type-alias-mutual-recursion.rs:11:11
+  --> $DIR/infinite-type-alias-mutual-recursion.rs:11:1
    |
 LL | type X3 = X1;
-   |           ^^
+   | ^^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
diff --git a/tests/ui/infinite/infinite-vec-type-recursion.feature.stderr b/tests/ui/infinite/infinite-vec-type-recursion.feature.stderr
index 5c8d503..3e07a46 100644
--- a/tests/ui/infinite/infinite-vec-type-recursion.feature.stderr
+++ b/tests/ui/infinite/infinite-vec-type-recursion.feature.stderr
@@ -1,8 +1,8 @@
 error[E0275]: overflow normalizing the type alias `X`
-  --> $DIR/infinite-vec-type-recursion.rs:6:10
+  --> $DIR/infinite-vec-type-recursion.rs:6:1
    |
 LL | type X = Vec<X>;
-   |          ^^^^^^
+   | ^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
diff --git a/tests/ui/inner-attrs-on-impl.rs b/tests/ui/inner-attrs-on-impl.rs
deleted file mode 100644
index 1dce1cd..0000000
--- a/tests/ui/inner-attrs-on-impl.rs
+++ /dev/null
@@ -1,24 +0,0 @@
-//@ run-pass
-
-struct Foo;
-
-impl Foo {
-    #![cfg(false)]
-
-    fn method(&self) -> bool { false }
-}
-
-impl Foo {
-    #![cfg(not(FALSE))]
-
-    // check that we don't eat attributes too eagerly.
-    #[cfg(false)]
-    fn method(&self) -> bool { false }
-
-    fn method(&self) -> bool { true }
-}
-
-
-pub fn main() {
-    assert!(Foo.method());
-}
diff --git a/tests/ui/inner-module.rs b/tests/ui/inner-module.rs
deleted file mode 100644
index 111f2ca..0000000
--- a/tests/ui/inner-module.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-//@ run-pass
-
-mod inner {
-    pub mod inner2 {
-        pub fn hello() { println!("hello, modular world"); }
-    }
-    pub fn hello() { inner2::hello(); }
-}
-
-pub fn main() { inner::hello(); inner::inner2::hello(); }
diff --git a/tests/ui/inner-static-type-parameter.rs b/tests/ui/inner-static-type-parameter.rs
deleted file mode 100644
index a1994e7..0000000
--- a/tests/ui/inner-static-type-parameter.rs
+++ /dev/null
@@ -1,11 +0,0 @@
-// see #9186
-
-enum Bar<T> { What } //~ ERROR parameter `T` is never used
-
-fn foo<T>() {
-    static a: Bar<T> = Bar::What;
-//~^ ERROR can't use generic parameters from outer item
-}
-
-fn main() {
-}
diff --git a/tests/ui/integral-indexing.rs b/tests/ui/integral-indexing.rs
deleted file mode 100644
index e20553a..0000000
--- a/tests/ui/integral-indexing.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-pub fn main() {
-    let v: Vec<isize> = vec![0, 1, 2, 3, 4, 5];
-    let s: String = "abcdef".to_string();
-    v[3_usize];
-    v[3];
-    v[3u8];  //~ ERROR the type `[isize]` cannot be indexed by `u8`
-    v[3i8];  //~ ERROR the type `[isize]` cannot be indexed by `i8`
-    v[3u32]; //~ ERROR the type `[isize]` cannot be indexed by `u32`
-    v[3i32]; //~ ERROR the type `[isize]` cannot be indexed by `i32`
-    s.as_bytes()[3_usize];
-    s.as_bytes()[3];
-    s.as_bytes()[3u8];  //~ ERROR the type `[u8]` cannot be indexed by `u8`
-    s.as_bytes()[3i8];  //~ ERROR the type `[u8]` cannot be indexed by `i8`
-    s.as_bytes()[3u32]; //~ ERROR the type `[u8]` cannot be indexed by `u32`
-    s.as_bytes()[3i32]; //~ ERROR the type `[u8]` cannot be indexed by `i32`
-}
diff --git a/tests/ui/invalid/invalid_rustc_layout_scalar_valid_range.stderr b/tests/ui/invalid/invalid_rustc_layout_scalar_valid_range.stderr
index 7879e73..8b9ad78 100644
--- a/tests/ui/invalid/invalid_rustc_layout_scalar_valid_range.stderr
+++ b/tests/ui/invalid/invalid_rustc_layout_scalar_valid_range.stderr
@@ -1,20 +1,38 @@
-error: expected exactly one integer literal argument
+error[E0539]: malformed `rustc_layout_scalar_valid_range_start` attribute input
   --> $DIR/invalid_rustc_layout_scalar_valid_range.rs:3:1
    |
 LL | #[rustc_layout_scalar_valid_range_start(u32::MAX)]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^--------^^
+   | |                                       |
+   | |                                       expected an integer literal here
+   | help: must be of the form: `#[rustc_layout_scalar_valid_range_start(start)]`
 
-error: expected exactly one integer literal argument
+error[E0805]: malformed `rustc_layout_scalar_valid_range_end` attribute input
   --> $DIR/invalid_rustc_layout_scalar_valid_range.rs:6:1
    |
 LL | #[rustc_layout_scalar_valid_range_end(1, 2)]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^------^
+   | |                                    |
+   | |                                    expected a single argument here
+   | help: must be of the form: `#[rustc_layout_scalar_valid_range_end(end)]`
 
-error: expected exactly one integer literal argument
+error[E0539]: malformed `rustc_layout_scalar_valid_range_end` attribute input
   --> $DIR/invalid_rustc_layout_scalar_valid_range.rs:9:1
    |
 LL | #[rustc_layout_scalar_valid_range_end(a = "a")]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-------^^
+   | |                                     |
+   | |                                     expected an integer literal here
+   | help: must be of the form: `#[rustc_layout_scalar_valid_range_end(end)]`
+
+error[E0539]: malformed `rustc_layout_scalar_valid_range_start` attribute input
+  --> $DIR/invalid_rustc_layout_scalar_valid_range.rs:18:1
+   |
+LL | #[rustc_layout_scalar_valid_range_start(rustc_layout_scalar_valid_range_start)]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^-------------------------------------^^
+   | |                                       |
+   | |                                       expected an integer literal here
+   | help: must be of the form: `#[rustc_layout_scalar_valid_range_start(start)]`
 
 error: attribute should be applied to a struct
   --> $DIR/invalid_rustc_layout_scalar_valid_range.rs:12:1
@@ -27,11 +45,7 @@
 LL | | }
    | |_- not a struct
 
-error: expected exactly one integer literal argument
-  --> $DIR/invalid_rustc_layout_scalar_valid_range.rs:18:1
-   |
-LL | #[rustc_layout_scalar_valid_range_start(rustc_layout_scalar_valid_range_start)]
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
 error: aborting due to 5 previous errors
 
+Some errors have detailed explanations: E0539, E0805.
+For more information about an error, try `rustc --explain E0539`.
diff --git a/tests/ui/invalid_dispatch_from_dyn_impls.rs b/tests/ui/invalid_dispatch_from_dyn_impls.rs
deleted file mode 100644
index b1d4b26..0000000
--- a/tests/ui/invalid_dispatch_from_dyn_impls.rs
+++ /dev/null
@@ -1,55 +0,0 @@
-#![feature(unsize, dispatch_from_dyn)]
-
-use std::{
-    ops::DispatchFromDyn,
-    marker::{Unsize, PhantomData},
-};
-
-struct WrapperWithExtraField<T>(T, i32);
-
-impl<T, U> DispatchFromDyn<WrapperWithExtraField<U>> for WrapperWithExtraField<T>
-//~^ ERROR [E0378]
-where
-    T: DispatchFromDyn<U>,
-{}
-
-
-struct MultiplePointers<T: ?Sized>{
-    ptr1: *const T,
-    ptr2: *const T,
-}
-
-impl<T: ?Sized, U: ?Sized> DispatchFromDyn<MultiplePointers<U>> for MultiplePointers<T>
-//~^ ERROR implementing `DispatchFromDyn` does not allow multiple fields to be coerced
-where
-    T: Unsize<U>,
-{}
-
-
-struct NothingToCoerce<T: ?Sized> {
-    data: PhantomData<T>,
-}
-
-impl<T: ?Sized, U: ?Sized> DispatchFromDyn<NothingToCoerce<T>> for NothingToCoerce<U> {}
-//~^ ERROR implementing `DispatchFromDyn` requires a field to be coerced
-
-#[repr(C)]
-struct HasReprC<T: ?Sized>(Box<T>);
-
-impl<T: ?Sized, U: ?Sized> DispatchFromDyn<HasReprC<U>> for HasReprC<T>
-//~^ ERROR [E0378]
-where
-    T: Unsize<U>,
-{}
-
-#[repr(align(64))]
-struct OverAlignedZst;
-struct OverAligned<T: ?Sized>(Box<T>, OverAlignedZst);
-
-impl<T: ?Sized, U: ?Sized> DispatchFromDyn<OverAligned<U>> for OverAligned<T>
-//~^ ERROR [E0378]
-    where
-        T: Unsize<U>,
-{}
-
-fn main() {}
diff --git a/tests/ui/issues/issue-54410.stderr b/tests/ui/issues/issue-54410.stderr
index 2cd5a2a..cb68ada 100644
--- a/tests/ui/issues/issue-54410.stderr
+++ b/tests/ui/issues/issue-54410.stderr
@@ -1,8 +1,8 @@
 error[E0277]: the size for values of type `[i8]` cannot be known at compilation time
-  --> $DIR/issue-54410.rs:2:28
+  --> $DIR/issue-54410.rs:2:5
    |
 LL |     pub static mut symbol: [i8];
-   |                            ^^^^ doesn't have a size known at compile-time
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `Sized` is not implemented for `[i8]`
    = note: statics and constants must have a statically known size
diff --git a/tests/ui/issues/issue-7364.stderr b/tests/ui/issues/issue-7364.stderr
index a47a90c..e07f88b 100644
--- a/tests/ui/issues/issue-7364.stderr
+++ b/tests/ui/issues/issue-7364.stderr
@@ -1,8 +1,8 @@
 error[E0277]: `RefCell<isize>` cannot be shared between threads safely
-  --> $DIR/issue-7364.rs:4:15
+  --> $DIR/issue-7364.rs:4:1
    |
 LL | static boxed: Box<RefCell<isize>> = Box::new(RefCell::new(0));
-   |               ^^^^^^^^^^^^^^^^^^^ `RefCell<isize>` cannot be shared between threads safely
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `RefCell<isize>` cannot be shared between threads safely
    |
    = help: the trait `Sync` is not implemented for `RefCell<isize>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
diff --git a/tests/ui/layout/ice-non-last-unsized-field-issue-121473.stderr b/tests/ui/layout/ice-non-last-unsized-field-issue-121473.stderr
index 626be7a..b0ea655 100644
--- a/tests/ui/layout/ice-non-last-unsized-field-issue-121473.stderr
+++ b/tests/ui/layout/ice-non-last-unsized-field-issue-121473.stderr
@@ -70,6 +70,18 @@
 LL |         field2: Box<str>, // Unsized
    |                 ++++   +
 
+error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
+  --> $DIR/ice-non-last-unsized-field-issue-121473.rs:46:5
+   |
+LL |     field2: str, // Unsized
+   |     ^^^^^^^^^^^
+   |
+   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
+help: wrap the field type in `ManuallyDrop<...>`
+   |
+LL |     field2: std::mem::ManuallyDrop<str>, // Unsized
+   |             +++++++++++++++++++++++   +
+
 error[E0277]: the size for values of type `str` cannot be known at compilation time
   --> $DIR/ice-non-last-unsized-field-issue-121473.rs:46:13
    |
@@ -88,18 +100,6 @@
 LL |     field2: Box<str>, // Unsized
    |             ++++   +
 
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/ice-non-last-unsized-field-issue-121473.rs:46:5
-   |
-LL |     field2: str, // Unsized
-   |     ^^^^^^^^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     field2: std::mem::ManuallyDrop<str>, // Unsized
-   |             +++++++++++++++++++++++   +
-
 error: aborting due to 6 previous errors
 
 Some errors have detailed explanations: E0277, E0740.
diff --git a/tests/ui/layout/rust-call-abi-not-a-tuple-ice-81974.stderr b/tests/ui/layout/rust-call-abi-not-a-tuple-ice-81974.stderr
index 32a564e..75ee936 100644
--- a/tests/ui/layout/rust-call-abi-not-a-tuple-ice-81974.stderr
+++ b/tests/ui/layout/rust-call-abi-not-a-tuple-ice-81974.stderr
@@ -1,4 +1,17 @@
 error[E0059]: type parameter to bare `FnOnce` trait must be a tuple
+  --> $DIR/rust-call-abi-not-a-tuple-ice-81974.rs:31:5
+   |
+LL |     extern "rust-call" fn call_once(mut self, a: A) -> Self::Output {
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Tuple` is not implemented for `A`
+   |
+note: required by a bound in `FnOnce`
+  --> $SRC_DIR/core/src/ops/function.rs:LL:COL
+help: consider further restricting type parameter `A` with unstable trait `Tuple`
+   |
+LL |     A: Eq + Hash + Clone + std::marker::Tuple,
+   |                          ++++++++++++++++++++
+
+error[E0059]: type parameter to bare `FnOnce` trait must be a tuple
   --> $DIR/rust-call-abi-not-a-tuple-ice-81974.rs:24:12
    |
 LL | impl<A, B> FnOnce<A> for CachedFun<A, B>
@@ -12,9 +25,9 @@
    |                          ++++++++++++++++++++
 
 error[E0059]: type parameter to bare `FnOnce` trait must be a tuple
-  --> $DIR/rust-call-abi-not-a-tuple-ice-81974.rs:31:5
+  --> $DIR/rust-call-abi-not-a-tuple-ice-81974.rs:45:5
    |
-LL |     extern "rust-call" fn call_once(mut self, a: A) -> Self::Output {
+LL |     extern "rust-call" fn call_mut(&mut self, a: A) -> Self::Output {
    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Tuple` is not implemented for `A`
    |
 note: required by a bound in `FnOnce`
@@ -37,19 +50,6 @@
 LL |     A: Eq + Hash + Clone + std::marker::Tuple,
    |                          ++++++++++++++++++++
 
-error[E0059]: type parameter to bare `FnOnce` trait must be a tuple
-  --> $DIR/rust-call-abi-not-a-tuple-ice-81974.rs:45:5
-   |
-LL |     extern "rust-call" fn call_mut(&mut self, a: A) -> Self::Output {
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Tuple` is not implemented for `A`
-   |
-note: required by a bound in `FnOnce`
-  --> $SRC_DIR/core/src/ops/function.rs:LL:COL
-help: consider further restricting type parameter `A` with unstable trait `Tuple`
-   |
-LL |     A: Eq + Hash + Clone + std::marker::Tuple,
-   |                          ++++++++++++++++++++
-
 error[E0277]: functions with the "rust-call" ABI must take a single non-self tuple argument
   --> $DIR/rust-call-abi-not-a-tuple-ice-81974.rs:31:5
    |
diff --git a/tests/ui/lazy-type-alias/inherent-impls-overflow.current.stderr b/tests/ui/lazy-type-alias/inherent-impls-overflow.current.stderr
index 85ac98f..e919460 100644
--- a/tests/ui/lazy-type-alias/inherent-impls-overflow.current.stderr
+++ b/tests/ui/lazy-type-alias/inherent-impls-overflow.current.stderr
@@ -1,8 +1,8 @@
 error[E0275]: overflow normalizing the type alias `Loop`
-  --> $DIR/inherent-impls-overflow.rs:8:13
+  --> $DIR/inherent-impls-overflow.rs:8:1
    |
 LL | type Loop = Loop;
-   |             ^^^^
+   | ^^^^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
@@ -15,18 +15,18 @@
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
 error[E0275]: overflow normalizing the type alias `Poly0<(((((((...,),),),),),),)>`
-  --> $DIR/inherent-impls-overflow.rs:17:17
+  --> $DIR/inherent-impls-overflow.rs:17:1
    |
 LL | type Poly0<T> = Poly1<(T,)>;
-   |                 ^^^^^^^^^^^
+   | ^^^^^^^^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
 error[E0275]: overflow normalizing the type alias `Poly1<(((((((...,),),),),),),)>`
-  --> $DIR/inherent-impls-overflow.rs:21:17
+  --> $DIR/inherent-impls-overflow.rs:21:1
    |
 LL | type Poly1<T> = Poly0<(T,)>;
-   |                 ^^^^^^^^^^^
+   | ^^^^^^^^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
diff --git a/tests/ui/lazy-type-alias/inherent-impls-overflow.next.stderr b/tests/ui/lazy-type-alias/inherent-impls-overflow.next.stderr
index e94f29d..62ed6e8 100644
--- a/tests/ui/lazy-type-alias/inherent-impls-overflow.next.stderr
+++ b/tests/ui/lazy-type-alias/inherent-impls-overflow.next.stderr
@@ -1,8 +1,8 @@
 error[E0271]: type mismatch resolving `Loop normalizes-to _`
-  --> $DIR/inherent-impls-overflow.rs:8:13
+  --> $DIR/inherent-impls-overflow.rs:8:1
    |
 LL | type Loop = Loop;
-   |             ^^^^ types differ
+   | ^^^^^^^^^ types differ
 
 error[E0271]: type mismatch resolving `Loop normalizes-to _`
   --> $DIR/inherent-impls-overflow.rs:12:1
@@ -17,10 +17,10 @@
    |      ^^^^ types differ
 
 error[E0275]: overflow evaluating the requirement `Poly1<(T,)> == _`
-  --> $DIR/inherent-impls-overflow.rs:17:17
+  --> $DIR/inherent-impls-overflow.rs:17:1
    |
 LL | type Poly0<T> = Poly1<(T,)>;
-   |                 ^^^^^^^^^^^
+   | ^^^^^^^^^^^^^
    |
    = help: consider increasing the recursion limit by adding a `#![recursion_limit = "256"]` attribute to your crate (`inherent_impls_overflow`)
 
@@ -36,10 +36,10 @@
    = note: all type parameters must be used in a non-recursive way in order to constrain their variance
 
 error[E0275]: overflow evaluating the requirement `Poly0<(T,)> == _`
-  --> $DIR/inherent-impls-overflow.rs:21:17
+  --> $DIR/inherent-impls-overflow.rs:21:1
    |
 LL | type Poly1<T> = Poly0<(T,)>;
-   |                 ^^^^^^^^^^^
+   | ^^^^^^^^^^^^^
    |
    = help: consider increasing the recursion limit by adding a `#![recursion_limit = "256"]` attribute to your crate (`inherent_impls_overflow`)
 
diff --git a/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.stderr b/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.stderr
index bcffa02..d8270a0 100644
--- a/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.stderr
+++ b/tests/ui/lazy-type-alias/unconstrained-params-in-impl-due-to-overflow.stderr
@@ -5,10 +5,10 @@
    |      ^ unconstrained type parameter
 
 error[E0275]: overflow normalizing the type alias `Loop<T>`
-  --> $DIR/unconstrained-params-in-impl-due-to-overflow.rs:6:16
+  --> $DIR/unconstrained-params-in-impl-due-to-overflow.rs:6:1
    |
 LL | type Loop<T> = Loop<T>;
-   |                ^^^^^^^
+   | ^^^^^^^^^^^^
    |
    = note: in case this is a recursive type alias, consider using a struct, enum, or union instead
 
diff --git a/tests/ui/lexical-scoping.rs b/tests/ui/lexical-scoping.rs
deleted file mode 100644
index f858369..0000000
--- a/tests/ui/lexical-scoping.rs
+++ /dev/null
@@ -1,19 +0,0 @@
-//@ run-pass
-// Tests that items in subscopes can shadow type parameters and local variables (see issue #23880).
-
-#![allow(unused)]
-struct Foo<X> { x: Box<X> }
-impl<Bar> Foo<Bar> {
-    fn foo(&self) {
-        type Bar = i32;
-        let _: Bar = 42;
-    }
-}
-
-fn main() {
-    let f = 1;
-    {
-        fn f() {}
-        f();
-    }
-}
diff --git a/tests/ui/lifetimes/issue-64173-unused-lifetimes.stderr b/tests/ui/lifetimes/issue-64173-unused-lifetimes.stderr
index 534ba93..4bfbe0e 100644
--- a/tests/ui/lifetimes/issue-64173-unused-lifetimes.stderr
+++ b/tests/ui/lifetimes/issue-64173-unused-lifetimes.stderr
@@ -7,12 +7,6 @@
    = note: lifetime parameters may not be used in const expressions
    = help: add `#![feature(generic_const_exprs)]` to allow generic const expressions
 
-error: generic `Self` types are currently not permitted in anonymous constants
-  --> $DIR/issue-64173-unused-lifetimes.rs:4:28
-   |
-LL |     array: [(); size_of::<&Self>()],
-   |                            ^^^^
-
 error[E0392]: lifetime parameter `'s` is never used
   --> $DIR/issue-64173-unused-lifetimes.rs:3:12
    |
@@ -21,6 +15,12 @@
    |
    = help: consider removing `'s`, referring to it in a field, or using a marker such as `PhantomData`
 
+error: generic `Self` types are currently not permitted in anonymous constants
+  --> $DIR/issue-64173-unused-lifetimes.rs:4:28
+   |
+LL |     array: [(); size_of::<&Self>()],
+   |                            ^^^^
+
 error[E0392]: lifetime parameter `'a` is never used
   --> $DIR/issue-64173-unused-lifetimes.rs:15:12
    |
diff --git a/tests/ui/lifetimes/issue-76168-hr-outlives-3.rs b/tests/ui/lifetimes/issue-76168-hr-outlives-3.rs
index eab436f..d6fda12 100644
--- a/tests/ui/lifetimes/issue-76168-hr-outlives-3.rs
+++ b/tests/ui/lifetimes/issue-76168-hr-outlives-3.rs
@@ -7,10 +7,12 @@ async fn wrapper<F>(f: F)
 //~^ ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
 //~| ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
 //~| ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
-//~| ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
 where
 F:,
 for<'a> <i32 as FnOnce<(&'a mut i32,)>>::Output: Future<Output = ()> + 'a,
+//~^ ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
+//~| ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
+//~| ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
 {
     //~^ ERROR: expected a `FnOnce(&'a mut i32)` closure, found `i32`
     let mut i = 41;
diff --git a/tests/ui/lifetimes/issue-76168-hr-outlives-3.stderr b/tests/ui/lifetimes/issue-76168-hr-outlives-3.stderr
index 90572fe..945d38d 100644
--- a/tests/ui/lifetimes/issue-76168-hr-outlives-3.stderr
+++ b/tests/ui/lifetimes/issue-76168-hr-outlives-3.stderr
@@ -10,10 +10,26 @@
    = help: the trait `for<'a> FnOnce(&'a mut i32)` is not implemented for `i32`
 
 error[E0277]: expected a `FnOnce(&'a mut i32)` closure, found `i32`
-  --> $DIR/issue-76168-hr-outlives-3.rs:6:10
+  --> $DIR/issue-76168-hr-outlives-3.rs:12:50
    |
-LL | async fn wrapper<F>(f: F)
-   |          ^^^^^^^ expected an `FnOnce(&'a mut i32)` closure, found `i32`
+LL | for<'a> <i32 as FnOnce<(&'a mut i32,)>>::Output: Future<Output = ()> + 'a,
+   |                                                  ^^^^^^^^^^^^^^^^^^^ expected an `FnOnce(&'a mut i32)` closure, found `i32`
+   |
+   = help: the trait `for<'a> FnOnce(&'a mut i32)` is not implemented for `i32`
+
+error[E0277]: expected a `FnOnce(&'a mut i32)` closure, found `i32`
+  --> $DIR/issue-76168-hr-outlives-3.rs:12:57
+   |
+LL | for<'a> <i32 as FnOnce<(&'a mut i32,)>>::Output: Future<Output = ()> + 'a,
+   |                                                         ^^^^^^^^^^^ expected an `FnOnce(&'a mut i32)` closure, found `i32`
+   |
+   = help: the trait `for<'a> FnOnce(&'a mut i32)` is not implemented for `i32`
+
+error[E0277]: expected a `FnOnce(&'a mut i32)` closure, found `i32`
+  --> $DIR/issue-76168-hr-outlives-3.rs:12:72
+   |
+LL | for<'a> <i32 as FnOnce<(&'a mut i32,)>>::Output: Future<Output = ()> + 'a,
+   |                                                                        ^^ expected an `FnOnce(&'a mut i32)` closure, found `i32`
    |
    = help: the trait `for<'a> FnOnce(&'a mut i32)` is not implemented for `i32`
 
@@ -41,7 +57,7 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error[E0277]: expected a `FnOnce(&'a mut i32)` closure, found `i32`
-  --> $DIR/issue-76168-hr-outlives-3.rs:14:1
+  --> $DIR/issue-76168-hr-outlives-3.rs:16:1
    |
 LL | / {
 LL | |
@@ -52,6 +68,6 @@
    |
    = help: the trait `for<'a> FnOnce(&'a mut i32)` is not implemented for `i32`
 
-error: aborting due to 5 previous errors
+error: aborting due to 7 previous errors
 
 For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/lifetimes/issue-95023.stderr b/tests/ui/lifetimes/issue-95023.stderr
index cbc0eee..dffa033 100644
--- a/tests/ui/lifetimes/issue-95023.stderr
+++ b/tests/ui/lifetimes/issue-95023.stderr
@@ -32,6 +32,14 @@
 LL | impl Fn(&isize) for Error {
    |      ^^^^^^^^^^
 
+error[E0046]: not all trait items implemented, missing: `call`
+  --> $DIR/issue-95023.rs:3:1
+   |
+LL | impl Fn(&isize) for Error {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^ missing `call` in implementation
+   |
+   = help: implement the missing item: `fn call(&self, _: (&isize,)) -> <Self as FnOnce<(&isize,)>>::Output { todo!() }`
+
 error[E0277]: expected a `FnMut(&isize)` closure, found `Error`
   --> $DIR/issue-95023.rs:3:21
    |
@@ -42,14 +50,6 @@
 note: required by a bound in `Fn`
   --> $SRC_DIR/core/src/ops/function.rs:LL:COL
 
-error[E0046]: not all trait items implemented, missing: `call`
-  --> $DIR/issue-95023.rs:3:1
-   |
-LL | impl Fn(&isize) for Error {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^ missing `call` in implementation
-   |
-   = help: implement the missing item: `fn call(&self, _: (&isize,)) -> <Self as FnOnce<(&isize,)>>::Output { todo!() }`
-
 error[E0220]: associated type `B` not found for `Self`
   --> $DIR/issue-95023.rs:8:44
    |
diff --git a/tests/ui/auxiliary/msvc-data-only-lib.rs b/tests/ui/linkage-attr/auxiliary/msvc-static-data-import-lib.rs
similarity index 100%
rename from tests/ui/auxiliary/msvc-data-only-lib.rs
rename to tests/ui/linkage-attr/auxiliary/msvc-static-data-import-lib.rs
diff --git a/tests/ui/link-section.rs b/tests/ui/linkage-attr/link-section-placement.rs
similarity index 92%
rename from tests/ui/link-section.rs
rename to tests/ui/linkage-attr/link-section-placement.rs
index a8de8c2..6a143bf 100644
--- a/tests/ui/link-section.rs
+++ b/tests/ui/linkage-attr/link-section-placement.rs
@@ -1,8 +1,9 @@
+//! Test placement of functions and statics in custom link sections
+
 //@ run-pass
 
 // FIXME(static_mut_refs): Do not allow `static_mut_refs` lint
 #![allow(static_mut_refs)]
-
 #![allow(non_upper_case_globals)]
 #[cfg(not(target_vendor = "apple"))]
 #[link_section = ".moretext"]
diff --git a/tests/ui/linkage-attr/msvc-static-data-import.rs b/tests/ui/linkage-attr/msvc-static-data-import.rs
new file mode 100644
index 0000000..e53eb40
--- /dev/null
+++ b/tests/ui/linkage-attr/msvc-static-data-import.rs
@@ -0,0 +1,18 @@
+//! Test that static data from external crates can be imported on MSVC targets.
+//!
+//! On Windows MSVC targets, static data from external rlibs must be imported
+//! through `__imp_<symbol>` stubs to ensure proper linking. Without this,
+//! the linker would fail with "unresolved external symbol" errors when trying
+//! to reference static data from another crate.
+//!
+//! Regression test for <https://github.com/rust-lang/rust/issues/26591>.
+//! Fixed in <https://github.com/rust-lang/rust/pull/28646>.
+
+//@ run-pass
+//@ aux-build:msvc-static-data-import-lib.rs
+
+extern crate msvc_static_data_import_lib;
+
+fn main() {
+    println!("The answer is {}!", msvc_static_data_import_lib::FOO);
+}
diff --git a/tests/ui/missing_debug_impls.rs b/tests/ui/lint/missing-debug-implementations-lint.rs
similarity index 75%
rename from tests/ui/missing_debug_impls.rs
rename to tests/ui/lint/missing-debug-implementations-lint.rs
index 3abc070..8a93f05 100644
--- a/tests/ui/missing_debug_impls.rs
+++ b/tests/ui/lint/missing-debug-implementations-lint.rs
@@ -1,3 +1,7 @@
+//! Test the `missing_debug_implementations` lint that warns about public types without Debug.
+//!
+//! See https://github.com/rust-lang/rust/issues/20855
+
 //@ compile-flags: --crate-type lib
 #![deny(missing_debug_implementations)]
 #![allow(unused)]
@@ -10,7 +14,6 @@ pub enum A {} //~ ERROR type does not implement `Debug`
 pub enum B {}
 
 pub enum C {}
-
 impl fmt::Debug for C {
     fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
         Ok(())
@@ -23,15 +26,14 @@ fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
 pub struct Bar;
 
 pub struct Baz;
-
 impl fmt::Debug for Baz {
     fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
         Ok(())
     }
 }
 
+// Private types should not trigger the lint
 struct PrivateStruct;
-
 enum PrivateEnum {}
 
 #[derive(Debug)]
diff --git a/tests/ui/missing_debug_impls.stderr b/tests/ui/lint/missing-debug-implementations-lint.stderr
similarity index 74%
rename from tests/ui/missing_debug_impls.stderr
rename to tests/ui/lint/missing-debug-implementations-lint.stderr
index 0538f20..288ab98 100644
--- a/tests/ui/missing_debug_impls.stderr
+++ b/tests/ui/lint/missing-debug-implementations-lint.stderr
@@ -1,17 +1,17 @@
 error: type does not implement `Debug`; consider adding `#[derive(Debug)]` or a manual implementation
-  --> $DIR/missing_debug_impls.rs:7:1
+  --> $DIR/missing-debug-implementations-lint.rs:11:1
    |
 LL | pub enum A {}
    | ^^^^^^^^^^^^^
    |
 note: the lint level is defined here
-  --> $DIR/missing_debug_impls.rs:2:9
+  --> $DIR/missing-debug-implementations-lint.rs:6:9
    |
 LL | #![deny(missing_debug_implementations)]
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error: type does not implement `Debug`; consider adding `#[derive(Debug)]` or a manual implementation
-  --> $DIR/missing_debug_impls.rs:20:1
+  --> $DIR/missing-debug-implementations-lint.rs:23:1
    |
 LL | pub struct Foo;
    | ^^^^^^^^^^^^^^^
diff --git a/tests/ui/lint/unused/unused-attr-duplicate.rs b/tests/ui/lint/unused/unused-attr-duplicate.rs
index 407af40..bf94a42 100644
--- a/tests/ui/lint/unused/unused-attr-duplicate.rs
+++ b/tests/ui/lint/unused/unused-attr-duplicate.rs
@@ -102,4 +102,10 @@ pub fn no_mangle_test() {}
 #[used] //~ ERROR unused attribute
 static FOO: u32 = 0;
 
+#[link_section = ".text"]
+//~^ ERROR unused attribute
+//~| WARN this was previously accepted
+#[link_section = ".bss"]
+pub extern "C" fn example() {}
+
 fn main() {}
diff --git a/tests/ui/lint/unused/unused-attr-duplicate.stderr b/tests/ui/lint/unused/unused-attr-duplicate.stderr
index e845246..feae852 100644
--- a/tests/ui/lint/unused/unused-attr-duplicate.stderr
+++ b/tests/ui/lint/unused/unused-attr-duplicate.stderr
@@ -289,5 +289,18 @@
 LL | #[used]
    | ^^^^^^^
 
-error: aborting due to 23 previous errors
+error: unused attribute
+  --> $DIR/unused-attr-duplicate.rs:105:1
+   |
+LL | #[link_section = ".text"]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove this attribute
+   |
+note: attribute also specified here
+  --> $DIR/unused-attr-duplicate.rs:108:1
+   |
+LL | #[link_section = ".bss"]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+
+error: aborting due to 24 previous errors
 
diff --git a/tests/ui/log-err-phi.rs b/tests/ui/log-err-phi.rs
deleted file mode 100644
index 1bb9775..0000000
--- a/tests/ui/log-err-phi.rs
+++ /dev/null
@@ -1,7 +0,0 @@
-//@ run-pass
-
-pub fn main() {
-    if false {
-        println!("{}", "foobar");
-    }
-}
diff --git a/tests/ui/log-knows-the-names-of-variants.rs b/tests/ui/log-knows-the-names-of-variants.rs
deleted file mode 100644
index cb82cb4..0000000
--- a/tests/ui/log-knows-the-names-of-variants.rs
+++ /dev/null
@@ -1,21 +0,0 @@
-//@ run-pass
-
-#![allow(non_camel_case_types)]
-#![allow(dead_code)]
-#[derive(Debug)]
-enum foo {
-  a(usize),
-  b(String),
-  c,
-}
-
-#[derive(Debug)]
-enum bar {
-  d, e, f
-}
-
-pub fn main() {
-    assert_eq!("a(22)".to_string(), format!("{:?}", foo::a(22)));
-    assert_eq!("c".to_string(), format!("{:?}", foo::c));
-    assert_eq!("d".to_string(), format!("{:?}", bar::d));
-}
diff --git a/tests/ui/loud_ui.rs b/tests/ui/loud_ui.rs
deleted file mode 100644
index 2a73e49..0000000
--- a/tests/ui/loud_ui.rs
+++ /dev/null
@@ -1,6 +0,0 @@
-//@ should-fail
-
-// this test ensures that when we forget to use
-// any `//~ ERROR` comments whatsoever, that the test doesn't succeed
-
-fn main() {}
diff --git a/tests/ui/lowering/issue-121108.stderr b/tests/ui/lowering/issue-121108.stderr
index e4942e8..f68655a 100644
--- a/tests/ui/lowering/issue-121108.stderr
+++ b/tests/ui/lowering/issue-121108.stderr
@@ -5,7 +5,7 @@
    | ^^^^^^^^^^^^^^^^^^^^^^^
 LL |
 LL | use std::ptr::addr_of;
-   |               ------- the inner attribute doesn't annotate this `use` import
+   |               ------- the inner attribute doesn't annotate this import
    |
 help: perhaps you meant to use an outer attribute
    |
diff --git a/tests/ui/macros/macro-span-issue-116502.stderr b/tests/ui/macros/macro-span-issue-116502.stderr
index 68f8874..024656e 100644
--- a/tests/ui/macros/macro-span-issue-116502.stderr
+++ b/tests/ui/macros/macro-span-issue-116502.stderr
@@ -4,6 +4,17 @@
 LL |             _
    |             ^ not allowed in type signatures
 ...
+LL |     struct S<T = m!()>(m!(), T)
+   |                  ---- in this macro invocation
+   |
+   = note: this error originates in the macro `m` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for structs
+  --> $DIR/macro-span-issue-116502.rs:7:13
+   |
+LL |             _
+   |             ^ not allowed in type signatures
+...
 LL |         T: Trait<m!()>;
    |                  ---- in this macro invocation
    |
@@ -20,17 +31,6 @@
    |
    = note: this error originates in the macro `m` (in Nightly builds, run with -Z macro-backtrace for more info)
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for structs
-  --> $DIR/macro-span-issue-116502.rs:7:13
-   |
-LL |             _
-   |             ^ not allowed in type signatures
-...
-LL |     struct S<T = m!()>(m!(), T)
-   |                  ---- in this macro invocation
-   |
-   = note: this error originates in the macro `m` (in Nightly builds, run with -Z macro-backtrace for more info)
-
 error: aborting due to 3 previous errors
 
 For more information about this error, try `rustc --explain E0121`.
diff --git a/tests/ui/macros/macro-metavar-expr-concat/allowed-operations.rs b/tests/ui/macros/metavar-expressions/concat-allowed-operations.rs
similarity index 100%
rename from tests/ui/macros/macro-metavar-expr-concat/allowed-operations.rs
rename to tests/ui/macros/metavar-expressions/concat-allowed-operations.rs
diff --git a/tests/ui/macros/macro-metavar-expr-concat/hygiene.rs b/tests/ui/macros/metavar-expressions/concat-hygiene.rs
similarity index 100%
rename from tests/ui/macros/macro-metavar-expr-concat/hygiene.rs
rename to tests/ui/macros/metavar-expressions/concat-hygiene.rs
diff --git a/tests/ui/macros/macro-metavar-expr-concat/hygiene.stderr b/tests/ui/macros/metavar-expressions/concat-hygiene.stderr
similarity index 93%
rename from tests/ui/macros/macro-metavar-expr-concat/hygiene.stderr
rename to tests/ui/macros/metavar-expressions/concat-hygiene.stderr
index ef2326d..f3150d3 100644
--- a/tests/ui/macros/macro-metavar-expr-concat/hygiene.stderr
+++ b/tests/ui/macros/metavar-expressions/concat-hygiene.stderr
@@ -1,5 +1,5 @@
 error[E0425]: cannot find value `abcdef` in this scope
-  --> $DIR/hygiene.rs:5:10
+  --> $DIR/concat-hygiene.rs:5:10
    |
 LL |         ${concat($lhs, $rhs)}
    |          ^^^^^^^^^^^^^^^^^^^^ not found in this scope
diff --git a/tests/ui/macros/macro-metavar-expr-concat/raw-identifiers.rs b/tests/ui/macros/metavar-expressions/concat-raw-identifiers.rs
similarity index 100%
rename from tests/ui/macros/macro-metavar-expr-concat/raw-identifiers.rs
rename to tests/ui/macros/metavar-expressions/concat-raw-identifiers.rs
diff --git a/tests/ui/macros/macro-metavar-expr-concat/raw-identifiers.stderr b/tests/ui/macros/metavar-expressions/concat-raw-identifiers.stderr
similarity index 80%
rename from tests/ui/macros/macro-metavar-expr-concat/raw-identifiers.stderr
rename to tests/ui/macros/metavar-expressions/concat-raw-identifiers.stderr
index 4e11e20..7abab6a 100644
--- a/tests/ui/macros/macro-metavar-expr-concat/raw-identifiers.stderr
+++ b/tests/ui/macros/metavar-expressions/concat-raw-identifiers.stderr
@@ -1,47 +1,47 @@
 error: expected identifier or string literal
-  --> $DIR/raw-identifiers.rs:28:22
+  --> $DIR/concat-raw-identifiers.rs:28:22
    |
 LL |         let ${concat(r#abc, abc)}: () = ();
    |                      ^^^^^
 
 error: expected identifier or string literal
-  --> $DIR/raw-identifiers.rs:32:27
+  --> $DIR/concat-raw-identifiers.rs:32:27
    |
 LL |         let ${concat(abc, r#abc)}: () = ();
    |                           ^^^^^
 
 error: expected identifier or string literal
-  --> $DIR/raw-identifiers.rs:35:22
+  --> $DIR/concat-raw-identifiers.rs:35:22
    |
 LL |         let ${concat(r#abc, r#abc)}: () = ();
    |                      ^^^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:5:28
+  --> $DIR/concat-raw-identifiers.rs:5:28
    |
 LL |         let ${concat(abc, $rhs)}: () = ();
    |                            ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:12:23
+  --> $DIR/concat-raw-identifiers.rs:12:23
    |
 LL |         let ${concat($lhs, abc)}: () = ();
    |                       ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:19:23
+  --> $DIR/concat-raw-identifiers.rs:19:23
    |
 LL |         let ${concat($lhs, $rhs)}: () = ();
    |                       ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:19:29
+  --> $DIR/concat-raw-identifiers.rs:19:29
    |
 LL |         let ${concat($lhs, $rhs)}: () = ();
    |                             ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:19:23
+  --> $DIR/concat-raw-identifiers.rs:19:23
    |
 LL |         let ${concat($lhs, $rhs)}: () = ();
    |                       ^^^
@@ -49,31 +49,31 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:42:28
+  --> $DIR/concat-raw-identifiers.rs:42:28
    |
 LL |         let ${concat(abc, $rhs)}: () = ();
    |                            ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:49:23
+  --> $DIR/concat-raw-identifiers.rs:49:23
    |
 LL |         let ${concat($lhs, abc)}: () = ();
    |                       ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:56:23
+  --> $DIR/concat-raw-identifiers.rs:56:23
    |
 LL |         let ${concat($lhs, $rhs)}: () = ();
    |                       ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:56:29
+  --> $DIR/concat-raw-identifiers.rs:56:29
    |
 LL |         let ${concat($lhs, $rhs)}: () = ();
    |                             ^^^
 
 error: `${concat(..)}` currently does not support raw identifiers
-  --> $DIR/raw-identifiers.rs:56:23
+  --> $DIR/concat-raw-identifiers.rs:56:23
    |
 LL |         let ${concat($lhs, $rhs)}: () = ();
    |                       ^^^
@@ -81,7 +81,7 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: expected pattern, found `$`
-  --> $DIR/raw-identifiers.rs:28:13
+  --> $DIR/concat-raw-identifiers.rs:28:13
    |
 LL |         let ${concat(r#abc, abc)}: () = ();
    |             ^ expected pattern
diff --git a/tests/ui/macros/macro-metavar-expr-concat/repetitions.rs b/tests/ui/macros/metavar-expressions/concat-repetitions.rs
similarity index 100%
rename from tests/ui/macros/macro-metavar-expr-concat/repetitions.rs
rename to tests/ui/macros/metavar-expressions/concat-repetitions.rs
diff --git a/tests/ui/macros/macro-metavar-expr-concat/repetitions.stderr b/tests/ui/macros/metavar-expressions/concat-repetitions.stderr
similarity index 79%
rename from tests/ui/macros/macro-metavar-expr-concat/repetitions.stderr
rename to tests/ui/macros/metavar-expressions/concat-repetitions.stderr
index c3006c4..18b0a90 100644
--- a/tests/ui/macros/macro-metavar-expr-concat/repetitions.stderr
+++ b/tests/ui/macros/metavar-expressions/concat-repetitions.stderr
@@ -1,17 +1,17 @@
 error: invalid syntax
-  --> $DIR/repetitions.rs:14:20
+  --> $DIR/concat-repetitions.rs:14:20
    |
 LL |             const ${concat($a, Z)}: i32 = 3;
    |                    ^^^^^^^^^^^^^^^
 
 error: invalid syntax
-  --> $DIR/repetitions.rs:22:17
+  --> $DIR/concat-repetitions.rs:22:17
    |
 LL |         read::<${concat($t, $en)}>()
    |                 ^^^^^^^^^^^^^^^^^
 
 error: invalid syntax
-  --> $DIR/repetitions.rs:22:17
+  --> $DIR/concat-repetitions.rs:22:17
    |
 LL |         read::<${concat($t, $en)}>()
    |                 ^^^^^^^^^^^^^^^^^
diff --git a/tests/ui/macros/metavar-expressions/concat-trace-errors.rs b/tests/ui/macros/metavar-expressions/concat-trace-errors.rs
new file mode 100644
index 0000000..45407f5
--- /dev/null
+++ b/tests/ui/macros/metavar-expressions/concat-trace-errors.rs
@@ -0,0 +1,33 @@
+// Our diagnostics should be able to point to a specific input that caused an invalid
+// identifier.
+
+#![feature(macro_metavar_expr_concat)]
+
+// See what we can do without expanding anything
+macro_rules! pre_expansion {
+    ($a:ident) => {
+        ${concat("hi", " bye ")};
+        ${concat("hi", "-", "bye")};
+        ${concat($a, "-")};
+    }
+}
+
+macro_rules! post_expansion {
+    ($a:literal) => {
+        const _: () = ${concat("hi", $a, "bye")};
+        //~^ ERROR is not generating a valid identifier
+    }
+}
+
+post_expansion!("!");
+
+macro_rules! post_expansion_many {
+    ($a:ident, $b:ident, $c:ident, $d:literal, $e:ident) => {
+        const _: () = ${concat($a, $b, $c, $d, $e)};
+        //~^ ERROR is not generating a valid identifier
+    }
+}
+
+post_expansion_many!(a, b, c, ".d", e);
+
+fn main() {}
diff --git a/tests/ui/macros/metavar-expressions/concat-trace-errors.stderr b/tests/ui/macros/metavar-expressions/concat-trace-errors.stderr
new file mode 100644
index 0000000..dac8b58
--- /dev/null
+++ b/tests/ui/macros/metavar-expressions/concat-trace-errors.stderr
@@ -0,0 +1,24 @@
+error: `${concat(..)}` is not generating a valid identifier
+  --> $DIR/concat-trace-errors.rs:17:24
+   |
+LL |         const _: () = ${concat("hi", $a, "bye")};
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^
+...
+LL | post_expansion!("!");
+   | -------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `post_expansion` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error: `${concat(..)}` is not generating a valid identifier
+  --> $DIR/concat-trace-errors.rs:26:24
+   |
+LL |         const _: () = ${concat($a, $b, $c, $d, $e)};
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+...
+LL | post_expansion_many!(a, b, c, ".d", e);
+   | -------------------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `post_expansion_many` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error: aborting due to 2 previous errors
+
diff --git a/tests/ui/macros/macro-metavar-expr-concat/unicode-expansion.rs b/tests/ui/macros/metavar-expressions/concat-unicode-expansion.rs
similarity index 100%
rename from tests/ui/macros/macro-metavar-expr-concat/unicode-expansion.rs
rename to tests/ui/macros/metavar-expressions/concat-unicode-expansion.rs
diff --git a/tests/ui/macros/macro-metavar-expr-concat/syntax-errors.rs b/tests/ui/macros/metavar-expressions/concat-usage-errors.rs
similarity index 80%
rename from tests/ui/macros/macro-metavar-expr-concat/syntax-errors.rs
rename to tests/ui/macros/metavar-expressions/concat-usage-errors.rs
index 7673bd3..7d8756d 100644
--- a/tests/ui/macros/macro-metavar-expr-concat/syntax-errors.rs
+++ b/tests/ui/macros/metavar-expressions/concat-usage-errors.rs
@@ -1,6 +1,8 @@
+//@ edition: 2021
+
 #![feature(macro_metavar_expr_concat)]
 
-macro_rules! wrong_concat_declarations {
+macro_rules! syntax_errors {
     ($ex:expr) => {
         ${concat()}
         //~^ ERROR expected identifier
@@ -90,11 +92,31 @@ macro_rules! unsupported_literals {
         //~| ERROR expected pattern
         let ${concat(_a, 1)}: () = ();
         //~^ ERROR expected identifier or string literal
+        let ${concat(_a, 1.5)}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat(_a, c"hi")}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat(_a, b"hi")}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat(_a, b'b')}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat(_a, b'b')}: () = ();
+        //~^ ERROR expected identifier or string literal
 
         let ${concat($ident, 'b')}: () = ();
         //~^ ERROR expected identifier or string literal
         let ${concat($ident, 1)}: () = ();
         //~^ ERROR expected identifier or string literal
+        let ${concat($ident, 1.5)}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat($ident, c"hi")}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat($ident, b"hi")}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat($ident, b'b')}: () = ();
+        //~^ ERROR expected identifier or string literal
+        let ${concat($ident, b'b')}: () = ();
+        //~^ ERROR expected identifier or string literal
     }};
 }
 
@@ -132,7 +154,7 @@ macro_rules! bad_tt_literal {
 }
 
 fn main() {
-    wrong_concat_declarations!(1);
+    syntax_errors!(1);
 
     dollar_sign_without_referenced_ident!(VAR);
 
diff --git a/tests/ui/macros/macro-metavar-expr-concat/syntax-errors.stderr b/tests/ui/macros/metavar-expressions/concat-usage-errors.stderr
similarity index 73%
rename from tests/ui/macros/macro-metavar-expr-concat/syntax-errors.stderr
rename to tests/ui/macros/metavar-expressions/concat-usage-errors.stderr
index 2de6d2b..8be3e79 100644
--- a/tests/ui/macros/macro-metavar-expr-concat/syntax-errors.stderr
+++ b/tests/ui/macros/metavar-expressions/concat-usage-errors.stderr
@@ -1,71 +1,131 @@
 error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:5:10
+  --> $DIR/concat-usage-errors.rs:7:10
    |
 LL |         ${concat()}
    |          ^^^^^^^^^^
 
 error: `concat` must have at least two elements
-  --> $DIR/syntax-errors.rs:8:11
+  --> $DIR/concat-usage-errors.rs:10:11
    |
 LL |         ${concat(aaaa)}
    |           ^^^^^^
 
 error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:11:10
+  --> $DIR/concat-usage-errors.rs:13:10
    |
 LL |         ${concat(aaaa,)}
    |          ^^^^^^^^^^^^^^^
 
 error: expected comma
-  --> $DIR/syntax-errors.rs:16:10
+  --> $DIR/concat-usage-errors.rs:18:10
    |
 LL |         ${concat(aaaa aaaa)}
    |          ^^^^^^^^^^^^^^^^^^^
 
 error: `concat` must have at least two elements
-  --> $DIR/syntax-errors.rs:19:11
+  --> $DIR/concat-usage-errors.rs:21:11
    |
 LL |         ${concat($ex)}
    |           ^^^^^^
 
 error: expected comma
-  --> $DIR/syntax-errors.rs:25:10
+  --> $DIR/concat-usage-errors.rs:27:10
    |
 LL |         ${concat($ex, aaaa 123)}
    |          ^^^^^^^^^^^^^^^^^^^^^^^
 
 error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:28:10
+  --> $DIR/concat-usage-errors.rs:30:10
    |
 LL |         ${concat($ex, aaaa,)}
    |          ^^^^^^^^^^^^^^^^^^^^
 
 error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:88:26
+  --> $DIR/concat-usage-errors.rs:90:26
    |
 LL |         let ${concat(_a, 'b')}: () = ();
    |                          ^^^
 
 error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:91:26
+  --> $DIR/concat-usage-errors.rs:93:26
    |
 LL |         let ${concat(_a, 1)}: () = ();
    |                          ^
 
 error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:94:30
+  --> $DIR/concat-usage-errors.rs:95:26
+   |
+LL |         let ${concat(_a, 1.5)}: () = ();
+   |                          ^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:97:26
+   |
+LL |         let ${concat(_a, c"hi")}: () = ();
+   |                          ^^^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:99:26
+   |
+LL |         let ${concat(_a, b"hi")}: () = ();
+   |                          ^^^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:101:26
+   |
+LL |         let ${concat(_a, b'b')}: () = ();
+   |                          ^^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:103:26
+   |
+LL |         let ${concat(_a, b'b')}: () = ();
+   |                          ^^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:106:30
    |
 LL |         let ${concat($ident, 'b')}: () = ();
    |                              ^^^
 
 error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:96:30
+  --> $DIR/concat-usage-errors.rs:108:30
    |
 LL |         let ${concat($ident, 1)}: () = ();
    |                              ^
 
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:110:30
+   |
+LL |         let ${concat($ident, 1.5)}: () = ();
+   |                              ^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:112:30
+   |
+LL |         let ${concat($ident, c"hi")}: () = ();
+   |                              ^^^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:114:30
+   |
+LL |         let ${concat($ident, b"hi")}: () = ();
+   |                              ^^^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:116:30
+   |
+LL |         let ${concat($ident, b'b')}: () = ();
+   |                              ^^^^
+
+error: expected identifier or string literal
+  --> $DIR/concat-usage-errors.rs:118:30
+   |
+LL |         let ${concat($ident, b'b')}: () = ();
+   |                              ^^^^
+
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:22:19
+  --> $DIR/concat-usage-errors.rs:24:19
    |
 LL |         ${concat($ex, aaaa)}
    |                   ^^
@@ -73,13 +133,13 @@
    = note: currently only string literals are supported
 
 error: variable `foo` is not recognized in meta-variable expression
-  --> $DIR/syntax-errors.rs:35:30
+  --> $DIR/concat-usage-errors.rs:37:30
    |
 LL |         const ${concat(FOO, $foo)}: i32 = 2;
    |                              ^^^
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:42:14
+  --> $DIR/concat-usage-errors.rs:44:14
    |
 LL |         let ${concat("1", $ident)}: () = ();
    |              ^^^^^^^^^^^^^^^^^^^^^
@@ -90,7 +150,7 @@
    = note: this error originates in the macro `starting_number` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:55:14
+  --> $DIR/concat-usage-errors.rs:57:14
    |
 LL |         let ${concat("\u{00BD}", $ident)}: () = ();
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -101,7 +161,7 @@
    = note: this error originates in the macro `starting_invalid_unicode` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:74:14
+  --> $DIR/concat-usage-errors.rs:76:14
    |
 LL |         let ${concat($ident, "\u{00BD}")}: () = ();
    |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -112,7 +172,7 @@
    = note: this error originates in the macro `ending_invalid_unicode` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: expected pattern, found `$`
-  --> $DIR/syntax-errors.rs:88:13
+  --> $DIR/concat-usage-errors.rs:90:13
    |
 LL |         let ${concat(_a, 'b')}: () = ();
    |             ^ expected pattern
@@ -123,7 +183,7 @@
    = note: this error originates in the macro `unsupported_literals` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:81:14
+  --> $DIR/concat-usage-errors.rs:83:14
    |
 LL |         let ${concat("", "")}: () = ();
    |              ^^^^^^^^^^^^^^^^
@@ -134,7 +194,7 @@
    = note: this error originates in the macro `empty` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:103:16
+  --> $DIR/concat-usage-errors.rs:125:16
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -145,7 +205,7 @@
    = note: this error originates in the macro `bad_literal_string` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:103:16
+  --> $DIR/concat-usage-errors.rs:125:16
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -156,7 +216,7 @@
    = note: this error originates in the macro `bad_literal_string` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:103:16
+  --> $DIR/concat-usage-errors.rs:125:16
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -167,7 +227,7 @@
    = note: this error originates in the macro `bad_literal_string` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:103:16
+  --> $DIR/concat-usage-errors.rs:125:16
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -178,7 +238,7 @@
    = note: this error originates in the macro `bad_literal_string` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:103:16
+  --> $DIR/concat-usage-errors.rs:125:16
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -189,7 +249,7 @@
    = note: this error originates in the macro `bad_literal_string` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:103:16
+  --> $DIR/concat-usage-errors.rs:125:16
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -200,7 +260,7 @@
    = note: this error originates in the macro `bad_literal_string` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: `${concat(..)}` is not generating a valid identifier
-  --> $DIR/syntax-errors.rs:103:16
+  --> $DIR/concat-usage-errors.rs:125:16
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -211,7 +271,7 @@
    = note: this error originates in the macro `bad_literal_string` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:116:31
+  --> $DIR/concat-usage-errors.rs:138:31
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                               ^^^^^^^
@@ -219,7 +279,7 @@
    = note: currently only string literals are supported
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:116:31
+  --> $DIR/concat-usage-errors.rs:138:31
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                               ^^^^^^^
@@ -228,7 +288,7 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:116:31
+  --> $DIR/concat-usage-errors.rs:138:31
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                               ^^^^^^^
@@ -237,7 +297,7 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:116:31
+  --> $DIR/concat-usage-errors.rs:138:31
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                               ^^^^^^^
@@ -246,7 +306,7 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:116:31
+  --> $DIR/concat-usage-errors.rs:138:31
    |
 LL |         const ${concat(_foo, $literal)}: () = ();
    |                               ^^^^^^^
@@ -255,7 +315,7 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:127:31
+  --> $DIR/concat-usage-errors.rs:149:31
    |
 LL |         const ${concat(_foo, $tt)}: () = ();
    |                               ^^
@@ -263,7 +323,7 @@
    = note: currently only string literals are supported
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:127:31
+  --> $DIR/concat-usage-errors.rs:149:31
    |
 LL |         const ${concat(_foo, $tt)}: () = ();
    |                               ^^
@@ -272,7 +332,7 @@
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
 error: metavariables of `${concat(..)}` must be of type `ident`, `literal` or `tt`
-  --> $DIR/syntax-errors.rs:127:31
+  --> $DIR/concat-usage-errors.rs:149:31
    |
 LL |         const ${concat(_foo, $tt)}: () = ();
    |                               ^^
@@ -280,5 +340,5 @@
    = note: currently only string literals are supported
    = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 
-error: aborting due to 33 previous errors
+error: aborting due to 43 previous errors
 
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/count-and-length-are-distinct.rs b/tests/ui/macros/metavar-expressions/count-and-length-are-distinct.rs
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/count-and-length-are-distinct.rs
rename to tests/ui/macros/metavar-expressions/count-and-length-are-distinct.rs
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/issue-111904.rs b/tests/ui/macros/metavar-expressions/count-empty-index-arg.rs
similarity index 65%
rename from tests/ui/macros/rfc-3086-metavar-expr/issue-111904.rs
rename to tests/ui/macros/metavar-expressions/count-empty-index-arg.rs
index 3000bfe..69880ee 100644
--- a/tests/ui/macros/rfc-3086-metavar-expr/issue-111904.rs
+++ b/tests/ui/macros/metavar-expressions/count-empty-index-arg.rs
@@ -1,3 +1,6 @@
+// Issue: https://github.com/rust-lang/rust/issues/111904
+// Ensure that a trailing `,` is not interpreted as a `0`.
+
 #![feature(macro_metavar_expr)]
 
 macro_rules! foo {
@@ -10,5 +13,4 @@ fn test() {
     foo!(a, a; b, b);
 }
 
-fn main() {
-}
+fn main() {}
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/issue-111904.stderr b/tests/ui/macros/metavar-expressions/count-empty-index-arg.stderr
similarity index 87%
rename from tests/ui/macros/rfc-3086-metavar-expr/issue-111904.stderr
rename to tests/ui/macros/metavar-expressions/count-empty-index-arg.stderr
index fd53c16..e1f9d02 100644
--- a/tests/ui/macros/rfc-3086-metavar-expr/issue-111904.stderr
+++ b/tests/ui/macros/metavar-expressions/count-empty-index-arg.stderr
@@ -1,11 +1,11 @@
 error: `count` followed by a comma must have an associated index indicating its depth
-  --> $DIR/issue-111904.rs:4:37
+  --> $DIR/count-empty-index-arg.rs:7:37
    |
 LL |     ( $( $($t:ident),* );* ) => { ${count($t,)} }
    |                                     ^^^^^
 
 error: expected expression, found `$`
-  --> $DIR/issue-111904.rs:4:35
+  --> $DIR/count-empty-index-arg.rs:7:35
    |
 LL |     ( $( $($t:ident),* );* ) => { ${count($t,)} }
    |                                   ^ expected expression
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/dollar-dollar-has-correct-behavior.rs b/tests/ui/macros/metavar-expressions/dollar-dollar-has-correct-behavior.rs
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/dollar-dollar-has-correct-behavior.rs
rename to tests/ui/macros/metavar-expressions/dollar-dollar-has-correct-behavior.rs
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/feature-gate-macro_metavar_expr.rs b/tests/ui/macros/metavar-expressions/feature-gate-macro_metavar_expr.rs
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/feature-gate-macro_metavar_expr.rs
rename to tests/ui/macros/metavar-expressions/feature-gate-macro_metavar_expr.rs
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/macro-expansion.rs b/tests/ui/macros/metavar-expressions/macro-expansion.rs
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/macro-expansion.rs
rename to tests/ui/macros/metavar-expressions/macro-expansion.rs
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/out-of-bounds-arguments.rs b/tests/ui/macros/metavar-expressions/out-of-bounds-arguments.rs
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/out-of-bounds-arguments.rs
rename to tests/ui/macros/metavar-expressions/out-of-bounds-arguments.rs
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/out-of-bounds-arguments.stderr b/tests/ui/macros/metavar-expressions/out-of-bounds-arguments.stderr
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/out-of-bounds-arguments.stderr
rename to tests/ui/macros/metavar-expressions/out-of-bounds-arguments.stderr
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/required-feature.rs b/tests/ui/macros/metavar-expressions/required-feature.rs
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/required-feature.rs
rename to tests/ui/macros/metavar-expressions/required-feature.rs
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/required-feature.stderr b/tests/ui/macros/metavar-expressions/required-feature.stderr
similarity index 100%
rename from tests/ui/macros/rfc-3086-metavar-expr/required-feature.stderr
rename to tests/ui/macros/metavar-expressions/required-feature.stderr
diff --git a/tests/ui/macros/metavar-expressions/syntax-errors.rs b/tests/ui/macros/metavar-expressions/syntax-errors.rs
new file mode 100644
index 0000000..8fc76a7
--- /dev/null
+++ b/tests/ui/macros/metavar-expressions/syntax-errors.rs
@@ -0,0 +1,117 @@
+// General syntax errors that apply to all matavariable expressions
+//
+// We don't invoke the macros here to ensure code gets rejected at the definition rather than
+// only when expanded.
+
+#![feature(macro_metavar_expr)]
+
+macro_rules! dollar_dollar_in_the_lhs {
+    ( $$ $a:ident ) => {
+        //~^ ERROR unexpected token: $
+    };
+}
+
+macro_rules! metavar_in_the_lhs {
+    ( ${ len() } ) => {
+        //~^ ERROR unexpected token: {
+        //~| ERROR expected one of: `*`, `+`, or `?`
+    };
+}
+
+macro_rules! metavar_token_without_ident {
+    ( $( $i:ident ),* ) => { ${ ignore() } };
+    //~^ ERROR meta-variable expressions must be referenced using a dollar sign
+}
+
+macro_rules! metavar_with_literal_suffix {
+    ( $( $i:ident ),* ) => { ${ index(1u32) } };
+    //~^ ERROR only unsuffixes integer literals are supported in meta-variable expressions
+}
+
+macro_rules! mve_without_parens {
+    ( $( $i:ident ),* ) => { ${ count } };
+    //~^ ERROR meta-variable expression parameter must be wrapped in parentheses
+}
+
+#[rustfmt::skip]
+macro_rules! empty_expression {
+    () => { ${} };
+    //~^ ERROR expected identifier or string literal
+}
+
+#[rustfmt::skip]
+macro_rules! open_brackets_with_lit {
+     () => { ${ "hi" } };
+     //~^ ERROR expected identifier
+ }
+
+macro_rules! mve_wrong_delim {
+    ( $( $i:ident ),* ) => { ${ count{i} } };
+    //~^ ERROR meta-variable expression parameter must be wrapped in parentheses
+}
+
+macro_rules! invalid_metavar {
+    () => { ${ignore($123)} }
+    //~^ ERROR expected identifier, found `123`
+}
+
+#[rustfmt::skip]
+macro_rules! open_brackets_with_group {
+    ( $( $i:ident ),* ) => { ${ {} } };
+    //~^ ERROR expected identifier
+}
+
+macro_rules! extra_garbage_after_metavar {
+    ( $( $i:ident ),* ) => {
+        ${count() a b c}
+        //~^ ERROR unexpected token: a
+        ${count($i a b c)}
+        //~^ ERROR unexpected token: a
+        ${count($i, 1 a b c)}
+        //~^ ERROR unexpected token: a
+        ${count($i) a b c}
+        //~^ ERROR unexpected token: a
+
+        ${ignore($i) a b c}
+        //~^ ERROR unexpected token: a
+        ${ignore($i a b c)}
+        //~^ ERROR unexpected token: a
+
+        ${index() a b c}
+        //~^ ERROR unexpected token: a
+        ${index(1 a b c)}
+        //~^ ERROR unexpected token: a
+
+        ${index() a b c}
+        //~^ ERROR unexpected token: a
+        ${index(1 a b c)}
+        //~^ ERROR unexpected token: a
+    };
+}
+
+const IDX: usize = 1;
+macro_rules! metavar_depth_is_not_literal {
+    ( $( $i:ident ),* ) => { ${ index(IDX) } };
+    //~^ ERROR meta-variable expression depth must be a literal
+}
+
+macro_rules! unknown_count_ident {
+    ( $( $i:ident )* ) => {
+        ${count(foo)}
+        //~^ ERROR meta-variable expressions must be referenced using a dollar sign
+    };
+}
+
+macro_rules! unknown_ignore_ident {
+    ( $( $i:ident )* ) => {
+        ${ignore(bar)}
+        //~^ ERROR meta-variable expressions must be referenced using a dollar sign
+    };
+}
+
+macro_rules! unknown_metavar {
+    ( $( $i:ident ),* ) => { ${ aaaaaaaaaaaaaa(i) } };
+    //~^ ERROR unrecognized meta-variable expression
+}
+
+fn main() {}
diff --git a/tests/ui/macros/metavar-expressions/syntax-errors.stderr b/tests/ui/macros/metavar-expressions/syntax-errors.stderr
new file mode 100644
index 0000000..20d2358
--- /dev/null
+++ b/tests/ui/macros/metavar-expressions/syntax-errors.stderr
@@ -0,0 +1,224 @@
+error: unexpected token: $
+  --> $DIR/syntax-errors.rs:9:8
+   |
+LL |     ( $$ $a:ident ) => {
+   |        ^
+
+note: `$$` and meta-variable expressions are not allowed inside macro parameter definitions
+  --> $DIR/syntax-errors.rs:9:8
+   |
+LL |     ( $$ $a:ident ) => {
+   |        ^
+
+error: unexpected token: {
+  --> $DIR/syntax-errors.rs:15:8
+   |
+LL |     ( ${ len() } ) => {
+   |        ^^^^^^^^^
+
+note: `$$` and meta-variable expressions are not allowed inside macro parameter definitions
+  --> $DIR/syntax-errors.rs:15:8
+   |
+LL |     ( ${ len() } ) => {
+   |        ^^^^^^^^^
+
+error: expected one of: `*`, `+`, or `?`
+  --> $DIR/syntax-errors.rs:15:8
+   |
+LL |     ( ${ len() } ) => {
+   |        ^^^^^^^^^
+
+error: meta-variables within meta-variable expressions must be referenced using a dollar sign
+  --> $DIR/syntax-errors.rs:22:33
+   |
+LL |     ( $( $i:ident ),* ) => { ${ ignore() } };
+   |                                 ^^^^^^
+
+error: only unsuffixes integer literals are supported in meta-variable expressions
+  --> $DIR/syntax-errors.rs:27:33
+   |
+LL |     ( $( $i:ident ),* ) => { ${ index(1u32) } };
+   |                                 ^^^^^
+
+error: meta-variable expression parameter must be wrapped in parentheses
+  --> $DIR/syntax-errors.rs:32:33
+   |
+LL |     ( $( $i:ident ),* ) => { ${ count } };
+   |                                 ^^^^^
+
+error: meta-variable expression parameter must be wrapped in parentheses
+  --> $DIR/syntax-errors.rs:49:33
+   |
+LL |     ( $( $i:ident ),* ) => { ${ count{i} } };
+   |                                 ^^^^^
+
+error: expected identifier, found `123`
+  --> $DIR/syntax-errors.rs:54:23
+   |
+LL |     () => { ${ignore($123)} }
+   |                       ^^^ help: try removing `123`
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:66:19
+   |
+LL |         ${count() a b c}
+   |                   ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:66:19
+   |
+LL |         ${count() a b c}
+   |                   ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:68:20
+   |
+LL |         ${count($i a b c)}
+   |                    ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:68:20
+   |
+LL |         ${count($i a b c)}
+   |                    ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:70:23
+   |
+LL |         ${count($i, 1 a b c)}
+   |                       ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:70:23
+   |
+LL |         ${count($i, 1 a b c)}
+   |                       ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:72:21
+   |
+LL |         ${count($i) a b c}
+   |                     ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:72:21
+   |
+LL |         ${count($i) a b c}
+   |                     ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:75:22
+   |
+LL |         ${ignore($i) a b c}
+   |                      ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:75:22
+   |
+LL |         ${ignore($i) a b c}
+   |                      ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:77:21
+   |
+LL |         ${ignore($i a b c)}
+   |                     ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:77:21
+   |
+LL |         ${ignore($i a b c)}
+   |                     ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:80:19
+   |
+LL |         ${index() a b c}
+   |                   ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:80:19
+   |
+LL |         ${index() a b c}
+   |                   ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:82:19
+   |
+LL |         ${index(1 a b c)}
+   |                   ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:82:19
+   |
+LL |         ${index(1 a b c)}
+   |                   ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:85:19
+   |
+LL |         ${index() a b c}
+   |                   ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:85:19
+   |
+LL |         ${index() a b c}
+   |                   ^
+
+error: unexpected token: a
+  --> $DIR/syntax-errors.rs:87:19
+   |
+LL |         ${index(1 a b c)}
+   |                   ^
+   |
+note: meta-variable expression must not have trailing tokens
+  --> $DIR/syntax-errors.rs:87:19
+   |
+LL |         ${index(1 a b c)}
+   |                   ^
+
+error: meta-variable expression depth must be a literal
+  --> $DIR/syntax-errors.rs:94:33
+   |
+LL |     ( $( $i:ident ),* ) => { ${ index(IDX) } };
+   |                                 ^^^^^
+
+error: meta-variables within meta-variable expressions must be referenced using a dollar sign
+  --> $DIR/syntax-errors.rs:100:11
+   |
+LL |         ${count(foo)}
+   |           ^^^^^
+
+error: meta-variables within meta-variable expressions must be referenced using a dollar sign
+  --> $DIR/syntax-errors.rs:107:11
+   |
+LL |         ${ignore(bar)}
+   |           ^^^^^^
+
+error: unrecognized meta-variable expression
+  --> $DIR/syntax-errors.rs:113:33
+   |
+LL |     ( $( $i:ident ),* ) => { ${ aaaaaaaaaaaaaa(i) } };
+   |                                 ^^^^^^^^^^^^^^ help: supported expressions are count, ignore, index and len
+
+error: expected identifier or string literal
+  --> $DIR/syntax-errors.rs:38:14
+   |
+LL |     () => { ${} };
+   |              ^^
+
+error: expected identifier, found `"hi"`
+  --> $DIR/syntax-errors.rs:44:17
+   |
+LL |      () => { ${ "hi" } };
+   |                 ^^^^ help: try removing `"hi"`
+
+error: expected identifier or string literal
+  --> $DIR/syntax-errors.rs:60:33
+   |
+LL |     ( $( $i:ident ),* ) => { ${ {} } };
+   |                                 ^^
+
+error: aborting due to 25 previous errors
+
diff --git a/tests/ui/macros/metavar-expressions/usage-errors.rs b/tests/ui/macros/metavar-expressions/usage-errors.rs
new file mode 100644
index 0000000..feff02e
--- /dev/null
+++ b/tests/ui/macros/metavar-expressions/usage-errors.rs
@@ -0,0 +1,55 @@
+// Errors for the `count` and `length` metavariable expressions
+
+#![feature(macro_metavar_expr)]
+
+// `curly` = Right hand side curly brackets
+// `no_rhs_dollar` = No dollar sign at the right hand side meta variable "function"
+// `round` = Left hand side round brackets
+
+macro_rules! curly__no_rhs_dollar__round {
+    ( $( $i:ident ),* ) => { ${ count($i) } };
+}
+const _: u32 = curly__no_rhs_dollar__round!(a, b, c);
+
+macro_rules! curly__no_rhs_dollar__no_round {
+    ( $i:ident ) => { ${ count($i) } };
+    //~^ ERROR `count` can not be placed inside the innermost repetition
+}
+curly__no_rhs_dollar__no_round!(a);
+
+macro_rules! curly__rhs_dollar__no_round {
+    ( $i:ident ) => { ${ count($i) } };
+    //~^ ERROR `count` can not be placed inside the innermost repetition
+}
+curly__rhs_dollar__no_round !(a);
+
+#[rustfmt::skip] // autoformatters can break a few of the error traces
+macro_rules! no_curly__no_rhs_dollar__round {
+    ( $( $i:ident ),* ) => { count(i) };
+    //~^ ERROR missing `fn` or `struct` for function or struct definition
+}
+no_curly__no_rhs_dollar__round !(a, b, c);
+
+#[rustfmt::skip] // autoformatters can break a few of the error traces
+macro_rules! no_curly__no_rhs_dollar__no_round {
+    ( $i:ident ) => { count(i) };
+    //~^ ERROR missing `fn` or `struct` for function or struct definition
+}
+no_curly__no_rhs_dollar__no_round !(a);
+
+#[rustfmt::skip] // autoformatters can break a few of the error traces
+macro_rules! no_curly__rhs_dollar__round {
+    ( $( $i:ident ),* ) => { count($i) };
+    //~^ ERROR variable `i` is still repeating at this depth
+}
+no_curly__rhs_dollar__round! (a);
+
+#[rustfmt::skip] // autoformatters can break a few of the error traces
+macro_rules! no_curly__rhs_dollar__no_round {
+    ( $i:ident ) => { count($i) };
+    //~^ ERROR cannot find function `count` in this scope
+}
+const _: u32 = no_curly__rhs_dollar__no_round! (a);
+//~^ ERROR cannot find value `a` in this scope
+
+fn main() {}
diff --git a/tests/ui/macros/metavar-expressions/usage-errors.stderr b/tests/ui/macros/metavar-expressions/usage-errors.stderr
new file mode 100644
index 0000000..f66f522
--- /dev/null
+++ b/tests/ui/macros/metavar-expressions/usage-errors.stderr
@@ -0,0 +1,71 @@
+error: `count` can not be placed inside the innermost repetition
+  --> $DIR/usage-errors.rs:15:24
+   |
+LL |     ( $i:ident ) => { ${ count($i) } };
+   |                        ^^^^^^^^^^^^^
+
+error: `count` can not be placed inside the innermost repetition
+  --> $DIR/usage-errors.rs:21:24
+   |
+LL |     ( $i:ident ) => { ${ count($i) } };
+   |                        ^^^^^^^^^^^^^
+
+error: missing `fn` or `struct` for function or struct definition
+  --> $DIR/usage-errors.rs:28:30
+   |
+LL |     ( $( $i:ident ),* ) => { count(i) };
+   |                              ^^^^^
+...
+LL | no_curly__no_rhs_dollar__round !(a, b, c);
+   | ----------------------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `no_curly__no_rhs_dollar__round` (in Nightly builds, run with -Z macro-backtrace for more info)
+help: if you meant to call a macro, try
+   |
+LL |     ( $( $i:ident ),* ) => { count!(i) };
+   |                                   +
+
+error: missing `fn` or `struct` for function or struct definition
+  --> $DIR/usage-errors.rs:35:23
+   |
+LL |     ( $i:ident ) => { count(i) };
+   |                       ^^^^^
+...
+LL | no_curly__no_rhs_dollar__no_round !(a);
+   | -------------------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `no_curly__no_rhs_dollar__no_round` (in Nightly builds, run with -Z macro-backtrace for more info)
+help: if you meant to call a macro, try
+   |
+LL |     ( $i:ident ) => { count!(i) };
+   |                            +
+
+error: variable `i` is still repeating at this depth
+  --> $DIR/usage-errors.rs:42:36
+   |
+LL |     ( $( $i:ident ),* ) => { count($i) };
+   |                                    ^^
+
+error[E0425]: cannot find value `a` in this scope
+  --> $DIR/usage-errors.rs:52:49
+   |
+LL |     ( $i:ident ) => { count($i) };
+   |                             -- due to this macro variable
+...
+LL | const _: u32 = no_curly__rhs_dollar__no_round! (a);
+   |                                                 ^ not found in this scope
+
+error[E0425]: cannot find function `count` in this scope
+  --> $DIR/usage-errors.rs:49:23
+   |
+LL |     ( $i:ident ) => { count($i) };
+   |                       ^^^^^ not found in this scope
+...
+LL | const _: u32 = no_curly__rhs_dollar__no_round! (a);
+   |                ----------------------------------- in this macro invocation
+   |
+   = note: this error originates in the macro `no_curly__rhs_dollar__no_round` (in Nightly builds, run with -Z macro-backtrace for more info)
+
+error: aborting due to 7 previous errors
+
+For more information about this error, try `rustc --explain E0425`.
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/syntax-errors.rs b/tests/ui/macros/rfc-3086-metavar-expr/syntax-errors.rs
deleted file mode 100644
index 78cede9..0000000
--- a/tests/ui/macros/rfc-3086-metavar-expr/syntax-errors.rs
+++ /dev/null
@@ -1,164 +0,0 @@
-#![feature(macro_metavar_expr)]
-
-// `curly` = Right hand side curly brackets
-// `no_rhs_dollar` = No dollar sign at the right hand side meta variable "function"
-// `round` = Left hand side round brackets
-
-macro_rules! curly__no_rhs_dollar__round {
-    ( $( $i:ident ),* ) => { ${ count($i) } };
-}
-
-macro_rules! curly__no_rhs_dollar__no_round {
-    ( $i:ident ) => { ${ count($i) } };
-    //~^ ERROR `count` can not be placed inside the innermost repetition
-}
-
-macro_rules! curly__rhs_dollar__no_round {
-    ( $i:ident ) => { ${ count($i) } };
-    //~^ ERROR `count` can not be placed inside the innermost repetition
-}
-
-#[rustfmt::skip] // autoformatters can break a few of the error traces
-macro_rules! no_curly__no_rhs_dollar__round {
-    ( $( $i:ident ),* ) => { count(i) };
-    //~^ ERROR cannot find function `count` in this scope
-    //~| ERROR cannot find value `i` in this scope
-}
-
-#[rustfmt::skip] // autoformatters can break a few of the error traces
-macro_rules! no_curly__no_rhs_dollar__no_round {
-    ( $i:ident ) => { count(i) };
-    //~^ ERROR cannot find function `count` in this scope
-    //~| ERROR cannot find value `i` in this scope
-}
-
-#[rustfmt::skip] // autoformatters can break a few of the error traces
-macro_rules! no_curly__rhs_dollar__round {
-    ( $( $i:ident ),* ) => { count($i) };
-    //~^ ERROR variable `i` is still repeating at this depth
-}
-
-#[rustfmt::skip] // autoformatters can break a few of the error traces
-macro_rules! no_curly__rhs_dollar__no_round {
-    ( $i:ident ) => { count($i) };
-    //~^ ERROR cannot find function `count` in this scope
-}
-
-// Other scenarios
-
-macro_rules! dollar_dollar_in_the_lhs {
-    ( $$ $a:ident ) => {
-        //~^ ERROR unexpected token: $
-    };
-}
-
-macro_rules! extra_garbage_after_metavar {
-    ( $( $i:ident ),* ) => {
-        ${count() a b c}
-        //~^ ERROR unexpected token: a
-        //~| ERROR expected expression, found `$`
-        ${count($i a b c)}
-        //~^ ERROR unexpected token: a
-        ${count($i, 1 a b c)}
-        //~^ ERROR unexpected token: a
-        ${count($i) a b c}
-        //~^ ERROR unexpected token: a
-
-        ${ignore($i) a b c}
-        //~^ ERROR unexpected token: a
-        ${ignore($i a b c)}
-        //~^ ERROR unexpected token: a
-
-        ${index() a b c}
-        //~^ ERROR unexpected token: a
-        ${index(1 a b c)}
-        //~^ ERROR unexpected token: a
-
-        ${index() a b c}
-        //~^ ERROR unexpected token: a
-        ${index(1 a b c)}
-        //~^ ERROR unexpected token: a
-    };
-}
-
-const IDX: usize = 1;
-macro_rules! metavar_depth_is_not_literal {
-    ( $( $i:ident ),* ) => { ${ index(IDX) } };
-    //~^ ERROR meta-variable expression depth must be a literal
-    //~| ERROR expected expression, found `$`
-}
-
-macro_rules! metavar_in_the_lhs {
-    ( ${ len() } ) => {
-        //~^ ERROR unexpected token: {
-        //~| ERROR expected one of: `*`, `+`, or `?`
-    };
-}
-
-macro_rules! metavar_token_without_ident {
-    ( $( $i:ident ),* ) => { ${ ignore() } };
-    //~^ ERROR meta-variable expressions must be referenced using a dollar sign
-    //~| ERROR expected expression
-}
-
-macro_rules! metavar_with_literal_suffix {
-    ( $( $i:ident ),* ) => { ${ index(1u32) } };
-    //~^ ERROR only unsuffixes integer literals are supported in meta-variable expressions
-    //~| ERROR expected expression, found `$`
-}
-
-macro_rules! metavar_without_parens {
-    ( $( $i:ident ),* ) => { ${ count{i} } };
-    //~^ ERROR meta-variable expression parameter must be wrapped in parentheses
-    //~| ERROR expected expression, found `$`
-}
-
-#[rustfmt::skip]
-macro_rules! open_brackets_without_tokens {
-    ( $( $i:ident ),* ) => { ${ {} } };
-    //~^ ERROR expected expression, found `$`
-    //~| ERROR expected identifier
-}
-
-macro_rules! unknown_count_ident {
-    ( $( $i:ident )* ) => {
-        ${count(foo)}
-        //~^ ERROR meta-variable expressions must be referenced using a dollar sign
-        //~| ERROR expected expression
-    };
-}
-
-macro_rules! unknown_ignore_ident {
-    ( $( $i:ident )* ) => {
-        ${ignore(bar)}
-        //~^ ERROR meta-variable expressions must be referenced using a dollar sign
-        //~| ERROR expected expression
-    };
-}
-
-macro_rules! unknown_metavar {
-    ( $( $i:ident ),* ) => { ${ aaaaaaaaaaaaaa(i) } };
-    //~^ ERROR unrecognized meta-variable expression
-    //~| ERROR expected expression
-}
-
-fn main() {
-    curly__no_rhs_dollar__round!(a, b, c);
-    curly__no_rhs_dollar__no_round!(a);
-    curly__rhs_dollar__no_round!(a);
-    no_curly__no_rhs_dollar__round!(a, b, c);
-    no_curly__no_rhs_dollar__no_round!(a);
-    no_curly__rhs_dollar__round!(a, b, c);
-    no_curly__rhs_dollar__no_round!(a);
-    //~^ ERROR cannot find value `a` in this scope
-
-    extra_garbage_after_metavar!(a);
-    metavar_depth_is_not_literal!(a);
-    metavar_token_without_ident!(a);
-    metavar_with_literal_suffix!(a);
-    metavar_without_parens!(a);
-    open_brackets_without_tokens!(a);
-    unknown_count_ident!(a);
-    unknown_ignore_ident!(a);
-    unknown_metavar!(a);
-}
diff --git a/tests/ui/macros/rfc-3086-metavar-expr/syntax-errors.stderr b/tests/ui/macros/rfc-3086-metavar-expr/syntax-errors.stderr
deleted file mode 100644
index d964676..0000000
--- a/tests/ui/macros/rfc-3086-metavar-expr/syntax-errors.stderr
+++ /dev/null
@@ -1,382 +0,0 @@
-error: unexpected token: $
-  --> $DIR/syntax-errors.rs:50:8
-   |
-LL |     ( $$ $a:ident ) => {
-   |        ^
-
-note: `$$` and meta-variable expressions are not allowed inside macro parameter definitions
-  --> $DIR/syntax-errors.rs:50:8
-   |
-LL |     ( $$ $a:ident ) => {
-   |        ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:57:19
-   |
-LL |         ${count() a b c}
-   |                   ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:57:19
-   |
-LL |         ${count() a b c}
-   |                   ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:60:20
-   |
-LL |         ${count($i a b c)}
-   |                    ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:60:20
-   |
-LL |         ${count($i a b c)}
-   |                    ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:62:23
-   |
-LL |         ${count($i, 1 a b c)}
-   |                       ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:62:23
-   |
-LL |         ${count($i, 1 a b c)}
-   |                       ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:64:21
-   |
-LL |         ${count($i) a b c}
-   |                     ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:64:21
-   |
-LL |         ${count($i) a b c}
-   |                     ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:67:22
-   |
-LL |         ${ignore($i) a b c}
-   |                      ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:67:22
-   |
-LL |         ${ignore($i) a b c}
-   |                      ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:69:21
-   |
-LL |         ${ignore($i a b c)}
-   |                     ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:69:21
-   |
-LL |         ${ignore($i a b c)}
-   |                     ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:72:19
-   |
-LL |         ${index() a b c}
-   |                   ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:72:19
-   |
-LL |         ${index() a b c}
-   |                   ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:74:19
-   |
-LL |         ${index(1 a b c)}
-   |                   ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:74:19
-   |
-LL |         ${index(1 a b c)}
-   |                   ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:77:19
-   |
-LL |         ${index() a b c}
-   |                   ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:77:19
-   |
-LL |         ${index() a b c}
-   |                   ^
-
-error: unexpected token: a
-  --> $DIR/syntax-errors.rs:79:19
-   |
-LL |         ${index(1 a b c)}
-   |                   ^
-   |
-note: meta-variable expression must not have trailing tokens
-  --> $DIR/syntax-errors.rs:79:19
-   |
-LL |         ${index(1 a b c)}
-   |                   ^
-
-error: meta-variable expression depth must be a literal
-  --> $DIR/syntax-errors.rs:86:33
-   |
-LL |     ( $( $i:ident ),* ) => { ${ index(IDX) } };
-   |                                 ^^^^^
-
-error: unexpected token: {
-  --> $DIR/syntax-errors.rs:92:8
-   |
-LL |     ( ${ len() } ) => {
-   |        ^^^^^^^^^
-
-note: `$$` and meta-variable expressions are not allowed inside macro parameter definitions
-  --> $DIR/syntax-errors.rs:92:8
-   |
-LL |     ( ${ len() } ) => {
-   |        ^^^^^^^^^
-
-error: expected one of: `*`, `+`, or `?`
-  --> $DIR/syntax-errors.rs:92:8
-   |
-LL |     ( ${ len() } ) => {
-   |        ^^^^^^^^^
-
-error: meta-variables within meta-variable expressions must be referenced using a dollar sign
-  --> $DIR/syntax-errors.rs:99:33
-   |
-LL |     ( $( $i:ident ),* ) => { ${ ignore() } };
-   |                                 ^^^^^^
-
-error: only unsuffixes integer literals are supported in meta-variable expressions
-  --> $DIR/syntax-errors.rs:105:33
-   |
-LL |     ( $( $i:ident ),* ) => { ${ index(1u32) } };
-   |                                 ^^^^^
-
-error: meta-variable expression parameter must be wrapped in parentheses
-  --> $DIR/syntax-errors.rs:111:33
-   |
-LL |     ( $( $i:ident ),* ) => { ${ count{i} } };
-   |                                 ^^^^^
-
-error: meta-variables within meta-variable expressions must be referenced using a dollar sign
-  --> $DIR/syntax-errors.rs:125:11
-   |
-LL |         ${count(foo)}
-   |           ^^^^^
-
-error: meta-variables within meta-variable expressions must be referenced using a dollar sign
-  --> $DIR/syntax-errors.rs:133:11
-   |
-LL |         ${ignore(bar)}
-   |           ^^^^^^
-
-error: unrecognized meta-variable expression
-  --> $DIR/syntax-errors.rs:140:33
-   |
-LL |     ( $( $i:ident ),* ) => { ${ aaaaaaaaaaaaaa(i) } };
-   |                                 ^^^^^^^^^^^^^^ help: supported expressions are count, ignore, index and len
-
-error: expected identifier or string literal
-  --> $DIR/syntax-errors.rs:118:33
-   |
-LL |     ( $( $i:ident ),* ) => { ${ {} } };
-   |                                 ^^
-
-error: `count` can not be placed inside the innermost repetition
-  --> $DIR/syntax-errors.rs:12:24
-   |
-LL |     ( $i:ident ) => { ${ count($i) } };
-   |                        ^^^^^^^^^^^^^
-
-error: `count` can not be placed inside the innermost repetition
-  --> $DIR/syntax-errors.rs:17:24
-   |
-LL |     ( $i:ident ) => { ${ count($i) } };
-   |                        ^^^^^^^^^^^^^
-
-error: variable `i` is still repeating at this depth
-  --> $DIR/syntax-errors.rs:37:36
-   |
-LL |     ( $( $i:ident ),* ) => { count($i) };
-   |                                    ^^
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:57:9
-   |
-LL |         ${count() a b c}
-   |         ^ expected expression
-...
-LL |     extra_garbage_after_metavar!(a);
-   |     ------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `extra_garbage_after_metavar` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:86:30
-   |
-LL |     ( $( $i:ident ),* ) => { ${ index(IDX) } };
-   |                              ^ expected expression
-...
-LL |     metavar_depth_is_not_literal!(a);
-   |     -------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `metavar_depth_is_not_literal` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:99:30
-   |
-LL |     ( $( $i:ident ),* ) => { ${ ignore() } };
-   |                              ^ expected expression
-...
-LL |     metavar_token_without_ident!(a);
-   |     ------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `metavar_token_without_ident` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:105:30
-   |
-LL |     ( $( $i:ident ),* ) => { ${ index(1u32) } };
-   |                              ^ expected expression
-...
-LL |     metavar_with_literal_suffix!(a);
-   |     ------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `metavar_with_literal_suffix` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:111:30
-   |
-LL |     ( $( $i:ident ),* ) => { ${ count{i} } };
-   |                              ^ expected expression
-...
-LL |     metavar_without_parens!(a);
-   |     -------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `metavar_without_parens` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:118:30
-   |
-LL |     ( $( $i:ident ),* ) => { ${ {} } };
-   |                              ^ expected expression
-...
-LL |     open_brackets_without_tokens!(a);
-   |     -------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `open_brackets_without_tokens` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:125:9
-   |
-LL |         ${count(foo)}
-   |         ^ expected expression
-...
-LL |     unknown_count_ident!(a);
-   |     ----------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `unknown_count_ident` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:133:9
-   |
-LL |         ${ignore(bar)}
-   |         ^ expected expression
-...
-LL |     unknown_ignore_ident!(a);
-   |     ------------------------ in this macro invocation
-   |
-   = note: this error originates in the macro `unknown_ignore_ident` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: expected expression, found `$`
-  --> $DIR/syntax-errors.rs:140:30
-   |
-LL |     ( $( $i:ident ),* ) => { ${ aaaaaaaaaaaaaa(i) } };
-   |                              ^ expected expression
-...
-LL |     unknown_metavar!(a);
-   |     ------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `unknown_metavar` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error[E0425]: cannot find value `i` in this scope
-  --> $DIR/syntax-errors.rs:23:36
-   |
-LL |     ( $( $i:ident ),* ) => { count(i) };
-   |                                    ^ not found in this scope
-...
-LL |     no_curly__no_rhs_dollar__round!(a, b, c);
-   |     ---------------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `no_curly__no_rhs_dollar__round` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error[E0425]: cannot find value `i` in this scope
-  --> $DIR/syntax-errors.rs:30:29
-   |
-LL |     ( $i:ident ) => { count(i) };
-   |                             ^ not found in this scope
-...
-LL |     no_curly__no_rhs_dollar__no_round!(a);
-   |     ------------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `no_curly__no_rhs_dollar__no_round` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error[E0425]: cannot find value `a` in this scope
-  --> $DIR/syntax-errors.rs:152:37
-   |
-LL |     ( $i:ident ) => { count($i) };
-   |                             -- due to this macro variable
-...
-LL |     no_curly__rhs_dollar__no_round!(a);
-   |                                     ^ not found in this scope
-
-error[E0425]: cannot find function `count` in this scope
-  --> $DIR/syntax-errors.rs:23:30
-   |
-LL |     ( $( $i:ident ),* ) => { count(i) };
-   |                              ^^^^^ not found in this scope
-...
-LL |     no_curly__no_rhs_dollar__round!(a, b, c);
-   |     ---------------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `no_curly__no_rhs_dollar__round` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error[E0425]: cannot find function `count` in this scope
-  --> $DIR/syntax-errors.rs:30:23
-   |
-LL |     ( $i:ident ) => { count(i) };
-   |                       ^^^^^ not found in this scope
-...
-LL |     no_curly__no_rhs_dollar__no_round!(a);
-   |     ------------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `no_curly__no_rhs_dollar__no_round` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error[E0425]: cannot find function `count` in this scope
-  --> $DIR/syntax-errors.rs:43:23
-   |
-LL |     ( $i:ident ) => { count($i) };
-   |                       ^^^^^ not found in this scope
-...
-LL |     no_curly__rhs_dollar__no_round!(a);
-   |     ---------------------------------- in this macro invocation
-   |
-   = note: this error originates in the macro `no_curly__rhs_dollar__no_round` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: aborting due to 39 previous errors
-
-For more information about this error, try `rustc --explain E0425`.
diff --git a/tests/ui/maximal_mir_to_hir_coverage.rs b/tests/ui/maximal_mir_to_hir_coverage.rs
deleted file mode 100644
index e57c83d..0000000
--- a/tests/ui/maximal_mir_to_hir_coverage.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-//@ compile-flags: -Zmaximal-hir-to-mir-coverage
-//@ run-pass
-
-// Just making sure this flag is accepted and doesn't crash the compiler
-
-fn main() {
-  let x = 1;
-  let y = x + 1;
-  println!("{y}");
-}
diff --git a/tests/ui/maybe-bounds.rs b/tests/ui/maybe-bounds.rs
deleted file mode 100644
index 02ed45c..0000000
--- a/tests/ui/maybe-bounds.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-trait Tr: ?Sized {}
-//~^ ERROR `?Trait` is not permitted in supertraits
-
-type A1 = dyn Tr + (?Sized);
-//~^ ERROR `?Trait` is not permitted in trait object types
-type A2 = dyn for<'a> Tr + (?Sized);
-//~^ ERROR `?Trait` is not permitted in trait object types
-
-fn main() {}
diff --git a/tests/ui/method-output-diff-issue-127263.rs b/tests/ui/method-output-diff-issue-127263.rs
deleted file mode 100644
index 85a903e..0000000
--- a/tests/ui/method-output-diff-issue-127263.rs
+++ /dev/null
@@ -1,8 +0,0 @@
-fn bar() {}
-fn foo(x: i32) -> u32 {
-    0
-}
-fn main() {
-    let b: fn() -> u32 = bar; //~ ERROR mismatched types [E0308]
-    let f: fn(i32) = foo; //~ ERROR mismatched types [E0308]
-}
diff --git a/tests/ui/methods/filter-relevant-fn-bounds.rs b/tests/ui/methods/filter-relevant-fn-bounds.rs
index 76ececf..6233c9d 100644
--- a/tests/ui/methods/filter-relevant-fn-bounds.rs
+++ b/tests/ui/methods/filter-relevant-fn-bounds.rs
@@ -7,11 +7,10 @@
 impl Wrapper {
     fn do_something_wrapper<O, F>(self, _: F)
     //~^ ERROR the trait bound `for<'a> F: Output<'a>` is not satisfied
-    //~| ERROR the trait bound `for<'a> F: Output<'a>` is not satisfied
     where
         F: for<'a> FnOnce(<F as Output<'a>>::Type),
-        //~^ ERROR the trait bound `F: Output<'_>` is not satisfied
-        //~| ERROR the trait bound `F: Output<'_>` is not satisfied
+        //~^ ERROR the trait bound `for<'a> F: Output<'a>` is not satisfied
+        //~| ERROR the trait bound `for<'a> F: Output<'a>` is not satisfied
     {
     }
 }
diff --git a/tests/ui/methods/filter-relevant-fn-bounds.stderr b/tests/ui/methods/filter-relevant-fn-bounds.stderr
index 0e00adf..82103e6 100644
--- a/tests/ui/methods/filter-relevant-fn-bounds.stderr
+++ b/tests/ui/methods/filter-relevant-fn-bounds.stderr
@@ -3,7 +3,6 @@
    |
 LL | /     fn do_something_wrapper<O, F>(self, _: F)
 LL | |
-LL | |
 LL | |     where
 LL | |         F: for<'a> FnOnce(<F as Output<'a>>::Type),
    | |___________________________________________________^ the trait `for<'a> Output<'a>` is not implemented for `F`
@@ -14,54 +13,43 @@
    |                                                    ++++++++++++++++++++
 
 error[E0277]: the trait bound `for<'a> F: Output<'a>` is not satisfied
-  --> $DIR/filter-relevant-fn-bounds.rs:8:8
+  --> $DIR/filter-relevant-fn-bounds.rs:11:12
    |
-LL |     fn do_something_wrapper<O, F>(self, _: F)
-   |        ^^^^^^^^^^^^^^^^^^^^ the trait `for<'a> Output<'a>` is not implemented for `F`
+LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type),
+   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `for<'a> Output<'a>` is not implemented for `F`
    |
 help: consider further restricting type parameter `F` with trait `Output`
    |
 LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type) + for<'a> Output<'a>,
    |                                                    ++++++++++++++++++++
 
-error[E0277]: the trait bound `F: Output<'_>` is not satisfied
-  --> $DIR/filter-relevant-fn-bounds.rs:12:12
+error[E0277]: the trait bound `for<'a> F: Output<'a>` is not satisfied
+  --> $DIR/filter-relevant-fn-bounds.rs:11:20
    |
 LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type),
-   |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Output<'_>` is not implemented for `F`
+   |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `for<'a> Output<'a>` is not implemented for `F`
    |
 help: consider further restricting type parameter `F` with trait `Output`
    |
-LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type) + Output<'_>,
-   |                                                    ++++++++++++
+LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type) + for<'a> Output<'a>,
+   |                                                    ++++++++++++++++++++
 
-error[E0277]: the trait bound `F: Output<'_>` is not satisfied
-  --> $DIR/filter-relevant-fn-bounds.rs:12:20
-   |
-LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type),
-   |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Output<'_>` is not implemented for `F`
-   |
-help: consider further restricting type parameter `F` with trait `Output`
-   |
-LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type) + Output<'_>,
-   |                                                    ++++++++++++
-
-error[E0277]: expected a `FnOnce(<{closure@$DIR/filter-relevant-fn-bounds.rs:21:34: 21:41} as Output<'a>>::Type)` closure, found `{closure@$DIR/filter-relevant-fn-bounds.rs:21:34: 21:41}`
-  --> $DIR/filter-relevant-fn-bounds.rs:21:34
+error[E0277]: expected a `FnOnce(<{closure@$DIR/filter-relevant-fn-bounds.rs:20:34: 20:41} as Output<'a>>::Type)` closure, found `{closure@$DIR/filter-relevant-fn-bounds.rs:20:34: 20:41}`
+  --> $DIR/filter-relevant-fn-bounds.rs:20:34
    |
 LL |     wrapper.do_something_wrapper(|value| ());
-   |             -------------------- ^^^^^^^^^^ expected an `FnOnce(<{closure@$DIR/filter-relevant-fn-bounds.rs:21:34: 21:41} as Output<'a>>::Type)` closure, found `{closure@$DIR/filter-relevant-fn-bounds.rs:21:34: 21:41}`
+   |             -------------------- ^^^^^^^^^^ expected an `FnOnce(<{closure@$DIR/filter-relevant-fn-bounds.rs:20:34: 20:41} as Output<'a>>::Type)` closure, found `{closure@$DIR/filter-relevant-fn-bounds.rs:20:34: 20:41}`
    |             |
    |             required by a bound introduced by this call
    |
-   = help: the trait `for<'a> Output<'a>` is not implemented for closure `{closure@$DIR/filter-relevant-fn-bounds.rs:21:34: 21:41}`
+   = help: the trait `for<'a> Output<'a>` is not implemented for closure `{closure@$DIR/filter-relevant-fn-bounds.rs:20:34: 20:41}`
 help: this trait has no implementations, consider adding one
   --> $DIR/filter-relevant-fn-bounds.rs:1:1
    |
 LL | trait Output<'a> {
    | ^^^^^^^^^^^^^^^^
 note: required by a bound in `Wrapper::do_something_wrapper`
-  --> $DIR/filter-relevant-fn-bounds.rs:12:12
+  --> $DIR/filter-relevant-fn-bounds.rs:11:12
    |
 LL |     fn do_something_wrapper<O, F>(self, _: F)
    |        -------------------- required by a bound in this associated function
@@ -69,6 +57,6 @@
 LL |         F: for<'a> FnOnce(<F as Output<'a>>::Type),
    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `Wrapper::do_something_wrapper`
 
-error: aborting due to 5 previous errors
+error: aborting due to 4 previous errors
 
 For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/mismatched_types/fn-pointer-mismatch-diagnostics.rs b/tests/ui/mismatched_types/fn-pointer-mismatch-diagnostics.rs
new file mode 100644
index 0000000..e28ca3e
--- /dev/null
+++ b/tests/ui/mismatched_types/fn-pointer-mismatch-diagnostics.rs
@@ -0,0 +1,16 @@
+//! This test checks that when there's a type mismatch between a function item and
+//! a function pointer, the error message focuses on the actual type difference
+//! (return types, argument types) rather than the confusing "pointer vs item" distinction.
+//!
+//! See https://github.com/rust-lang/rust/issues/127263
+
+fn bar() {}
+
+fn foo(x: i32) -> u32 {
+    0
+}
+
+fn main() {
+    let b: fn() -> u32 = bar; //~ ERROR mismatched types [E0308]
+    let f: fn(i32) = foo; //~ ERROR mismatched types [E0308]
+}
diff --git a/tests/ui/method-output-diff-issue-127263.stderr b/tests/ui/mismatched_types/fn-pointer-mismatch-diagnostics.stderr
similarity index 86%
rename from tests/ui/method-output-diff-issue-127263.stderr
rename to tests/ui/mismatched_types/fn-pointer-mismatch-diagnostics.stderr
index 35b8611..8d63f2e 100644
--- a/tests/ui/method-output-diff-issue-127263.stderr
+++ b/tests/ui/mismatched_types/fn-pointer-mismatch-diagnostics.stderr
@@ -1,5 +1,5 @@
 error[E0308]: mismatched types
-  --> $DIR/method-output-diff-issue-127263.rs:6:26
+  --> $DIR/fn-pointer-mismatch-diagnostics.rs:14:26
    |
 LL |     let b: fn() -> u32 = bar;
    |            -----------   ^^^ expected fn pointer, found fn item
@@ -10,7 +10,7 @@
                  found fn item `fn() -> () {bar}`
 
 error[E0308]: mismatched types
-  --> $DIR/method-output-diff-issue-127263.rs:7:22
+  --> $DIR/fn-pointer-mismatch-diagnostics.rs:15:22
    |
 LL |     let f: fn(i32) = foo;
    |            -------   ^^^ expected fn pointer, found fn item
diff --git a/tests/ui/integral-variable-unification-error.rs b/tests/ui/mismatched_types/int-float-type-mismatch.rs
similarity index 64%
rename from tests/ui/integral-variable-unification-error.rs
rename to tests/ui/mismatched_types/int-float-type-mismatch.rs
index 8d16213..b45d027 100644
--- a/tests/ui/integral-variable-unification-error.rs
+++ b/tests/ui/mismatched_types/int-float-type-mismatch.rs
@@ -1,3 +1,6 @@
+//! Check that a type mismatch error is reported when trying
+//! to unify a {float} value assignment to an {integer} variable.
+
 fn main() {
     let mut x //~ NOTE expected due to the type of this binding
         =
diff --git a/tests/ui/integral-variable-unification-error.stderr b/tests/ui/mismatched_types/int-float-type-mismatch.stderr
similarity index 86%
rename from tests/ui/integral-variable-unification-error.stderr
rename to tests/ui/mismatched_types/int-float-type-mismatch.stderr
index 1caa604..43b8609 100644
--- a/tests/ui/integral-variable-unification-error.stderr
+++ b/tests/ui/mismatched_types/int-float-type-mismatch.stderr
@@ -1,5 +1,5 @@
 error[E0308]: mismatched types
-  --> $DIR/integral-variable-unification-error.rs:5:9
+  --> $DIR/int-float-type-mismatch.rs:8:9
    |
 LL |     let mut x
    |         ----- expected due to the type of this binding
diff --git a/tests/ui/mod-subitem-as-enum-variant.rs b/tests/ui/mod-subitem-as-enum-variant.rs
deleted file mode 100644
index 959024c..0000000
--- a/tests/ui/mod-subitem-as-enum-variant.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-mod Mod {
-    pub struct FakeVariant<T>(pub T);
-}
-
-fn main() {
-    Mod::FakeVariant::<i32>(0);
-    Mod::<i32>::FakeVariant(0);
-    //~^ ERROR type arguments are not allowed on module `Mod` [E0109]
-}
diff --git a/tests/ui/modules/nested-modules-basic.rs b/tests/ui/modules/nested-modules-basic.rs
new file mode 100644
index 0000000..12eccec
--- /dev/null
+++ b/tests/ui/modules/nested-modules-basic.rs
@@ -0,0 +1,19 @@
+//! Basic test for nested module functionality and path resolution
+
+//@ run-pass
+
+mod inner {
+    pub mod inner2 {
+        pub fn hello() {
+            println!("hello, modular world");
+        }
+    }
+    pub fn hello() {
+        inner2::hello();
+    }
+}
+
+pub fn main() {
+    inner::hello();
+    inner::inner2::hello();
+}
diff --git a/tests/ui/monomorphize-abi-alignment.rs b/tests/ui/monomorphize-abi-alignment.rs
deleted file mode 100644
index 62df1ac..0000000
--- a/tests/ui/monomorphize-abi-alignment.rs
+++ /dev/null
@@ -1,35 +0,0 @@
-//@ run-pass
-
-#![allow(non_upper_case_globals)]
-#![allow(dead_code)]
-/*!
- * On x86_64-linux-gnu and possibly other platforms, structs get 8-byte "preferred" alignment,
- * but their "ABI" alignment (i.e., what actually matters for data layout) is the largest alignment
- * of any field. (Also, `u64` has 8-byte ABI alignment; this is not always true).
- *
- * On such platforms, if monomorphize uses the "preferred" alignment, then it will unify
- * `A` and `B`, even though `S<A>` and `S<B>` have the field `t` at different offsets,
- * and apply the wrong instance of the method `unwrap`.
- */
-
-#[derive(Copy, Clone)]
-struct S<T> { i:u8, t:T }
-
-impl<T> S<T> {
-    fn unwrap(self) -> T {
-        self.t
-    }
-}
-
-#[derive(Copy, Clone, PartialEq, Debug)]
-struct A((u32, u32));
-
-#[derive(Copy, Clone, PartialEq, Debug)]
-struct B(u64);
-
-pub fn main() {
-    static Ca: S<A> = S { i: 0, t: A((13, 104)) };
-    static Cb: S<B> = S { i: 0, t: B(31337) };
-    assert_eq!(Ca.unwrap(), A((13, 104)));
-    assert_eq!(Cb.unwrap(), B(31337));
-}
diff --git a/tests/ui/msvc-data-only.rs b/tests/ui/msvc-data-only.rs
deleted file mode 100644
index 15d7990..0000000
--- a/tests/ui/msvc-data-only.rs
+++ /dev/null
@@ -1,8 +0,0 @@
-//@ run-pass
-//@ aux-build:msvc-data-only-lib.rs
-
-extern crate msvc_data_only_lib;
-
-fn main() {
-    println!("The answer is {} !", msvc_data_only_lib::FOO);
-}
diff --git a/tests/ui/msvc-opt-minsize.rs b/tests/ui/msvc-opt-minsize.rs
deleted file mode 100644
index c1be168..0000000
--- a/tests/ui/msvc-opt-minsize.rs
+++ /dev/null
@@ -1,31 +0,0 @@
-// A previously outdated version of LLVM caused compilation failures on Windows
-// specifically with optimization level `z`. After the update to a more recent LLVM
-// version, this test checks that compilation and execution both succeed.
-// See https://github.com/rust-lang/rust/issues/45034
-
-//@ ignore-cross-compile
-// Reason: the compiled binary is executed
-//@ only-windows
-// Reason: the observed bug only occurs on Windows
-//@ run-pass
-//@ compile-flags: -C opt-level=z
-
-#![feature(test)]
-extern crate test;
-
-fn foo(x: i32, y: i32) -> i64 {
-    (x + y) as i64
-}
-
-#[inline(never)]
-fn bar() {
-    let _f = Box::new(0);
-    // This call used to trigger an LLVM bug in opt-level z where the base
-    // pointer gets corrupted, see issue #45034
-    let y: fn(i32, i32) -> i64 = test::black_box(foo);
-    test::black_box(y(1, 2));
-}
-
-fn main() {
-    bar();
-}
diff --git a/tests/ui/multibyte.rs b/tests/ui/multibyte.rs
deleted file mode 100644
index d585a79..0000000
--- a/tests/ui/multibyte.rs
+++ /dev/null
@@ -1,7 +0,0 @@
-//@ run-pass
-//
-
-// Test that multibyte characters don't crash the compiler
-pub fn main() {
-    println!("마이너스 사인이 없으면");
-}
diff --git a/tests/ui/multiline-comment.rs b/tests/ui/multiline-comment.rs
deleted file mode 100644
index 9817488..0000000
--- a/tests/ui/multiline-comment.rs
+++ /dev/null
@@ -1,6 +0,0 @@
-//@ run-pass
-
-/*
- * This is a multi-line oldcomment.
- */
-pub fn main() { }
diff --git a/tests/ui/new-import-syntax.rs b/tests/ui/new-import-syntax.rs
deleted file mode 100644
index 547900f..0000000
--- a/tests/ui/new-import-syntax.rs
+++ /dev/null
@@ -1,5 +0,0 @@
-//@ run-pass
-
-pub fn main() {
-    println!("Hello world!");
-}
diff --git a/tests/ui/new-style-constants.rs b/tests/ui/new-style-constants.rs
deleted file mode 100644
index e33a2da..0000000
--- a/tests/ui/new-style-constants.rs
+++ /dev/null
@@ -1,7 +0,0 @@
-//@ run-pass
-
-static FOO: isize = 3;
-
-pub fn main() {
-    println!("{}", FOO);
-}
diff --git a/tests/ui/new-unicode-escapes.rs b/tests/ui/new-unicode-escapes.rs
deleted file mode 100644
index 867a50d..0000000
--- a/tests/ui/new-unicode-escapes.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-//@ run-pass
-
-pub fn main() {
-    let s = "\u{2603}";
-    assert_eq!(s, "☃");
-
-    let s = "\u{2a10}\u{2A01}\u{2Aa0}";
-    assert_eq!(s, "⨐⨁⪠");
-
-    let s = "\\{20}";
-    let mut correct_s = String::from("\\");
-    correct_s.push_str("{20}");
-    assert_eq!(s, correct_s);
-}
diff --git a/tests/ui/newlambdas.rs b/tests/ui/newlambdas.rs
deleted file mode 100644
index 75e851f..0000000
--- a/tests/ui/newlambdas.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-//@ run-pass
-// Tests for the new |args| expr lambda syntax
-
-
-fn f<F>(i: isize, f: F) -> isize where F: FnOnce(isize) -> isize { f(i) }
-
-fn g<G>(_g: G) where G: FnOnce() { }
-
-pub fn main() {
-    assert_eq!(f(10, |a| a), 10);
-    g(||());
-    assert_eq!(f(10, |a| a), 10);
-    g(||{});
-}
diff --git a/tests/ui/newtype-polymorphic.rs b/tests/ui/newtype-polymorphic.rs
deleted file mode 100644
index 146d49f..0000000
--- a/tests/ui/newtype-polymorphic.rs
+++ /dev/null
@@ -1,27 +0,0 @@
-//@ run-pass
-
-#![allow(non_camel_case_types)]
-
-
-#[derive(Clone)]
-struct myvec<X>(Vec<X> );
-
-fn myvec_deref<X:Clone>(mv: myvec<X>) -> Vec<X> {
-    let myvec(v) = mv;
-    return v.clone();
-}
-
-fn myvec_elt<X>(mv: myvec<X>) -> X {
-    let myvec(v) = mv;
-    return v.into_iter().next().unwrap();
-}
-
-pub fn main() {
-    let mv = myvec(vec![1, 2, 3]);
-    let mv_clone = mv.clone();
-    let mv_clone = myvec_deref(mv_clone);
-    assert_eq!(mv_clone[1], 2);
-    assert_eq!(myvec_elt(mv.clone()), 1);
-    let myvec(v) = mv;
-    assert_eq!(v[2], 3);
-}
diff --git a/tests/ui/newtype.rs b/tests/ui/newtype.rs
deleted file mode 100644
index 8a07c67..0000000
--- a/tests/ui/newtype.rs
+++ /dev/null
@@ -1,23 +0,0 @@
-//@ run-pass
-
-#![allow(non_camel_case_types)]
-#[derive(Copy, Clone)]
-struct mytype(Mytype);
-
-#[derive(Copy, Clone)]
-struct Mytype {
-    compute: fn(mytype) -> isize,
-    val: isize,
-}
-
-fn compute(i: mytype) -> isize {
-    let mytype(m) = i;
-    return m.val + 20;
-}
-
-pub fn main() {
-    let myval = mytype(Mytype{compute: compute, val: 30});
-    println!("{}", compute(myval));
-    let mytype(m) = myval;
-    assert_eq!((m.compute)(myval), 50);
-}
diff --git a/tests/ui/no-core-1.rs b/tests/ui/no-core-1.rs
deleted file mode 100644
index d6d2ba6..0000000
--- a/tests/ui/no-core-1.rs
+++ /dev/null
@@ -1,15 +0,0 @@
-//@ run-pass
-
-#![allow(stable_features)]
-#![feature(no_core, core)]
-#![no_core]
-
-extern crate std;
-extern crate core;
-
-use std::option::Option::Some;
-
-fn main() {
-    let a = Some("foo");
-    a.unwrap();
-}
diff --git a/tests/ui/no-core-2.rs b/tests/ui/no-core-2.rs
deleted file mode 100644
index 2f55365..0000000
--- a/tests/ui/no-core-2.rs
+++ /dev/null
@@ -1,20 +0,0 @@
-//@ run-pass
-
-#![allow(dead_code, unused_imports)]
-#![feature(no_core)]
-#![no_core]
-//@ edition:2018
-
-extern crate std;
-extern crate core;
-use core::{prelude::v1::*, *};
-
-fn foo() {
-    for _ in &[()] {}
-}
-
-fn bar() -> Option<()> {
-    None?
-}
-
-fn main() {}
diff --git a/tests/ui/no-send-res-ports.rs b/tests/ui/no-send-res-ports.rs
deleted file mode 100644
index 1bac586..0000000
--- a/tests/ui/no-send-res-ports.rs
+++ /dev/null
@@ -1,30 +0,0 @@
-use std::thread;
-use std::rc::Rc;
-
-#[derive(Debug)]
-struct Port<T>(Rc<T>);
-
-fn main() {
-    #[derive(Debug)]
-    struct Foo {
-      _x: Port<()>,
-    }
-
-    impl Drop for Foo {
-        fn drop(&mut self) {}
-    }
-
-    fn foo(x: Port<()>) -> Foo {
-        Foo {
-            _x: x
-        }
-    }
-
-    let x = foo(Port(Rc::new(())));
-
-    thread::spawn(move|| {
-        //~^ ERROR `Rc<()>` cannot be sent between threads safely
-        let y = x;
-        println!("{:?}", y);
-    });
-}
diff --git a/tests/ui/no-send-res-ports.stderr b/tests/ui/no-send-res-ports.stderr
deleted file mode 100644
index 9c30261..0000000
--- a/tests/ui/no-send-res-ports.stderr
+++ /dev/null
@@ -1,37 +0,0 @@
-error[E0277]: `Rc<()>` cannot be sent between threads safely
-  --> $DIR/no-send-res-ports.rs:25:19
-   |
-LL |       thread::spawn(move|| {
-   |       ------------- ^-----
-   |       |             |
-   |  _____|_____________within this `{closure@$DIR/no-send-res-ports.rs:25:19: 25:25}`
-   | |     |
-   | |     required by a bound introduced by this call
-LL | |
-LL | |         let y = x;
-LL | |         println!("{:?}", y);
-LL | |     });
-   | |_____^ `Rc<()>` cannot be sent between threads safely
-   |
-   = help: within `{closure@$DIR/no-send-res-ports.rs:25:19: 25:25}`, the trait `Send` is not implemented for `Rc<()>`
-note: required because it appears within the type `Port<()>`
-  --> $DIR/no-send-res-ports.rs:5:8
-   |
-LL | struct Port<T>(Rc<T>);
-   |        ^^^^
-note: required because it appears within the type `Foo`
-  --> $DIR/no-send-res-ports.rs:9:12
-   |
-LL |     struct Foo {
-   |            ^^^
-note: required because it's used within this closure
-  --> $DIR/no-send-res-ports.rs:25:19
-   |
-LL |     thread::spawn(move|| {
-   |                   ^^^^^^
-note: required by a bound in `spawn`
-  --> $SRC_DIR/std/src/thread/mod.rs:LL:COL
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/no-warn-on-field-replace-issue-34101.rs b/tests/ui/no-warn-on-field-replace-issue-34101.rs
deleted file mode 100644
index e1d5e9c..0000000
--- a/tests/ui/no-warn-on-field-replace-issue-34101.rs
+++ /dev/null
@@ -1,46 +0,0 @@
-// Issue 34101: Circa 2016-06-05, `fn inline` below issued an
-// erroneous warning from the elaborate_drops pass about moving out of
-// a field in `Foo`, which has a destructor (and thus cannot have
-// content moved out of it). The reason that the warning is erroneous
-// in this case is that we are doing a *replace*, not a move, of the
-// content in question, and it is okay to replace fields within `Foo`.
-//
-// Another more subtle problem was that the elaborate_drops was
-// creating a separate drop flag for that internally replaced content,
-// even though the compiler should enforce an invariant that any drop
-// flag for such subcontent of `Foo` will always have the same value
-// as the drop flag for `Foo` itself.
-
-
-
-
-
-
-
-
-//@ check-pass
-
-struct Foo(String);
-
-impl Drop for Foo {
-    fn drop(&mut self) {}
-}
-
-fn inline() {
-    // (dummy variable so `f` gets assigned `var1` in MIR for both fn's)
-    let _s = ();
-    let mut f = Foo(String::from("foo"));
-    f.0 = String::from("bar");
-}
-
-fn outline() {
-    let _s = String::from("foo");
-    let mut f = Foo(_s);
-    f.0 = String::from("bar");
-}
-
-
-fn main() {
-    inline();
-    outline();
-}
diff --git a/tests/ui/no_send-enum.rs b/tests/ui/no_send-enum.rs
deleted file mode 100644
index bd56064..0000000
--- a/tests/ui/no_send-enum.rs
+++ /dev/null
@@ -1,18 +0,0 @@
-#![feature(negative_impls)]
-
-use std::marker::Send;
-
-struct NoSend;
-impl !Send for NoSend {}
-
-enum Foo {
-    A(NoSend)
-}
-
-fn bar<T: Send>(_: T) {}
-
-fn main() {
-    let x = Foo::A(NoSend);
-    bar(x);
-    //~^ ERROR `NoSend` cannot be sent between threads safely
-}
diff --git a/tests/ui/no_send-enum.stderr b/tests/ui/no_send-enum.stderr
deleted file mode 100644
index 3b66c7d..0000000
--- a/tests/ui/no_send-enum.stderr
+++ /dev/null
@@ -1,23 +0,0 @@
-error[E0277]: `NoSend` cannot be sent between threads safely
-  --> $DIR/no_send-enum.rs:16:9
-   |
-LL |     bar(x);
-   |     --- ^ `NoSend` cannot be sent between threads safely
-   |     |
-   |     required by a bound introduced by this call
-   |
-   = help: within `Foo`, the trait `Send` is not implemented for `NoSend`
-note: required because it appears within the type `Foo`
-  --> $DIR/no_send-enum.rs:8:6
-   |
-LL | enum Foo {
-   |      ^^^
-note: required by a bound in `bar`
-  --> $DIR/no_send-enum.rs:12:11
-   |
-LL | fn bar<T: Send>(_: T) {}
-   |           ^^^^ required by this bound in `bar`
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/no_send-rc.rs b/tests/ui/no_send-rc.rs
deleted file mode 100644
index f31db15..0000000
--- a/tests/ui/no_send-rc.rs
+++ /dev/null
@@ -1,9 +0,0 @@
-use std::rc::Rc;
-
-fn bar<T: Send>(_: T) {}
-
-fn main() {
-    let x = Rc::new(5);
-    bar(x);
-    //~^ ERROR `Rc<{integer}>` cannot be sent between threads safely
-}
diff --git a/tests/ui/no_send-rc.stderr b/tests/ui/no_send-rc.stderr
deleted file mode 100644
index 1430a7a..0000000
--- a/tests/ui/no_send-rc.stderr
+++ /dev/null
@@ -1,22 +0,0 @@
-error[E0277]: `Rc<{integer}>` cannot be sent between threads safely
-  --> $DIR/no_send-rc.rs:7:9
-   |
-LL |     bar(x);
-   |     --- ^ `Rc<{integer}>` cannot be sent between threads safely
-   |     |
-   |     required by a bound introduced by this call
-   |
-   = help: the trait `Send` is not implemented for `Rc<{integer}>`
-note: required by a bound in `bar`
-  --> $DIR/no_send-rc.rs:3:11
-   |
-LL | fn bar<T: Send>(_: T) {}
-   |           ^^^^ required by this bound in `bar`
-help: consider dereferencing here
-   |
-LL |     bar(*x);
-   |         +
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/no_share-enum.rs b/tests/ui/no_share-enum.rs
deleted file mode 100644
index 44bf191..0000000
--- a/tests/ui/no_share-enum.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-#![feature(negative_impls)]
-
-use std::marker::Sync;
-
-struct NoSync;
-impl !Sync for NoSync {}
-
-enum Foo { A(NoSync) }
-
-fn bar<T: Sync>(_: T) {}
-
-fn main() {
-    let x = Foo::A(NoSync);
-    bar(x);
-    //~^ ERROR `NoSync` cannot be shared between threads safely [E0277]
-}
diff --git a/tests/ui/no_share-enum.stderr b/tests/ui/no_share-enum.stderr
deleted file mode 100644
index 8993921..0000000
--- a/tests/ui/no_share-enum.stderr
+++ /dev/null
@@ -1,23 +0,0 @@
-error[E0277]: `NoSync` cannot be shared between threads safely
-  --> $DIR/no_share-enum.rs:14:9
-   |
-LL |     bar(x);
-   |     --- ^ `NoSync` cannot be shared between threads safely
-   |     |
-   |     required by a bound introduced by this call
-   |
-   = help: within `Foo`, the trait `Sync` is not implemented for `NoSync`
-note: required because it appears within the type `Foo`
-  --> $DIR/no_share-enum.rs:8:6
-   |
-LL | enum Foo { A(NoSync) }
-   |      ^^^
-note: required by a bound in `bar`
-  --> $DIR/no_share-enum.rs:10:11
-   |
-LL | fn bar<T: Sync>(_: T) {}
-   |           ^^^^ required by this bound in `bar`
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/no_share-struct.rs b/tests/ui/no_share-struct.rs
deleted file mode 100644
index 7d8a36a..0000000
--- a/tests/ui/no_share-struct.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-#![feature(negative_impls)]
-
-use std::marker::Sync;
-
-struct Foo { a: isize }
-impl !Sync for Foo {}
-
-fn bar<T: Sync>(_: T) {}
-
-fn main() {
-    let x = Foo { a: 5 };
-    bar(x);
-    //~^ ERROR `Foo` cannot be shared between threads safely [E0277]
-}
diff --git a/tests/ui/no_share-struct.stderr b/tests/ui/no_share-struct.stderr
deleted file mode 100644
index 9c7a921..0000000
--- a/tests/ui/no_share-struct.stderr
+++ /dev/null
@@ -1,18 +0,0 @@
-error[E0277]: `Foo` cannot be shared between threads safely
-  --> $DIR/no_share-struct.rs:12:9
-   |
-LL |     bar(x);
-   |     --- ^ `Foo` cannot be shared between threads safely
-   |     |
-   |     required by a bound introduced by this call
-   |
-   = help: the trait `Sync` is not implemented for `Foo`
-note: required by a bound in `bar`
-  --> $DIR/no_share-struct.rs:8:11
-   |
-LL | fn bar<T: Sync>(_: T) {}
-   |           ^^^^ required by this bound in `bar`
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/no_std/no-core-edition2018-syntax.rs b/tests/ui/no_std/no-core-edition2018-syntax.rs
new file mode 100644
index 0000000..9a327e4
--- /dev/null
+++ b/tests/ui/no_std/no-core-edition2018-syntax.rs
@@ -0,0 +1,28 @@
+//! Test that `#![no_core]` doesn't break modern Rust syntax in edition 2018.
+//!
+//! When you use `#![no_core]`, you lose the automatic prelude, but you can still
+//! get everything back by manually importing `use core::{prelude::v1::*, *}`.
+//! This test makes sure that after doing that, things like `for` loops and the
+//! `?` operator still work as expected.
+
+//@ run-pass
+//@ edition:2018
+
+#![allow(dead_code, unused_imports)]
+#![feature(no_core)]
+#![no_core]
+
+extern crate core;
+extern crate std;
+use core::prelude::v1::*;
+use core::*;
+
+fn test_for_loop() {
+    for _ in &[()] {}
+}
+
+fn test_question_mark_operator() -> Option<()> {
+    None?
+}
+
+fn main() {}
diff --git a/tests/ui/no_std/no-core-with-explicit-std-core.rs b/tests/ui/no_std/no-core-with-explicit-std-core.rs
new file mode 100644
index 0000000..3940bcb
--- /dev/null
+++ b/tests/ui/no_std/no-core-with-explicit-std-core.rs
@@ -0,0 +1,21 @@
+//! Test that you can use `#![no_core]` and still import std and core manually.
+//!
+//! The `#![no_core]` attribute disables the automatic core prelude, but you should
+//! still be able to explicitly import both `std` and `core` crates and use types
+//! like `Option` normally.
+
+//@ run-pass
+
+#![allow(stable_features)]
+#![feature(no_core, core)]
+#![no_core]
+
+extern crate core;
+extern crate std;
+
+use std::option::Option::Some;
+
+fn main() {
+    let a = Some("foo");
+    a.unwrap();
+}
diff --git a/tests/ui/noexporttypeexe.stderr b/tests/ui/noexporttypeexe.stderr
deleted file mode 100644
index 59759b6..0000000
--- a/tests/ui/noexporttypeexe.stderr
+++ /dev/null
@@ -1,18 +0,0 @@
-error[E0308]: mismatched types
-  --> $DIR/noexporttypeexe.rs:10:18
-   |
-LL |   let x: isize = noexporttypelib::foo();
-   |          -----   ^^^^^^^^^^^^^^^^^^^^^^ expected `isize`, found `Option<isize>`
-   |          |
-   |          expected due to this
-   |
-   = note: expected type `isize`
-              found enum `Option<isize>`
-help: consider using `Option::expect` to unwrap the `Option<isize>` value, panicking if the value is an `Option::None`
-   |
-LL |   let x: isize = noexporttypelib::foo().expect("REASON");
-   |                                        +++++++++++++++++
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/non-constant-expr-for-arr-len.rs b/tests/ui/non-constant-expr-for-arr-len.rs
deleted file mode 100644
index 1b101d3..0000000
--- a/tests/ui/non-constant-expr-for-arr-len.rs
+++ /dev/null
@@ -1,8 +0,0 @@
-// Check that non constant exprs fail for array repeat syntax
-
-fn main() {
-    fn bar(n: usize) {
-        let _x = [0; n];
-        //~^ ERROR attempt to use a non-constant value in a constant [E0435]
-    }
-}
diff --git a/tests/ui/nonscalar-cast.fixed b/tests/ui/nonscalar-cast.fixed
deleted file mode 100644
index cb5591d..0000000
--- a/tests/ui/nonscalar-cast.fixed
+++ /dev/null
@@ -1,16 +0,0 @@
-//@ run-rustfix
-
-#[derive(Debug)]
-struct Foo {
-    x: isize
-}
-
-impl From<Foo> for isize {
-    fn from(val: Foo) -> isize {
-        val.x
-    }
-}
-
-fn main() {
-    println!("{}", isize::from(Foo { x: 1 })); //~ ERROR non-primitive cast: `Foo` as `isize` [E0605]
-}
diff --git a/tests/ui/nonscalar-cast.rs b/tests/ui/nonscalar-cast.rs
deleted file mode 100644
index 27429b4..0000000
--- a/tests/ui/nonscalar-cast.rs
+++ /dev/null
@@ -1,16 +0,0 @@
-//@ run-rustfix
-
-#[derive(Debug)]
-struct Foo {
-    x: isize
-}
-
-impl From<Foo> for isize {
-    fn from(val: Foo) -> isize {
-        val.x
-    }
-}
-
-fn main() {
-    println!("{}", Foo { x: 1 } as isize); //~ ERROR non-primitive cast: `Foo` as `isize` [E0605]
-}
diff --git a/tests/ui/nonscalar-cast.stderr b/tests/ui/nonscalar-cast.stderr
deleted file mode 100644
index 834d4ea..0000000
--- a/tests/ui/nonscalar-cast.stderr
+++ /dev/null
@@ -1,15 +0,0 @@
-error[E0605]: non-primitive cast: `Foo` as `isize`
-  --> $DIR/nonscalar-cast.rs:15:20
-   |
-LL |     println!("{}", Foo { x: 1 } as isize);
-   |                    ^^^^^^^^^^^^^^^^^^^^^ an `as` expression can only be used to convert between primitive types or to coerce to a specific trait object
-   |
-help: consider using the `From` trait instead
-   |
-LL -     println!("{}", Foo { x: 1 } as isize);
-LL +     println!("{}", isize::from(Foo { x: 1 }));
-   |
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0605`.
diff --git a/tests/ui/not-clone-closure.rs b/tests/ui/not-clone-closure.rs
deleted file mode 100644
index 976e3b9..0000000
--- a/tests/ui/not-clone-closure.rs
+++ /dev/null
@@ -1,13 +0,0 @@
-//@compile-flags: --diagnostic-width=300
-// Check that closures do not implement `Clone` if their environment is not `Clone`.
-
-struct S(i32);
-
-fn main() {
-    let a = S(5);
-    let hello = move || {
-        println!("Hello {}", a.0);
-    };
-
-    let hello = hello.clone(); //~ ERROR the trait bound `S: Clone` is not satisfied
-}
diff --git a/tests/ui/not-clone-closure.stderr b/tests/ui/not-clone-closure.stderr
deleted file mode 100644
index 0c95a99..0000000
--- a/tests/ui/not-clone-closure.stderr
+++ /dev/null
@@ -1,23 +0,0 @@
-error[E0277]: the trait bound `S: Clone` is not satisfied in `{closure@$DIR/not-clone-closure.rs:8:17: 8:24}`
-  --> $DIR/not-clone-closure.rs:12:23
-   |
-LL |     let hello = move || {
-   |                 ------- within this `{closure@$DIR/not-clone-closure.rs:8:17: 8:24}`
-...
-LL |     let hello = hello.clone();
-   |                       ^^^^^ within `{closure@$DIR/not-clone-closure.rs:8:17: 8:24}`, the trait `Clone` is not implemented for `S`
-   |
-note: required because it's used within this closure
-  --> $DIR/not-clone-closure.rs:8:17
-   |
-LL |     let hello = move || {
-   |                 ^^^^^^^
-help: consider annotating `S` with `#[derive(Clone)]`
-   |
-LL + #[derive(Clone)]
-LL | struct S(i32);
-   |
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/parser/bad-lit-suffixes.rs b/tests/ui/parser/bad-lit-suffixes.rs
index 4e8edf4..0a01bb8 100644
--- a/tests/ui/parser/bad-lit-suffixes.rs
+++ b/tests/ui/parser/bad-lit-suffixes.rs
@@ -33,6 +33,7 @@ fn f() {}
 
 #[must_use = "string"suffix]
 //~^ ERROR suffixes on string literals are invalid
+//~| ERROR malformed `must_use` attribute input
 fn g() {}
 
 #[link(name = "string"suffix)]
@@ -41,4 +42,5 @@ fn g() {}
 
 #[rustc_layout_scalar_valid_range_start(0suffix)]
 //~^ ERROR invalid suffix `suffix` for number literal
+//~| ERROR malformed `rustc_layout_scalar_valid_range_start` attribute input
 struct S;
diff --git a/tests/ui/parser/bad-lit-suffixes.stderr b/tests/ui/parser/bad-lit-suffixes.stderr
index 416143e..7876d75 100644
--- a/tests/ui/parser/bad-lit-suffixes.stderr
+++ b/tests/ui/parser/bad-lit-suffixes.stderr
@@ -23,13 +23,13 @@
    |              ^^^^^^^^^^^^^^ invalid suffix `suffix`
 
 error: suffixes on string literals are invalid
-  --> $DIR/bad-lit-suffixes.rs:38:15
+  --> $DIR/bad-lit-suffixes.rs:39:15
    |
 LL | #[link(name = "string"suffix)]
    |               ^^^^^^^^^^^^^^ invalid suffix `suffix`
 
 error: invalid suffix `suffix` for number literal
-  --> $DIR/bad-lit-suffixes.rs:42:41
+  --> $DIR/bad-lit-suffixes.rs:43:41
    |
 LL | #[rustc_layout_scalar_valid_range_start(0suffix)]
    |                                         ^^^^^^^ invalid suffix `suffix`
@@ -150,5 +150,33 @@
    |
    = help: valid suffixes are `f32` and `f64`
 
-error: aborting due to 20 previous errors; 2 warnings emitted
+error[E0539]: malformed `must_use` attribute input
+  --> $DIR/bad-lit-suffixes.rs:34:1
+   |
+LL | #[must_use = "string"suffix]
+   | ^^^^^^^^^^^^^--------------^
+   |              |
+   |              expected a string literal here
+   |
+help: try changing it to one of the following valid forms of the attribute
+   |
+LL - #[must_use = "string"suffix]
+LL + #[must_use = "reason"]
+   |
+LL - #[must_use = "string"suffix]
+LL + #[must_use]
+   |
 
+error[E0805]: malformed `rustc_layout_scalar_valid_range_start` attribute input
+  --> $DIR/bad-lit-suffixes.rs:43:1
+   |
+LL | #[rustc_layout_scalar_valid_range_start(0suffix)]
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^---------^
+   | |                                      |
+   | |                                      expected a single argument here
+   | help: must be of the form: `#[rustc_layout_scalar_valid_range_start(start)]`
+
+error: aborting due to 22 previous errors; 2 warnings emitted
+
+Some errors have detailed explanations: E0539, E0805.
+For more information about an error, try `rustc --explain E0539`.
diff --git a/tests/ui/parser/multiline-comments-basic.rs b/tests/ui/parser/multiline-comments-basic.rs
new file mode 100644
index 0000000..1aa2a53
--- /dev/null
+++ b/tests/ui/parser/multiline-comments-basic.rs
@@ -0,0 +1,10 @@
+//! Test that basic multiline comments are parsed correctly.
+//!
+//! Feature implementation test for <https://github.com/rust-lang/rust/issues/66>.
+
+//@ run-pass
+
+/*
+ * This is a multi-line comment.
+ */
+pub fn main() {}
diff --git a/tests/ui/parser/trait-object-delimiters.rs b/tests/ui/parser/trait-object-delimiters.rs
index 1cbd2ff..2c75840 100644
--- a/tests/ui/parser/trait-object-delimiters.rs
+++ b/tests/ui/parser/trait-object-delimiters.rs
@@ -8,7 +8,7 @@ fn foo2(_: &dyn (Drop + AsRef<str>)) {} //~ ERROR incorrect parentheses around t
 fn foo2_no_space(_: &dyn(Drop + AsRef<str>)) {} //~ ERROR incorrect parentheses around trait bounds
 
 fn foo3(_: &dyn {Drop + AsRef<str>}) {} //~ ERROR expected parameter name, found `{`
-//~^ ERROR expected one of `!`, `(`, `)`, `*`, `,`, `?`, `[`, `async`, `const`, `for`, `use`, `~`, lifetime, or path, found `{`
+//~^ ERROR expected one of `!`, `(`, `)`, `,`, `?`, `[`, `async`, `const`, `for`, `use`, `~`, lifetime, or path, found `{`
 //~| ERROR at least one trait is required for an object type
 
 fn foo4(_: &dyn <Drop + AsRef<str>>) {} //~ ERROR expected identifier, found `<`
diff --git a/tests/ui/parser/trait-object-delimiters.stderr b/tests/ui/parser/trait-object-delimiters.stderr
index 16d5392..a2c9161 100644
--- a/tests/ui/parser/trait-object-delimiters.stderr
+++ b/tests/ui/parser/trait-object-delimiters.stderr
@@ -39,11 +39,11 @@
 LL | fn foo3(_: &dyn {Drop + AsRef<str>}) {}
    |                 ^ expected parameter name
 
-error: expected one of `!`, `(`, `)`, `*`, `,`, `?`, `[`, `async`, `const`, `for`, `use`, `~`, lifetime, or path, found `{`
+error: expected one of `!`, `(`, `)`, `,`, `?`, `[`, `async`, `const`, `for`, `use`, `~`, lifetime, or path, found `{`
   --> $DIR/trait-object-delimiters.rs:10:17
    |
 LL | fn foo3(_: &dyn {Drop + AsRef<str>}) {}
-   |                -^ expected one of 14 possible tokens
+   |                -^ expected one of 13 possible tokens
    |                |
    |                help: missing `,`
 
diff --git a/tests/ui/parser/unicode-escape-sequences.rs b/tests/ui/parser/unicode-escape-sequences.rs
new file mode 100644
index 0000000..8b08486
--- /dev/null
+++ b/tests/ui/parser/unicode-escape-sequences.rs
@@ -0,0 +1,20 @@
+//! Test ES6-style Unicode escape sequences in string literals.
+//!
+//! Regression test for RFC 446 implementation.
+//! See <https://github.com/rust-lang/rust/pull/19480>.
+
+//@ run-pass
+
+pub fn main() {
+    // Basic Unicode escape - snowman character
+    let s = "\u{2603}";
+    assert_eq!(s, "☃");
+
+    let s = "\u{2a10}\u{2A01}\u{2Aa0}";
+    assert_eq!(s, "⨐⨁⪠");
+
+    let s = "\\{20}";
+    let mut correct_s = String::from("\\");
+    correct_s.push_str("{20}");
+    assert_eq!(s, correct_s);
+}
diff --git a/tests/ui/parser/unicode-multibyte-chars-no-ice.rs b/tests/ui/parser/unicode-multibyte-chars-no-ice.rs
new file mode 100644
index 0000000..b1bb0c6
--- /dev/null
+++ b/tests/ui/parser/unicode-multibyte-chars-no-ice.rs
@@ -0,0 +1,9 @@
+//! Test that multibyte Unicode characters don't crash the compiler.
+//!
+//! Regression test for <https://github.com/rust-lang/rust/issues/4780>.
+
+//@ run-pass
+
+pub fn main() {
+    println!("마이너스 사인이 없으면");
+}
diff --git a/tests/ui/regions/lifetime-not-long-enough-suggestion-regression-test-124563.stderr b/tests/ui/regions/lifetime-not-long-enough-suggestion-regression-test-124563.stderr
index 9f13150..e940745 100644
--- a/tests/ui/regions/lifetime-not-long-enough-suggestion-regression-test-124563.stderr
+++ b/tests/ui/regions/lifetime-not-long-enough-suggestion-regression-test-124563.stderr
@@ -1,8 +1,8 @@
 error[E0478]: lifetime bound not satisfied
-  --> $DIR/lifetime-not-long-enough-suggestion-regression-test-124563.rs:19:16
+  --> $DIR/lifetime-not-long-enough-suggestion-regression-test-124563.rs:19:5
    |
 LL |     type Bar = BarImpl<'a, 'b, T>;
-   |                ^^^^^^^^^^^^^^^^^^
+   |     ^^^^^^^^
    |
 note: lifetime parameter instantiated with the lifetime `'a` as defined here
   --> $DIR/lifetime-not-long-enough-suggestion-regression-test-124563.rs:14:6
diff --git a/tests/ui/regions/region-bounds-on-objects-and-type-parameters.stderr b/tests/ui/regions/region-bounds-on-objects-and-type-parameters.stderr
index b15d2af..e2a5027 100644
--- a/tests/ui/regions/region-bounds-on-objects-and-type-parameters.stderr
+++ b/tests/ui/regions/region-bounds-on-objects-and-type-parameters.stderr
@@ -4,6 +4,14 @@
 LL |     z: Box<dyn Is<'a>+'b+'c>,
    |                          ^^
 
+error[E0392]: lifetime parameter `'c` is never used
+  --> $DIR/region-bounds-on-objects-and-type-parameters.rs:11:18
+   |
+LL | struct Foo<'a,'b,'c> {
+   |                  ^^ unused lifetime parameter
+   |
+   = help: consider removing `'c`, referring to it in a field, or using a marker such as `PhantomData`
+
 error[E0478]: lifetime bound not satisfied
   --> $DIR/region-bounds-on-objects-and-type-parameters.rs:21:8
    |
@@ -21,14 +29,6 @@
 LL | struct Foo<'a,'b,'c> {
    |            ^^
 
-error[E0392]: lifetime parameter `'c` is never used
-  --> $DIR/region-bounds-on-objects-and-type-parameters.rs:11:18
-   |
-LL | struct Foo<'a,'b,'c> {
-   |                  ^^ unused lifetime parameter
-   |
-   = help: consider removing `'c`, referring to it in a field, or using a marker such as `PhantomData`
-
 error: aborting due to 3 previous errors
 
 Some errors have detailed explanations: E0226, E0392, E0478.
diff --git a/tests/ui/regions/regions-normalize-in-where-clause-list.rs b/tests/ui/regions/regions-normalize-in-where-clause-list.rs
index 389f82e..9b046e6 100644
--- a/tests/ui/regions/regions-normalize-in-where-clause-list.rs
+++ b/tests/ui/regions/regions-normalize-in-where-clause-list.rs
@@ -22,9 +22,9 @@ fn foo<'a: 'b, 'b>()
 
 // Here we get an error: we need `'a: 'b`.
 fn bar<'a, 'b>()
-//~^ ERROR cannot infer
 where
     <() as Project<'a, 'b>>::Item: Eq,
+    //~^ ERROR cannot infer
 {
 }
 
diff --git a/tests/ui/regions/regions-normalize-in-where-clause-list.stderr b/tests/ui/regions/regions-normalize-in-where-clause-list.stderr
index ca9ceee..9a5c9ae 100644
--- a/tests/ui/regions/regions-normalize-in-where-clause-list.stderr
+++ b/tests/ui/regions/regions-normalize-in-where-clause-list.stderr
@@ -1,8 +1,8 @@
 error[E0803]: cannot infer an appropriate lifetime for lifetime parameter `'a` due to conflicting requirements
-  --> $DIR/regions-normalize-in-where-clause-list.rs:24:4
+  --> $DIR/regions-normalize-in-where-clause-list.rs:26:36
    |
-LL | fn bar<'a, 'b>()
-   |    ^^^
+LL |     <() as Project<'a, 'b>>::Item: Eq,
+   |                                    ^^
    |
 note: first, the lifetime cannot outlive the lifetime `'a` as defined here...
   --> $DIR/regions-normalize-in-where-clause-list.rs:24:8
@@ -15,10 +15,10 @@
 LL | fn bar<'a, 'b>()
    |            ^^
 note: ...so that the types are compatible
-  --> $DIR/regions-normalize-in-where-clause-list.rs:24:4
+  --> $DIR/regions-normalize-in-where-clause-list.rs:26:36
    |
-LL | fn bar<'a, 'b>()
-   |    ^^^
+LL |     <() as Project<'a, 'b>>::Item: Eq,
+   |                                    ^^
    = note: expected `Project<'a, 'b>`
               found `Project<'_, '_>`
 
diff --git a/tests/ui/resolve/resolve-conflict-extern-crate-vs-extern-crate.stderr b/tests/ui/resolve/resolve-conflict-extern-crate-vs-extern-crate.stderr
index a9b45a1..f53e9e3 100644
--- a/tests/ui/resolve/resolve-conflict-extern-crate-vs-extern-crate.stderr
+++ b/tests/ui/resolve/resolve-conflict-extern-crate-vs-extern-crate.stderr
@@ -2,6 +2,7 @@
    |
    = note: `std` must be defined only once in the type namespace of this module
 help: you can use `as` to change the binding name of the import
+  --> $DIR/resolve-conflict-extern-crate-vs-extern-crate.rs:1:17
    |
 LL | extern crate std as other_std;
    |                  ++++++++++++
diff --git a/tests/ui/max-min-classes.rs b/tests/ui/resolve/struct-function-same-name.rs
similarity index 83%
rename from tests/ui/max-min-classes.rs
rename to tests/ui/resolve/struct-function-same-name.rs
index 338a315..bb2837d 100644
--- a/tests/ui/max-min-classes.rs
+++ b/tests/ui/resolve/struct-function-same-name.rs
@@ -1,3 +1,5 @@
+//! Test that a struct and function can have the same name
+//!
 //@ run-pass
 
 #![allow(non_snake_case)]
@@ -23,7 +25,7 @@ fn product(&self) -> isize {
 }
 
 fn Foo(x: isize, y: isize) -> Foo {
-    Foo { x: x, y: y }
+    Foo { x, y }
 }
 
 pub fn main() {
diff --git a/tests/ui/resolve/type-param-local-var-shadowing.rs b/tests/ui/resolve/type-param-local-var-shadowing.rs
new file mode 100644
index 0000000..e08379e
--- /dev/null
+++ b/tests/ui/resolve/type-param-local-var-shadowing.rs
@@ -0,0 +1,24 @@
+//! Test that items in subscopes correctly shadow type parameters and local variables
+//!
+//! Regression test for https://github.com/rust-lang/rust/issues/23880
+
+//@ run-pass
+
+#![allow(unused)]
+struct Foo<X> {
+    x: Box<X>,
+}
+impl<Bar> Foo<Bar> {
+    fn foo(&self) {
+        type Bar = i32;
+        let _: Bar = 42;
+    }
+}
+
+fn main() {
+    let f = 1;
+    {
+        fn f() {}
+        f();
+    }
+}
diff --git a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.stderr b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.stderr
index 591585c..01a3f52 100644
--- a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.stderr
+++ b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.stderr
@@ -1,8 +1,8 @@
 error[E0491]: in type `&'a Foo<'b>`, reference has a longer lifetime than the data it references
-  --> $DIR/regions-outlives-nominal-type-region-rev.rs:17:20
+  --> $DIR/regions-outlives-nominal-type-region-rev.rs:17:9
    |
 LL |         type Out = &'a Foo<'b>;
-   |                    ^^^^^^^^^^^
+   |         ^^^^^^^^
    |
 note: the pointer is valid for the lifetime `'a` as defined here
   --> $DIR/regions-outlives-nominal-type-region-rev.rs:16:10
diff --git a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.stderr b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.stderr
index 0404b52..ff4c5f0 100644
--- a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.stderr
+++ b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.stderr
@@ -1,8 +1,8 @@
 error[E0491]: in type `&'a Foo<'b>`, reference has a longer lifetime than the data it references
-  --> $DIR/regions-outlives-nominal-type-region.rs:17:20
+  --> $DIR/regions-outlives-nominal-type-region.rs:17:9
    |
 LL |         type Out = &'a Foo<'b>;
-   |                    ^^^^^^^^^^^
+   |         ^^^^^^^^
    |
 note: the pointer is valid for the lifetime `'a` as defined here
   --> $DIR/regions-outlives-nominal-type-region.rs:16:10
diff --git a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.stderr b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.stderr
index 62415e25..a0ede2a 100644
--- a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.stderr
+++ b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.stderr
@@ -1,8 +1,8 @@
 error[E0491]: in type `&'a Foo<&'b i32>`, reference has a longer lifetime than the data it references
-  --> $DIR/regions-outlives-nominal-type-type-rev.rs:17:20
+  --> $DIR/regions-outlives-nominal-type-type-rev.rs:17:9
    |
 LL |         type Out = &'a Foo<&'b i32>;
-   |                    ^^^^^^^^^^^^^^^^
+   |         ^^^^^^^^
    |
 note: the pointer is valid for the lifetime `'a` as defined here
   --> $DIR/regions-outlives-nominal-type-type-rev.rs:16:10
diff --git a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.stderr b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.stderr
index 464d796..23d3f4a 100644
--- a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.stderr
+++ b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.stderr
@@ -1,8 +1,8 @@
 error[E0491]: in type `&'a Foo<&'b i32>`, reference has a longer lifetime than the data it references
-  --> $DIR/regions-outlives-nominal-type-type.rs:17:20
+  --> $DIR/regions-outlives-nominal-type-type.rs:17:9
    |
 LL |         type Out = &'a Foo<&'b i32>;
-   |                    ^^^^^^^^^^^^^^^^
+   |         ^^^^^^^^
    |
 note: the pointer is valid for the lifetime `'a` as defined here
   --> $DIR/regions-outlives-nominal-type-type.rs:16:10
diff --git a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-struct-not-wf.stderr b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-struct-not-wf.stderr
index eb17ce7..73c0bbc 100644
--- a/tests/ui/rfcs/rfc-2093-infer-outlives/regions-struct-not-wf.stderr
+++ b/tests/ui/rfcs/rfc-2093-infer-outlives/regions-struct-not-wf.stderr
@@ -1,10 +1,10 @@
 error[E0309]: the parameter type `T` may not live long enough
-  --> $DIR/regions-struct-not-wf.rs:13:16
+  --> $DIR/regions-struct-not-wf.rs:13:5
    |
 LL | impl<'a, T> Trait<'a, T> for usize {
    |      -- the parameter type `T` must be valid for the lifetime `'a` as defined here...
 LL |     type Out = &'a T;
-   |                ^^^^^ ...so that the reference type `&'a T` does not outlive the data it points at
+   |     ^^^^^^^^ ...so that the reference type `&'a T` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |
@@ -12,12 +12,12 @@
    |           ++++
 
 error[E0309]: the parameter type `T` may not live long enough
-  --> $DIR/regions-struct-not-wf.rs:21:16
+  --> $DIR/regions-struct-not-wf.rs:21:5
    |
 LL | impl<'a, T> Trait<'a, T> for u32 {
    |      -- the parameter type `T` must be valid for the lifetime `'a` as defined here...
 LL |     type Out = RefOk<'a, T>;
-   |                ^^^^^^^^^^^^ ...so that the type `T` will meet its required lifetime bounds...
+   |     ^^^^^^^^ ...so that the type `T` will meet its required lifetime bounds...
    |
 note: ...that is required by this bound
   --> $DIR/regions-struct-not-wf.rs:16:20
@@ -30,10 +30,10 @@
    |           ++++
 
 error[E0491]: in type `&'a &'b T`, reference has a longer lifetime than the data it references
-  --> $DIR/regions-struct-not-wf.rs:25:16
+  --> $DIR/regions-struct-not-wf.rs:25:5
    |
 LL |     type Out = &'a &'b T;
-   |                ^^^^^^^^^
+   |     ^^^^^^^^
    |
 note: the pointer is valid for the lifetime `'a` as defined here
   --> $DIR/regions-struct-not-wf.rs:24:6
diff --git a/tests/ui/self/self-infer.rs b/tests/ui/self/self-infer.rs
index 9839b88..d6f6d8b 100644
--- a/tests/ui/self/self-infer.rs
+++ b/tests/ui/self/self-infer.rs
@@ -1,8 +1,8 @@
 struct S;
 
 impl S {
-    fn f(self: _) {} //~ERROR the placeholder `_` is not allowed within types on item signatures for functions
-    fn g(self: &_) {} //~ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    fn f(self: _) {} //~ERROR the placeholder `_` is not allowed within types on item signatures for methods
+    fn g(self: &_) {} //~ERROR the placeholder `_` is not allowed within types on item signatures for methods
 }
 
 fn main() {}
diff --git a/tests/ui/self/self-infer.stderr b/tests/ui/self/self-infer.stderr
index f9db559..13d803d 100644
--- a/tests/ui/self/self-infer.stderr
+++ b/tests/ui/self/self-infer.stderr
@@ -1,10 +1,10 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/self-infer.rs:4:16
    |
 LL |     fn f(self: _) {}
    |                ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/self-infer.rs:5:17
    |
 LL |     fn g(self: &_) {}
diff --git a/tests/ui/simd/array-trait.stderr b/tests/ui/simd/array-trait.stderr
index 299f0ad..47f3950 100644
--- a/tests/ui/simd/array-trait.stderr
+++ b/tests/ui/simd/array-trait.stderr
@@ -1,3 +1,9 @@
+error[E0077]: SIMD vector element type should be a primitive scalar (integer/float/pointer) type
+  --> $DIR/array-trait.rs:22:1
+   |
+LL | pub struct T<S: Simd>([S::Lane; S::SIZE]);
+   | ^^^^^^^^^^^^^^^^^^^^^
+
 error: unconstrained generic constant
   --> $DIR/array-trait.rs:22:23
    |
@@ -9,12 +15,6 @@
 LL | pub struct T<S: Simd>([S::Lane; S::SIZE]) where [(); S::SIZE]:;
    |                                           ++++++++++++++++++++
 
-error[E0077]: SIMD vector element type should be a primitive scalar (integer/float/pointer) type
-  --> $DIR/array-trait.rs:22:1
-   |
-LL | pub struct T<S: Simd>([S::Lane; S::SIZE]);
-   | ^^^^^^^^^^^^^^^^^^^^^
-
 error: unconstrained generic constant
   --> $DIR/array-trait.rs:22:23
    |
diff --git a/tests/ui/sized-hierarchy/impls.rs b/tests/ui/sized-hierarchy/impls.rs
index 46697e4..643f7bc 100644
--- a/tests/ui/sized-hierarchy/impls.rs
+++ b/tests/ui/sized-hierarchy/impls.rs
@@ -3,7 +3,7 @@
 
 #![allow(incomplete_features, internal_features)]
 #![feature(sized_hierarchy)]
-#![feature(coroutines, dyn_star, extern_types, f16, never_type, unsized_fn_params)]
+#![feature(coroutines, extern_types, f16, never_type, unsized_fn_params)]
 
 use std::fmt::Debug;
 use std::marker::{MetaSized, PointeeSized};
@@ -151,11 +151,6 @@ fn foo(x: u8) -> u8 { x }
     needs_metasized::<!>();
     needs_pointeesized::<!>();
 
-    // `dyn*`
-    needs_sized::<dyn* Debug>();
-    needs_metasized::<dyn* Debug>();
-    needs_pointeesized::<dyn* Debug>();
-
     // `str`
     needs_sized::<str>();
     //~^ ERROR the size for values of type `str` cannot be known at compilation time
diff --git a/tests/ui/sized-hierarchy/impls.stderr b/tests/ui/sized-hierarchy/impls.stderr
index eebe4e0d..ca70822 100644
--- a/tests/ui/sized-hierarchy/impls.stderr
+++ b/tests/ui/sized-hierarchy/impls.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:240:42
+  --> $DIR/impls.rs:235:42
    |
 LL |     struct StructAllFieldsMetaSized { x: [u8], y: [u8] }
    |                                          ^^^^ doesn't have a size known at compile-time
@@ -17,7 +17,7 @@
    |                                          ++++    +
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:248:40
+  --> $DIR/impls.rs:243:40
    |
 LL |     struct StructAllFieldsUnsized { x: Foo, y: Foo }
    |                                        ^^^ doesn't have a size known at compile-time
@@ -35,7 +35,7 @@
    |                                        ++++   +
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:284:44
+  --> $DIR/impls.rs:279:44
    |
 LL |     enum EnumAllFieldsMetaSized { Qux { x: [u8], y: [u8] } }
    |                                            ^^^^ doesn't have a size known at compile-time
@@ -53,7 +53,7 @@
    |                                            ++++    +
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:291:42
+  --> $DIR/impls.rs:286:42
    |
 LL |     enum EnumAllFieldsUnsized { Qux { x: Foo, y: Foo } }
    |                                          ^^^ doesn't have a size known at compile-time
@@ -71,7 +71,7 @@
    |                                          ++++   +
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:298:52
+  --> $DIR/impls.rs:293:52
    |
 LL |     enum EnumLastFieldMetaSized { Qux { x: u32, y: [u8] } }
    |                                                    ^^^^ doesn't have a size known at compile-time
@@ -89,7 +89,7 @@
    |                                                    ++++    +
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:305:50
+  --> $DIR/impls.rs:300:50
    |
 LL |     enum EnumLastFieldUnsized { Qux { x: u32, y: Foo } }
    |                                                  ^^^ doesn't have a size known at compile-time
@@ -107,7 +107,7 @@
    |                                                  ++++   +
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/impls.rs:160:19
+  --> $DIR/impls.rs:155:19
    |
 LL |     needs_sized::<str>();
    |                   ^^^ doesn't have a size known at compile-time
@@ -120,7 +120,7 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:166:19
+  --> $DIR/impls.rs:161:19
    |
 LL |     needs_sized::<[u8]>();
    |                   ^^^^ doesn't have a size known at compile-time
@@ -133,7 +133,7 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `dyn Debug` cannot be known at compilation time
-  --> $DIR/impls.rs:172:19
+  --> $DIR/impls.rs:167:19
    |
 LL |     needs_sized::<dyn Debug>();
    |                   ^^^^^^^^^ doesn't have a size known at compile-time
@@ -146,7 +146,7 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:181:19
+  --> $DIR/impls.rs:176:19
    |
 LL |     needs_sized::<Foo>();
    |                   ^^^ doesn't have a size known at compile-time
@@ -159,7 +159,7 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known
-  --> $DIR/impls.rs:183:23
+  --> $DIR/impls.rs:178:23
    |
 LL |     needs_metasized::<Foo>();
    |                       ^^^ doesn't have a known size
@@ -172,7 +172,7 @@
    |                       ^^^^^^^^^ required by this bound in `needs_metasized`
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:198:19
+  --> $DIR/impls.rs:193:19
    |
 LL |     needs_sized::<([u8], [u8])>();
    |                   ^^^^^^^^^^^^ doesn't have a size known at compile-time
@@ -181,7 +181,7 @@
    = note: only the last element of a tuple may have a dynamically sized type
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:200:23
+  --> $DIR/impls.rs:195:23
    |
 LL |     needs_metasized::<([u8], [u8])>();
    |                       ^^^^^^^^^^^^ doesn't have a size known at compile-time
@@ -190,7 +190,7 @@
    = note: only the last element of a tuple may have a dynamically sized type
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:202:26
+  --> $DIR/impls.rs:197:26
    |
 LL |     needs_pointeesized::<([u8], [u8])>();
    |                          ^^^^^^^^^^^^ doesn't have a size known at compile-time
@@ -199,7 +199,7 @@
    = note: only the last element of a tuple may have a dynamically sized type
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:206:19
+  --> $DIR/impls.rs:201:19
    |
 LL |     needs_sized::<(Foo, Foo)>();
    |                   ^^^^^^^^^^ doesn't have a size known at compile-time
@@ -208,7 +208,7 @@
    = note: only the last element of a tuple may have a dynamically sized type
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:208:23
+  --> $DIR/impls.rs:203:23
    |
 LL |     needs_metasized::<(Foo, Foo)>();
    |                       ^^^^^^^^^^ doesn't have a size known at compile-time
@@ -217,7 +217,7 @@
    = note: only the last element of a tuple may have a dynamically sized type
 
 error[E0277]: the size for values of type `main::Foo` cannot be known
-  --> $DIR/impls.rs:208:23
+  --> $DIR/impls.rs:203:23
    |
 LL |     needs_metasized::<(Foo, Foo)>();
    |                       ^^^^^^^^^^ doesn't have a known size
@@ -231,7 +231,7 @@
    |                       ^^^^^^^^^ required by this bound in `needs_metasized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:211:26
+  --> $DIR/impls.rs:206:26
    |
 LL |     needs_pointeesized::<(Foo, Foo)>();
    |                          ^^^^^^^^^^ doesn't have a size known at compile-time
@@ -240,7 +240,7 @@
    = note: only the last element of a tuple may have a dynamically sized type
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:215:19
+  --> $DIR/impls.rs:210:19
    |
 LL |     needs_sized::<(u32, [u8])>();
    |                   ^^^^^^^^^^^ doesn't have a size known at compile-time
@@ -254,7 +254,7 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:221:19
+  --> $DIR/impls.rs:216:19
    |
 LL |     needs_sized::<(u32, Foo)>();
    |                   ^^^^^^^^^^ doesn't have a size known at compile-time
@@ -268,7 +268,7 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known
-  --> $DIR/impls.rs:223:23
+  --> $DIR/impls.rs:218:23
    |
 LL |     needs_metasized::<(u32, Foo)>();
    |                       ^^^^^^^^^^ doesn't have a known size
@@ -282,14 +282,14 @@
    |                       ^^^^^^^^^ required by this bound in `needs_metasized`
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:242:19
+  --> $DIR/impls.rs:237:19
    |
 LL |     needs_sized::<StructAllFieldsMetaSized>();
    |                   ^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `StructAllFieldsMetaSized`, the trait `Sized` is not implemented for `[u8]`
 note: required because it appears within the type `StructAllFieldsMetaSized`
-  --> $DIR/impls.rs:240:12
+  --> $DIR/impls.rs:235:12
    |
 LL |     struct StructAllFieldsMetaSized { x: [u8], y: [u8] }
    |            ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -300,14 +300,14 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:250:19
+  --> $DIR/impls.rs:245:19
    |
 LL |     needs_sized::<StructAllFieldsUnsized>();
    |                   ^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `StructAllFieldsUnsized`, the trait `Sized` is not implemented for `main::Foo`
 note: required because it appears within the type `StructAllFieldsUnsized`
-  --> $DIR/impls.rs:248:12
+  --> $DIR/impls.rs:243:12
    |
 LL |     struct StructAllFieldsUnsized { x: Foo, y: Foo }
    |            ^^^^^^^^^^^^^^^^^^^^^^
@@ -318,14 +318,14 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known
-  --> $DIR/impls.rs:252:23
+  --> $DIR/impls.rs:247:23
    |
 LL |     needs_metasized::<StructAllFieldsUnsized>();
    |                       ^^^^^^^^^^^^^^^^^^^^^^ doesn't have a known size
    |
    = help: within `StructAllFieldsUnsized`, the trait `MetaSized` is not implemented for `main::Foo`
 note: required because it appears within the type `StructAllFieldsUnsized`
-  --> $DIR/impls.rs:248:12
+  --> $DIR/impls.rs:243:12
    |
 LL |     struct StructAllFieldsUnsized { x: Foo, y: Foo }
    |            ^^^^^^^^^^^^^^^^^^^^^^
@@ -336,14 +336,14 @@
    |                       ^^^^^^^^^ required by this bound in `needs_metasized`
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/impls.rs:258:19
+  --> $DIR/impls.rs:253:19
    |
 LL |     needs_sized::<StructLastFieldMetaSized>();
    |                   ^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `StructLastFieldMetaSized`, the trait `Sized` is not implemented for `[u8]`
 note: required because it appears within the type `StructLastFieldMetaSized`
-  --> $DIR/impls.rs:257:12
+  --> $DIR/impls.rs:252:12
    |
 LL |     struct StructLastFieldMetaSized { x: u32, y: [u8] }
    |            ^^^^^^^^^^^^^^^^^^^^^^^^
@@ -354,14 +354,14 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known at compilation time
-  --> $DIR/impls.rs:265:19
+  --> $DIR/impls.rs:260:19
    |
 LL |     needs_sized::<StructLastFieldUnsized>();
    |                   ^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `StructLastFieldUnsized`, the trait `Sized` is not implemented for `main::Foo`
 note: required because it appears within the type `StructLastFieldUnsized`
-  --> $DIR/impls.rs:264:12
+  --> $DIR/impls.rs:259:12
    |
 LL |     struct StructLastFieldUnsized { x: u32, y: Foo }
    |            ^^^^^^^^^^^^^^^^^^^^^^
@@ -372,14 +372,14 @@
    |                   ^^^^^ required by this bound in `needs_sized`
 
 error[E0277]: the size for values of type `main::Foo` cannot be known
-  --> $DIR/impls.rs:267:23
+  --> $DIR/impls.rs:262:23
    |
 LL |     needs_metasized::<StructLastFieldUnsized>();
    |                       ^^^^^^^^^^^^^^^^^^^^^^ doesn't have a known size
    |
    = help: within `StructLastFieldUnsized`, the trait `MetaSized` is not implemented for `main::Foo`
 note: required because it appears within the type `StructLastFieldUnsized`
-  --> $DIR/impls.rs:264:12
+  --> $DIR/impls.rs:259:12
    |
 LL |     struct StructLastFieldUnsized { x: u32, y: Foo }
    |            ^^^^^^^^^^^^^^^^^^^^^^
diff --git a/tests/ui/specialization/defaultimpl/validation.stderr b/tests/ui/specialization/defaultimpl/validation.stderr
index d034386..82a33bf 100644
--- a/tests/ui/specialization/defaultimpl/validation.stderr
+++ b/tests/ui/specialization/defaultimpl/validation.stderr
@@ -18,14 +18,6 @@
    = help: consider using `min_specialization` instead, which is more stable and complete
    = note: `#[warn(incomplete_features)]` on by default
 
-error: impls of auto traits cannot be default
-  --> $DIR/validation.rs:9:21
-   |
-LL | default unsafe impl Send for S {}
-   | -------             ^^^^ auto trait
-   | |
-   | default because of this
-
 error[E0367]: `!Send` impl requires `Z: Send` but the struct it is implemented for does not
   --> $DIR/validation.rs:12:1
    |
@@ -39,6 +31,14 @@
    | ^^^^^^^^
 
 error: impls of auto traits cannot be default
+  --> $DIR/validation.rs:9:21
+   |
+LL | default unsafe impl Send for S {}
+   | -------             ^^^^ auto trait
+   | |
+   | default because of this
+
+error: impls of auto traits cannot be default
   --> $DIR/validation.rs:12:15
    |
 LL | default impl !Send for Z {}
diff --git a/tests/ui/specialization/issue-51892.stderr b/tests/ui/specialization/issue-51892.stderr
index b1cabc0..f327f10 100644
--- a/tests/ui/specialization/issue-51892.stderr
+++ b/tests/ui/specialization/issue-51892.stderr
@@ -1,8 +1,8 @@
 error: unconstrained generic constant
-  --> $DIR/issue-51892.rs:14:17
+  --> $DIR/issue-51892.rs:14:5
    |
 LL |     type Type = [u8; std::mem::size_of::<<T as Trait>::Type>()];
-   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |     ^^^^^^^^^
    |
 help: try adding a `where` bound
    |
diff --git a/tests/ui/specialization/min_specialization/issue-79224.stderr b/tests/ui/specialization/min_specialization/issue-79224.stderr
index 2ed614f..9b6c931 100644
--- a/tests/ui/specialization/min_specialization/issue-79224.stderr
+++ b/tests/ui/specialization/min_specialization/issue-79224.stderr
@@ -1,8 +1,8 @@
 error[E0277]: the trait bound `B: Clone` is not satisfied
-  --> $DIR/issue-79224.rs:28:29
+  --> $DIR/issue-79224.rs:30:5
    |
-LL | impl<B: ?Sized> Display for Cow<'_, B> {
-   |                             ^^^^^^^^^^ the trait `Clone` is not implemented for `B`
+LL |     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Clone` is not implemented for `B`
    |
    = note: required for `B` to implement `ToOwned`
 help: consider further restricting type parameter `B` with trait `Clone`
@@ -11,10 +11,10 @@
    |                +++++++++++++++++++
 
 error[E0277]: the trait bound `B: Clone` is not satisfied
-  --> $DIR/issue-79224.rs:30:5
+  --> $DIR/issue-79224.rs:28:29
    |
-LL |     fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `Clone` is not implemented for `B`
+LL | impl<B: ?Sized> Display for Cow<'_, B> {
+   |                             ^^^^^^^^^^ the trait `Clone` is not implemented for `B`
    |
    = note: required for `B` to implement `ToOwned`
 help: consider further restricting type parameter `B` with trait `Clone`
diff --git a/tests/ui/static/issue-24446.stderr b/tests/ui/static/issue-24446.stderr
index 0e6e338..6e35db7 100644
--- a/tests/ui/static/issue-24446.stderr
+++ b/tests/ui/static/issue-24446.stderr
@@ -1,17 +1,17 @@
 error[E0277]: `(dyn Fn() -> u32 + 'static)` cannot be shared between threads safely
-  --> $DIR/issue-24446.rs:2:17
+  --> $DIR/issue-24446.rs:2:5
    |
 LL |     static foo: dyn Fn() -> u32 = || -> u32 {
-   |                 ^^^^^^^^^^^^^^^ `(dyn Fn() -> u32 + 'static)` cannot be shared between threads safely
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ `(dyn Fn() -> u32 + 'static)` cannot be shared between threads safely
    |
    = help: the trait `Sync` is not implemented for `(dyn Fn() -> u32 + 'static)`
    = note: shared static variables must have a type that implements `Sync`
 
 error[E0277]: the size for values of type `(dyn Fn() -> u32 + 'static)` cannot be known at compilation time
-  --> $DIR/issue-24446.rs:2:17
+  --> $DIR/issue-24446.rs:2:5
    |
 LL |     static foo: dyn Fn() -> u32 = || -> u32 {
-   |                 ^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: the trait `Sized` is not implemented for `(dyn Fn() -> u32 + 'static)`
    = note: statics and constants must have a statically known size
diff --git a/tests/ui/statics/issue-17718-static-sync.stderr b/tests/ui/statics/issue-17718-static-sync.stderr
index 96f8941..d49dbd9 100644
--- a/tests/ui/statics/issue-17718-static-sync.stderr
+++ b/tests/ui/statics/issue-17718-static-sync.stderr
@@ -1,8 +1,8 @@
 error[E0277]: `Foo` cannot be shared between threads safely
-  --> $DIR/issue-17718-static-sync.rs:9:13
+  --> $DIR/issue-17718-static-sync.rs:9:1
    |
 LL | static BAR: Foo = Foo;
-   |             ^^^ `Foo` cannot be shared between threads safely
+   | ^^^^^^^^^^^^^^^ `Foo` cannot be shared between threads safely
    |
    = help: the trait `Sync` is not implemented for `Foo`
    = note: shared static variables must have a type that implements `Sync`
diff --git a/tests/ui/statics/static-generic-param-soundness.rs b/tests/ui/statics/static-generic-param-soundness.rs
new file mode 100644
index 0000000..aabcca51
--- /dev/null
+++ b/tests/ui/statics/static-generic-param-soundness.rs
@@ -0,0 +1,20 @@
+//! Originally, inner statics in generic functions were generated only once, causing the same
+//! static to be shared across all generic instantiations. This created a soundness hole where
+//! different types could be coerced through thread-local storage in safe code.
+//!
+//! This test checks that generic parameters from outer scopes cannot be used in inner statics,
+//! preventing this soundness issue.
+//!
+//! See https://github.com/rust-lang/rust/issues/9186
+
+enum Bar<T> {
+    //~^ ERROR parameter `T` is never used
+    What,
+}
+
+fn foo<T>() {
+    static a: Bar<T> = Bar::What;
+    //~^ ERROR can't use generic parameters from outer item
+}
+
+fn main() {}
diff --git a/tests/ui/inner-static-type-parameter.stderr b/tests/ui/statics/static-generic-param-soundness.stderr
similarity index 85%
rename from tests/ui/inner-static-type-parameter.stderr
rename to tests/ui/statics/static-generic-param-soundness.stderr
index 88d33b4..47554c7 100644
--- a/tests/ui/inner-static-type-parameter.stderr
+++ b/tests/ui/statics/static-generic-param-soundness.stderr
@@ -1,5 +1,5 @@
 error[E0401]: can't use generic parameters from outer item
-  --> $DIR/inner-static-type-parameter.rs:6:19
+  --> $DIR/static-generic-param-soundness.rs:16:19
    |
 LL | fn foo<T>() {
    |        - type parameter from outer item
@@ -9,9 +9,9 @@
    = note: a `static` is a separate item from the item that contains it
 
 error[E0392]: type parameter `T` is never used
-  --> $DIR/inner-static-type-parameter.rs:3:10
+  --> $DIR/static-generic-param-soundness.rs:10:10
    |
-LL | enum Bar<T> { What }
+LL | enum Bar<T> {
    |          ^ unused type parameter
    |
    = help: consider removing `T`, referring to it in a field, or using a marker such as `PhantomData`
diff --git a/tests/ui/statics/uninhabited-static.stderr b/tests/ui/statics/uninhabited-static.stderr
index f799a82f..a0f9ad6 100644
--- a/tests/ui/statics/uninhabited-static.stderr
+++ b/tests/ui/statics/uninhabited-static.stderr
@@ -1,8 +1,8 @@
 error: static of uninhabited type
-  --> $DIR/uninhabited-static.rs:6:5
+  --> $DIR/uninhabited-static.rs:12:1
    |
-LL |     static VOID: Void;
-   |     ^^^^^^^^^^^^^^^^^
+LL | static VOID2: Void = unsafe { std::mem::transmute(()) };
+   | ^^^^^^^^^^^^^^^^^^
    |
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
    = note: for more information, see issue #74840 <https://github.com/rust-lang/rust/issues/74840>
@@ -14,26 +14,6 @@
    |         ^^^^^^^^^^^^^^^^^^
 
 error: static of uninhabited type
-  --> $DIR/uninhabited-static.rs:8:5
-   |
-LL |     static NEVER: !;
-   |     ^^^^^^^^^^^^^^^
-   |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
-   = note: for more information, see issue #74840 <https://github.com/rust-lang/rust/issues/74840>
-   = note: uninhabited statics cannot be initialized, and any access would be an immediate error
-
-error: static of uninhabited type
-  --> $DIR/uninhabited-static.rs:12:1
-   |
-LL | static VOID2: Void = unsafe { std::mem::transmute(()) };
-   | ^^^^^^^^^^^^^^^^^^
-   |
-   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
-   = note: for more information, see issue #74840 <https://github.com/rust-lang/rust/issues/74840>
-   = note: uninhabited statics cannot be initialized, and any access would be an immediate error
-
-error: static of uninhabited type
   --> $DIR/uninhabited-static.rs:15:1
    |
 LL | static NEVER2: Void = unsafe { std::mem::transmute(()) };
@@ -43,6 +23,26 @@
    = note: for more information, see issue #74840 <https://github.com/rust-lang/rust/issues/74840>
    = note: uninhabited statics cannot be initialized, and any access would be an immediate error
 
+error: static of uninhabited type
+  --> $DIR/uninhabited-static.rs:6:5
+   |
+LL |     static VOID: Void;
+   |     ^^^^^^^^^^^^^^^^^
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #74840 <https://github.com/rust-lang/rust/issues/74840>
+   = note: uninhabited statics cannot be initialized, and any access would be an immediate error
+
+error: static of uninhabited type
+  --> $DIR/uninhabited-static.rs:8:5
+   |
+LL |     static NEVER: !;
+   |     ^^^^^^^^^^^^^^^
+   |
+   = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
+   = note: for more information, see issue #74840 <https://github.com/rust-lang/rust/issues/74840>
+   = note: uninhabited statics cannot be initialized, and any access would be an immediate error
+
 error[E0080]: constructing invalid value: encountered a value of uninhabited type `Void`
   --> $DIR/uninhabited-static.rs:12:31
    |
diff --git a/tests/ui/statics/unsized_type2.stderr b/tests/ui/statics/unsized_type2.stderr
index 3f9b087..293df75 100644
--- a/tests/ui/statics/unsized_type2.stderr
+++ b/tests/ui/statics/unsized_type2.stderr
@@ -1,8 +1,8 @@
 error[E0277]: the size for values of type `str` cannot be known at compilation time
-  --> $DIR/unsized_type2.rs:14:24
+  --> $DIR/unsized_type2.rs:14:1
    |
 LL | pub static WITH_ERROR: Foo = Foo { version: 0 };
-   |                        ^^^ doesn't have a size known at compile-time
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
    |
    = help: within `Foo`, the trait `Sized` is not implemented for `str`
 note: required because it appears within the type `Foo`
diff --git a/tests/ui/statics/unsizing-wfcheck-issue-127299.stderr b/tests/ui/statics/unsizing-wfcheck-issue-127299.stderr
index e401277..8a19207 100644
--- a/tests/ui/statics/unsizing-wfcheck-issue-127299.stderr
+++ b/tests/ui/statics/unsizing-wfcheck-issue-127299.stderr
@@ -22,10 +22,10 @@
    |                     +++++++++++++++++
 
 error[E0277]: `(dyn Qux + 'static)` cannot be shared between threads safely
-  --> $DIR/unsizing-wfcheck-issue-127299.rs:12:13
+  --> $DIR/unsizing-wfcheck-issue-127299.rs:12:1
    |
 LL | static FOO: &Lint = &Lint { desc: "desc" };
-   |             ^^^^^ `(dyn Qux + 'static)` cannot be shared between threads safely
+   | ^^^^^^^^^^^^^^^^^ `(dyn Qux + 'static)` cannot be shared between threads safely
    |
    = help: within `&'static Lint`, the trait `Sync` is not implemented for `(dyn Qux + 'static)`
    = note: required because it appears within the type `&'static (dyn Qux + 'static)`
diff --git a/tests/ui/stats/macro-stats.rs b/tests/ui/stats/macro-stats.rs
index ee265d6..d986904 100644
--- a/tests/ui/stats/macro-stats.rs
+++ b/tests/ui/stats/macro-stats.rs
@@ -49,12 +49,17 @@ fn opt(x: Option<u32>) {
     }
 }
 
-macro_rules! this_is_a_really_really_long_macro_name {
+macro_rules! long_name_that_fits_on_a_single_line {
+    () => {}
+}
+long_name_that_fits_on_a_single_line!();
+
+macro_rules! long_name_that_doesnt_fit_on_one_line {
     ($t:ty) => {
         fn f(_: $t) {}
     }
 }
-this_is_a_really_really_long_macro_name!(u32!()); // AstFragmentKind::{Items,Ty}
+long_name_that_doesnt_fit_on_one_line!(u32!()); // AstFragmentKind::{Items,Ty}
 
 macro_rules! trait_tys {
     () => {
diff --git a/tests/ui/stats/macro-stats.stderr b/tests/ui/stats/macro-stats.stderr
index 00c6b55..8d0fdb8 100644
--- a/tests/ui/stats/macro-stats.stderr
+++ b/tests/ui/stats/macro-stats.stderr
@@ -15,12 +15,13 @@
 macro-stats p!                                    1          3        3.0         32       32.0
 macro-stats trait_impl_tys!                       1          2        2.0         28       28.0
 macro-stats foreign_item!                         1          1        1.0         21       21.0
-macro-stats this_is_a_really_really_long_macro_name!
+macro-stats long_name_that_doesnt_fit_on_one_line!
 macro-stats                                       1          1        1.0         18       18.0
 macro-stats impl_const!                           1          1        1.0         17       17.0
 macro-stats trait_tys!                            1          2        2.0         15       15.0
 macro-stats n99!                                  2          2        1.0          4        2.0
 macro-stats none!                                 1          1        1.0          4        4.0
 macro-stats u32!                                  1          1        1.0          3        3.0
+macro-stats long_name_that_fits_on_a_single_line! 1          1        1.0          0        0.0
 macro-stats #[test]                               1          1        1.0          0        0.0
 macro-stats ===================================================================================
diff --git a/tests/ui/structs/basic-newtype-pattern.rs b/tests/ui/structs/basic-newtype-pattern.rs
new file mode 100644
index 0000000..38ccd0e
--- /dev/null
+++ b/tests/ui/structs/basic-newtype-pattern.rs
@@ -0,0 +1,25 @@
+//! Test basic newtype pattern functionality.
+
+//@ run-pass
+
+#[derive(Copy, Clone)]
+struct Counter(CounterData);
+
+#[derive(Copy, Clone)]
+struct CounterData {
+    compute: fn(Counter) -> isize,
+    val: isize,
+}
+
+fn compute_value(counter: Counter) -> isize {
+    let Counter(data) = counter;
+    data.val + 20
+}
+
+pub fn main() {
+    let my_counter = Counter(CounterData { compute: compute_value, val: 30 });
+
+    // Test destructuring and function pointer call
+    let Counter(data) = my_counter;
+    assert_eq!((data.compute)(my_counter), 50);
+}
diff --git a/tests/ui/suggestions/bad-infer-in-trait-impl.rs b/tests/ui/suggestions/bad-infer-in-trait-impl.rs
index f38b168..db6fc93 100644
--- a/tests/ui/suggestions/bad-infer-in-trait-impl.rs
+++ b/tests/ui/suggestions/bad-infer-in-trait-impl.rs
@@ -4,7 +4,7 @@
 
 impl Foo for () {
     fn bar(s: _) {}
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
     //~| ERROR has 1 parameter but the declaration in trait `Foo::bar` has 0
 }
 
diff --git a/tests/ui/suggestions/bad-infer-in-trait-impl.stderr b/tests/ui/suggestions/bad-infer-in-trait-impl.stderr
index 8b7d67a..5aa4654 100644
--- a/tests/ui/suggestions/bad-infer-in-trait-impl.stderr
+++ b/tests/ui/suggestions/bad-infer-in-trait-impl.stderr
@@ -1,4 +1,4 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/bad-infer-in-trait-impl.rs:6:15
    |
 LL |     fn bar(s: _) {}
diff --git a/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.rs b/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.rs
index 6a273997..2ee6ad9 100644
--- a/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.rs
+++ b/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.rs
@@ -1,5 +1,3 @@
-#![feature(dyn_star)] //~ WARNING the feature `dyn_star` is incomplete
-
 use std::future::Future;
 
 pub fn dyn_func<T>(
@@ -8,12 +6,6 @@ pub fn dyn_func<T>(
     Box::new(executor) //~ ERROR may not live long enough
 }
 
-pub fn dyn_star_func<T>(
-    executor: impl FnOnce(T) -> dyn* Future<Output = ()>,
-) -> Box<dyn FnOnce(T) -> dyn* Future<Output = ()>> {
-    Box::new(executor) //~ ERROR may not live long enough
-}
-
 trait Trait {
     fn method(&self) {}
 }
diff --git a/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.stderr b/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.stderr
index 1fb3e7d..6294361 100644
--- a/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.stderr
+++ b/tests/ui/suggestions/wrap-dyn-in-suggestion-issue-120223.stderr
@@ -1,14 +1,5 @@
-warning: the feature `dyn_star` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:1:12
-   |
-LL | #![feature(dyn_star)]
-   |            ^^^^^^^^
-   |
-   = note: see issue #102425 <https://github.com/rust-lang/rust/issues/102425> for more information
-   = note: `#[warn(incomplete_features)]` on by default
-
 error[E0599]: no method named `method` found for type parameter `T` in the current scope
-  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:24:7
+  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:16:7
    |
 LL | pub fn in_ty_param<T: Fn() -> dyn std::fmt::Debug> (t: T) {
    |                    - method `method` not found for this type parameter
@@ -22,7 +13,7 @@
    |                               +                   +++++++++
 
 error[E0277]: the size for values of type `T` cannot be known at compilation time
-  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:29:21
+  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:21:21
    |
 LL | fn with_sized<T: Fn() -> &'static (dyn std::fmt::Debug) + ?Sized>() {
    |               - this type parameter needs to be `Sized`
@@ -30,7 +21,7 @@
    |                     ^ doesn't have a size known at compile-time
    |
 note: required by an implicit `Sized` bound in `without_sized`
-  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:33:18
+  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:25:18
    |
 LL | fn without_sized<T: Fn() -> &'static dyn std::fmt::Debug>() {}
    |                  ^ required by the implicit `Sized` requirement on this type parameter in `without_sized`
@@ -45,7 +36,7 @@
    |                                      +                   ++++++++++
 
 error[E0310]: the parameter type `impl FnOnce(T) -> dyn Future<Output = ()>` may not live long enough
-  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:8:5
+  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:6:5
    |
 LL |     Box::new(executor)
    |     ^^^^^^^^^^^^^^^^^^
@@ -58,21 +49,7 @@
 LL |     executor: impl FnOnce(T) -> (dyn Future<Output = ()>) + 'static,
    |                                 +                       +++++++++++
 
-error[E0310]: the parameter type `impl FnOnce(T) -> dyn* Future<Output = ()>` may not live long enough
-  --> $DIR/wrap-dyn-in-suggestion-issue-120223.rs:14:5
-   |
-LL |     Box::new(executor)
-   |     ^^^^^^^^^^^^^^^^^^
-   |     |
-   |     the parameter type `impl FnOnce(T) -> dyn* Future<Output = ()>` must be valid for the static lifetime...
-   |     ...so that the type `impl FnOnce(T) -> dyn* Future<Output = ()>` will meet its required lifetime bounds
-   |
-help: consider adding an explicit lifetime bound
-   |
-LL |     executor: impl FnOnce(T) -> (dyn* Future<Output = ()>) + 'static,
-   |                                 +                        +++++++++++
-
-error: aborting due to 4 previous errors; 1 warning emitted
+error: aborting due to 3 previous errors
 
 Some errors have detailed explanations: E0277, E0310, E0599.
 For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/threads-sendsync/rc-is-not-send.rs b/tests/ui/threads-sendsync/rc-is-not-send.rs
new file mode 100644
index 0000000..dd562e9
--- /dev/null
+++ b/tests/ui/threads-sendsync/rc-is-not-send.rs
@@ -0,0 +1,30 @@
+//! Test that `Rc<T>` cannot be sent between threads.
+
+use std::rc::Rc;
+use std::thread;
+
+#[derive(Debug)]
+struct Port<T>(Rc<T>);
+
+#[derive(Debug)]
+struct Foo {
+    _x: Port<()>,
+}
+
+impl Drop for Foo {
+    fn drop(&mut self) {}
+}
+
+fn foo(x: Port<()>) -> Foo {
+    Foo { _x: x }
+}
+
+fn main() {
+    let x = foo(Port(Rc::new(())));
+
+    thread::spawn(move || {
+        //~^ ERROR `Rc<()>` cannot be sent between threads safely
+        let y = x;
+        println!("{:?}", y);
+    });
+}
diff --git a/tests/ui/threads-sendsync/rc-is-not-send.stderr b/tests/ui/threads-sendsync/rc-is-not-send.stderr
new file mode 100644
index 0000000..a06b683
--- /dev/null
+++ b/tests/ui/threads-sendsync/rc-is-not-send.stderr
@@ -0,0 +1,37 @@
+error[E0277]: `Rc<()>` cannot be sent between threads safely
+  --> $DIR/rc-is-not-send.rs:25:19
+   |
+LL |       thread::spawn(move || {
+   |       ------------- ^------
+   |       |             |
+   |  _____|_____________within this `{closure@$DIR/rc-is-not-send.rs:25:19: 25:26}`
+   | |     |
+   | |     required by a bound introduced by this call
+LL | |
+LL | |         let y = x;
+LL | |         println!("{:?}", y);
+LL | |     });
+   | |_____^ `Rc<()>` cannot be sent between threads safely
+   |
+   = help: within `{closure@$DIR/rc-is-not-send.rs:25:19: 25:26}`, the trait `Send` is not implemented for `Rc<()>`
+note: required because it appears within the type `Port<()>`
+  --> $DIR/rc-is-not-send.rs:7:8
+   |
+LL | struct Port<T>(Rc<T>);
+   |        ^^^^
+note: required because it appears within the type `Foo`
+  --> $DIR/rc-is-not-send.rs:10:8
+   |
+LL | struct Foo {
+   |        ^^^
+note: required because it's used within this closure
+  --> $DIR/rc-is-not-send.rs:25:19
+   |
+LL |     thread::spawn(move || {
+   |                   ^^^^^^^
+note: required by a bound in `spawn`
+  --> $SRC_DIR/std/src/thread/mod.rs:LL:COL
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/traits/associated_type_bound/116464-invalid-assoc-type-suggestion-in-trait-impl.stderr b/tests/ui/traits/associated_type_bound/116464-invalid-assoc-type-suggestion-in-trait-impl.stderr
index eedaae4..54c0cf8 100644
--- a/tests/ui/traits/associated_type_bound/116464-invalid-assoc-type-suggestion-in-trait-impl.stderr
+++ b/tests/ui/traits/associated_type_bound/116464-invalid-assoc-type-suggestion-in-trait-impl.stderr
@@ -1,9 +1,3 @@
-error[E0207]: the type parameter `S` is not constrained by the impl trait, self type, or predicates
-  --> $DIR/116464-invalid-assoc-type-suggestion-in-trait-impl.rs:9:9
-   |
-LL | impl<T, S> Trait<T> for i32 {
-   |         ^ unconstrained type parameter
-
 error[E0107]: trait takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/116464-invalid-assoc-type-suggestion-in-trait-impl.rs:15:12
    |
@@ -16,6 +10,12 @@
 LL | pub trait Trait<T> {
    |           ^^^^^ -
 
+error[E0207]: the type parameter `S` is not constrained by the impl trait, self type, or predicates
+  --> $DIR/116464-invalid-assoc-type-suggestion-in-trait-impl.rs:9:9
+   |
+LL | impl<T, S> Trait<T> for i32 {
+   |         ^ unconstrained type parameter
+
 error[E0107]: trait takes 1 generic argument but 2 generic arguments were supplied
   --> $DIR/116464-invalid-assoc-type-suggestion-in-trait-impl.rs:19:12
    |
diff --git a/tests/ui/traits/const-traits/ice-119717-constant-lifetime.stderr b/tests/ui/traits/const-traits/ice-119717-constant-lifetime.stderr
index c6e0c69..a165ef1 100644
--- a/tests/ui/traits/const-traits/ice-119717-constant-lifetime.stderr
+++ b/tests/ui/traits/const-traits/ice-119717-constant-lifetime.stderr
@@ -16,7 +16,7 @@
    = note: implementing a foreign trait is only possible if at least one of the types for which it is implemented is local
    = note: only traits defined in the current crate can be implemented for a type parameter
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/ice-119717-constant-lifetime.rs:9:31
    |
 LL |     fn from_residual(t: T) -> _ {
diff --git a/tests/ui/traits/constrained-type-params-trait-impl.stderr b/tests/ui/traits/constrained-type-params-trait-impl.stderr
index 2175129..e59fad6 100644
--- a/tests/ui/traits/constrained-type-params-trait-impl.stderr
+++ b/tests/ui/traits/constrained-type-params-trait-impl.stderr
@@ -35,6 +35,17 @@
 LL | impl<T, U> Foo<T> for [isize; 1] {
    |         ^ unconstrained type parameter
 
+error[E0119]: conflicting implementations of trait `Bar`
+  --> $DIR/constrained-type-params-trait-impl.rs:48:1
+   |
+LL |   impl<T, U> Bar for T {
+   |   -------------------- first implementation here
+...
+LL | / impl<T, U> Bar for T
+LL | | where
+LL | |     T: Bar<Out = U>,
+   | |____________________^ conflicting implementation
+
 error[E0207]: the type parameter `U` is not constrained by the impl trait, self type, or predicates
   --> $DIR/constrained-type-params-trait-impl.rs:42:9
    |
@@ -59,17 +70,6 @@
 LL | impl<T, U, V> Foo<T> for T
    |            ^ unconstrained type parameter
 
-error[E0119]: conflicting implementations of trait `Bar`
-  --> $DIR/constrained-type-params-trait-impl.rs:48:1
-   |
-LL |   impl<T, U> Bar for T {
-   |   -------------------- first implementation here
-...
-LL | / impl<T, U> Bar for T
-LL | | where
-LL | |     T: Bar<Out = U>,
-   | |____________________^ conflicting implementation
-
 error: aborting due to 9 previous errors
 
 Some errors have detailed explanations: E0119, E0207.
diff --git a/tests/ui/traits/deep-norm-pending.rs b/tests/ui/traits/deep-norm-pending.rs
index f56c3cf..d6c498d 100644
--- a/tests/ui/traits/deep-norm-pending.rs
+++ b/tests/ui/traits/deep-norm-pending.rs
@@ -8,9 +8,10 @@ trait Bar {
 }
 impl<T> Bar for T
 //~^ ERROR the trait bound `T: Foo` is not satisfied
-//~| ERROR the trait bound `T: Foo` is not satisfied
 where
     <T as Foo>::Assoc: Sized,
+    //~^ ERROR the trait bound `T: Foo` is not satisfied
+    //~| ERROR the trait bound `T: Foo` is not satisfied
 {
     fn method() {}
     //~^ ERROR the trait bound `T: Foo` is not satisfied
@@ -18,7 +19,6 @@ fn method() {}
     //~| ERROR the trait bound `T: Foo` is not satisfied
     //~| ERROR the trait bound `T: Foo` is not satisfied
     //~| ERROR the trait bound `T: Foo` is not satisfied
-    //~| ERROR the trait bound `T: Foo` is not satisfied
 }
 
 fn main() {}
diff --git a/tests/ui/traits/deep-norm-pending.stderr b/tests/ui/traits/deep-norm-pending.stderr
index b95b9d7..c1d6120 100644
--- a/tests/ui/traits/deep-norm-pending.stderr
+++ b/tests/ui/traits/deep-norm-pending.stderr
@@ -1,20 +1,8 @@
 error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/deep-norm-pending.rs:15:5
-   |
-LL |     fn method() {}
-   |     ^^^^^^^^^^^ the trait `Foo` is not implemented for `T`
-   |
-help: consider further restricting type parameter `T` with trait `Foo`
-   |
-LL |     <T as Foo>::Assoc: Sized, T: Foo
-   |                               ++++++
-
-error[E0277]: the trait bound `T: Foo` is not satisfied
   --> $DIR/deep-norm-pending.rs:9:1
    |
 LL | / impl<T> Bar for T
 LL | |
-LL | |
 LL | | where
 LL | |     <T as Foo>::Assoc: Sized,
    | |_____________________________^ the trait `Foo` is not implemented for `T`
@@ -25,15 +13,10 @@
    |                               ++++++
 
 error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/deep-norm-pending.rs:9:1
+  --> $DIR/deep-norm-pending.rs:16:5
    |
-LL | / impl<T> Bar for T
-LL | |
-LL | |
-LL | | where
-...  |
-LL | | }
-   | |_^ the trait `Foo` is not implemented for `T`
+LL |     fn method() {}
+   |     ^^^^^^^^^^^ the trait `Foo` is not implemented for `T`
    |
 help: consider further restricting type parameter `T` with trait `Foo`
    |
@@ -41,7 +24,7 @@
    |                               ++++++
 
 error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/deep-norm-pending.rs:15:5
+  --> $DIR/deep-norm-pending.rs:16:5
    |
 LL |     fn method() {}
    |     ^^^^^^^^^^^ the trait `Foo` is not implemented for `T`
@@ -53,7 +36,7 @@
    |                               ++++++
 
 error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/deep-norm-pending.rs:15:5
+  --> $DIR/deep-norm-pending.rs:16:5
    |
 LL |     fn method() {}
    |     ^^^^^^^^^^^ the trait `Foo` is not implemented for `T`
@@ -72,7 +55,7 @@
    |                               ++++++
 
 error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/deep-norm-pending.rs:15:5
+  --> $DIR/deep-norm-pending.rs:16:5
    |
 LL |     fn method() {}
    |     ^^^^^^^^^^^ the trait `Foo` is not implemented for `T`
@@ -103,7 +86,18 @@
    |                               ++++++
 
 error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/deep-norm-pending.rs:15:5
+  --> $DIR/deep-norm-pending.rs:12:24
+   |
+LL |     <T as Foo>::Assoc: Sized,
+   |                        ^^^^^ the trait `Foo` is not implemented for `T`
+   |
+help: consider further restricting type parameter `T` with trait `Foo`
+   |
+LL |     <T as Foo>::Assoc: Sized, T: Foo
+   |                               ++++++
+
+error[E0277]: the trait bound `T: Foo` is not satisfied
+  --> $DIR/deep-norm-pending.rs:16:5
    |
 LL |     fn method() {}
    |     ^^^^^^^^^^^ the trait `Foo` is not implemented for `T`
@@ -115,11 +109,12 @@
    |                               ++++++
 
 error[E0277]: the trait bound `T: Foo` is not satisfied
-  --> $DIR/deep-norm-pending.rs:15:8
+  --> $DIR/deep-norm-pending.rs:12:24
    |
-LL |     fn method() {}
-   |        ^^^^^^ the trait `Foo` is not implemented for `T`
+LL |     <T as Foo>::Assoc: Sized,
+   |                        ^^^^^ the trait `Foo` is not implemented for `T`
    |
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
 help: consider further restricting type parameter `T` with trait `Foo`
    |
 LL |     <T as Foo>::Assoc: Sized, T: Foo
diff --git a/tests/ui/traits/dispatch-from-dyn-invalid-impls.rs b/tests/ui/traits/dispatch-from-dyn-invalid-impls.rs
new file mode 100644
index 0000000..f5f66ca6
--- /dev/null
+++ b/tests/ui/traits/dispatch-from-dyn-invalid-impls.rs
@@ -0,0 +1,71 @@
+//! Test various invalid implementations of DispatchFromDyn trait.
+//!
+//! DispatchFromDyn is a special trait used by the compiler for dyn-compatible dynamic dispatch.
+//! This checks that the compiler correctly rejects invalid implementations:
+//! - Structs with extra non-coercible fields
+//! - Structs with multiple pointer fields
+//! - Structs with no coercible fields
+//! - Structs with repr(C) or other incompatible representations
+//! - Structs with over-aligned fields
+
+#![feature(unsize, dispatch_from_dyn)]
+
+use std::marker::{PhantomData, Unsize};
+use std::ops::DispatchFromDyn;
+
+// Extra field prevents DispatchFromDyn
+struct WrapperWithExtraField<T>(T, i32);
+
+impl<T, U> DispatchFromDyn<WrapperWithExtraField<U>> for WrapperWithExtraField<T>
+//~^ ERROR [E0378]
+where
+    T: DispatchFromDyn<U>
+{
+}
+
+// Multiple pointer fields create ambiguous coercion
+struct MultiplePointers<T: ?Sized> {
+    ptr1: *const T,
+    ptr2: *const T,
+}
+
+impl<T: ?Sized, U: ?Sized> DispatchFromDyn<MultiplePointers<U>> for MultiplePointers<T>
+//~^ ERROR implementing `DispatchFromDyn` does not allow multiple fields to be coerced
+where
+    T: Unsize<U>
+{
+}
+
+// No coercible fields (only PhantomData)
+struct NothingToCoerce<T: ?Sized> {
+    data: PhantomData<T>,
+}
+
+impl<T: ?Sized, U: ?Sized> DispatchFromDyn<NothingToCoerce<T>> for NothingToCoerce<U> {}
+//~^ ERROR implementing `DispatchFromDyn` requires a field to be coerced
+
+// repr(C) is incompatible with DispatchFromDyn
+#[repr(C)]
+struct HasReprC<T: ?Sized>(Box<T>);
+
+impl<T: ?Sized, U: ?Sized> DispatchFromDyn<HasReprC<U>> for HasReprC<T>
+//~^ ERROR [E0378]
+where
+    T: Unsize<U>
+{
+}
+
+// Over-aligned fields are incompatible
+#[repr(align(64))]
+struct OverAlignedZst;
+
+struct OverAligned<T: ?Sized>(Box<T>, OverAlignedZst);
+
+impl<T: ?Sized, U: ?Sized> DispatchFromDyn<OverAligned<U>> for OverAligned<T>
+//~^ ERROR [E0378]
+where
+    T: Unsize<U>
+{
+}
+
+fn main() {}
diff --git a/tests/ui/invalid_dispatch_from_dyn_impls.stderr b/tests/ui/traits/dispatch-from-dyn-invalid-impls.stderr
similarity index 76%
rename from tests/ui/invalid_dispatch_from_dyn_impls.stderr
rename to tests/ui/traits/dispatch-from-dyn-invalid-impls.stderr
index 93ec6bb..676da0c 100644
--- a/tests/ui/invalid_dispatch_from_dyn_impls.stderr
+++ b/tests/ui/traits/dispatch-from-dyn-invalid-impls.stderr
@@ -1,25 +1,25 @@
 error[E0378]: the trait `DispatchFromDyn` may only be implemented for structs containing the field being coerced, ZST fields with 1 byte alignment that don't mention type/const generics, and nothing else
-  --> $DIR/invalid_dispatch_from_dyn_impls.rs:10:1
+  --> $DIR/dispatch-from-dyn-invalid-impls.rs:19:1
    |
 LL | / impl<T, U> DispatchFromDyn<WrapperWithExtraField<U>> for WrapperWithExtraField<T>
 LL | |
 LL | | where
-LL | |     T: DispatchFromDyn<U>,
-   | |__________________________^
+LL | |     T: DispatchFromDyn<U>
+   | |_________________________^
    |
    = note: extra field `1` of type `i32` is not allowed
 
 error[E0375]: implementing `DispatchFromDyn` does not allow multiple fields to be coerced
-  --> $DIR/invalid_dispatch_from_dyn_impls.rs:22:1
+  --> $DIR/dispatch-from-dyn-invalid-impls.rs:32:1
    |
 LL | / impl<T: ?Sized, U: ?Sized> DispatchFromDyn<MultiplePointers<U>> for MultiplePointers<T>
 LL | |
 LL | | where
-LL | |     T: Unsize<U>,
-   | |_________________^
+LL | |     T: Unsize<U>
+   | |________________^
    |
 note: the trait `DispatchFromDyn` may only be implemented when a single field is being coerced
-  --> $DIR/invalid_dispatch_from_dyn_impls.rs:18:5
+  --> $DIR/dispatch-from-dyn-invalid-impls.rs:28:5
    |
 LL |     ptr1: *const T,
    |     ^^^^^^^^^^^^^^
@@ -27,7 +27,7 @@
    |     ^^^^^^^^^^^^^^
 
 error[E0374]: implementing `DispatchFromDyn` requires a field to be coerced
-  --> $DIR/invalid_dispatch_from_dyn_impls.rs:33:1
+  --> $DIR/dispatch-from-dyn-invalid-impls.rs:44:1
    |
 LL | impl<T: ?Sized, U: ?Sized> DispatchFromDyn<NothingToCoerce<T>> for NothingToCoerce<U> {}
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -35,22 +35,22 @@
    = note: expected a single field to be coerced, none found
 
 error[E0378]: structs implementing `DispatchFromDyn` may not have `#[repr(packed)]` or `#[repr(C)]`
-  --> $DIR/invalid_dispatch_from_dyn_impls.rs:39:1
+  --> $DIR/dispatch-from-dyn-invalid-impls.rs:51:1
    |
 LL | / impl<T: ?Sized, U: ?Sized> DispatchFromDyn<HasReprC<U>> for HasReprC<T>
 LL | |
 LL | | where
-LL | |     T: Unsize<U>,
-   | |_________________^
+LL | |     T: Unsize<U>
+   | |________________^
 
 error[E0378]: the trait `DispatchFromDyn` may only be implemented for structs containing the field being coerced, ZST fields with 1 byte alignment that don't mention type/const generics, and nothing else
-  --> $DIR/invalid_dispatch_from_dyn_impls.rs:49:1
+  --> $DIR/dispatch-from-dyn-invalid-impls.rs:64:1
    |
 LL | / impl<T: ?Sized, U: ?Sized> DispatchFromDyn<OverAligned<U>> for OverAligned<T>
 LL | |
-LL | |     where
-LL | |         T: Unsize<U>,
-   | |_____________________^
+LL | | where
+LL | |     T: Unsize<U>
+   | |________________^
    |
    = note: extra field `1` of type `OverAlignedZst` is not allowed
 
diff --git a/tests/ui/traits/dyn-star-drop-principal.rs b/tests/ui/traits/dyn-star-drop-principal.rs
deleted file mode 100644
index 1ad9907..0000000
--- a/tests/ui/traits/dyn-star-drop-principal.rs
+++ /dev/null
@@ -1,12 +0,0 @@
-#![feature(dyn_star)]
-#![allow(incomplete_features)]
-
-trait Trait {}
-impl Trait for usize {}
-
-fn main() {
-    // We allow &dyn Trait + Send -> &dyn Send (i.e. dropping principal),
-    // but we don't (currently?) allow the same for dyn*
-    let x: dyn* Trait + Send = 1usize;
-    x as dyn* Send; //~ error: `dyn* Trait + Send` needs to have the same ABI as a pointer
-}
diff --git a/tests/ui/traits/dyn-star-drop-principal.stderr b/tests/ui/traits/dyn-star-drop-principal.stderr
deleted file mode 100644
index 721ae7e..0000000
--- a/tests/ui/traits/dyn-star-drop-principal.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0277]: `dyn* Trait + Send` needs to have the same ABI as a pointer
-  --> $DIR/dyn-star-drop-principal.rs:11:5
-   |
-LL |     x as dyn* Send;
-   |     ^ `dyn* Trait + Send` needs to be a pointer-like type
-   |
-   = help: the trait `PointerLike` is not implemented for `dyn* Trait + Send`
-
-error: aborting due to 1 previous error
-
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/issue-11881.rs b/tests/ui/traits/encoder-trait-bounds-regression.rs
similarity index 76%
rename from tests/ui/issue-11881.rs
rename to tests/ui/traits/encoder-trait-bounds-regression.rs
index 1abe079..292b921 100644
--- a/tests/ui/issue-11881.rs
+++ b/tests/ui/traits/encoder-trait-bounds-regression.rs
@@ -1,14 +1,23 @@
+//! Regression test for issue #11881
+//!
+//! Originally, the compiler would ICE when trying to parameterize on certain encoder types
+//! due to issues with higher-ranked trait bounds and lifetime inference. This test checks
+//! that various encoder patterns work correctly:
+//! - Generic encoders with associated error types
+//! - Higher-ranked trait bounds (for<'r> Encodable<JsonEncoder<'r>>)
+//! - Multiple encoder implementations for the same type
+//! - Polymorphic encoding functions
+
 //@ run-pass
 
 #![allow(unused_must_use)]
 #![allow(dead_code)]
 #![allow(unused_imports)]
 
-use std::fmt;
-use std::io::prelude::*;
 use std::io::Cursor;
-use std::slice;
+use std::io::prelude::*;
 use std::marker::PhantomData;
+use std::{fmt, slice};
 
 trait Encoder {
     type Error;
@@ -45,7 +54,6 @@ impl Encoder for OpaqueEncoder {
     type Error = ();
 }
 
-
 struct Foo {
     baz: bool,
 }
@@ -69,7 +77,6 @@ fn encode(&self, _s: &mut S) -> Result<(), S::Error> {
 enum WireProtocol {
     JSON,
     Opaque,
-    // ...
 }
 
 fn encode_json<T: for<'a> Encodable<JsonEncoder<'a>>>(val: &T, wr: &mut Cursor<Vec<u8>>) {
diff --git a/tests/ui/traits/enum-negative-send-impl.rs b/tests/ui/traits/enum-negative-send-impl.rs
new file mode 100644
index 0000000..6bff42e
--- /dev/null
+++ b/tests/ui/traits/enum-negative-send-impl.rs
@@ -0,0 +1,22 @@
+//! Test that enums inherit Send/!Send properties from their variants.
+//!
+//! Uses the unstable `negative_impls` feature to explicitly opt-out of Send.
+
+#![feature(negative_impls)]
+
+use std::marker::Send;
+
+struct NoSend;
+impl !Send for NoSend {}
+
+enum Container {
+    WithNoSend(NoSend),
+}
+
+fn requires_send<T: Send>(_: T) {}
+
+fn main() {
+    let container = Container::WithNoSend(NoSend);
+    requires_send(container);
+    //~^ ERROR `NoSend` cannot be sent between threads safely
+}
diff --git a/tests/ui/traits/enum-negative-send-impl.stderr b/tests/ui/traits/enum-negative-send-impl.stderr
new file mode 100644
index 0000000..1992bec
--- /dev/null
+++ b/tests/ui/traits/enum-negative-send-impl.stderr
@@ -0,0 +1,23 @@
+error[E0277]: `NoSend` cannot be sent between threads safely
+  --> $DIR/enum-negative-send-impl.rs:20:19
+   |
+LL |     requires_send(container);
+   |     ------------- ^^^^^^^^^ `NoSend` cannot be sent between threads safely
+   |     |
+   |     required by a bound introduced by this call
+   |
+   = help: within `Container`, the trait `Send` is not implemented for `NoSend`
+note: required because it appears within the type `Container`
+  --> $DIR/enum-negative-send-impl.rs:12:6
+   |
+LL | enum Container {
+   |      ^^^^^^^^^
+note: required by a bound in `requires_send`
+  --> $DIR/enum-negative-send-impl.rs:16:21
+   |
+LL | fn requires_send<T: Send>(_: T) {}
+   |                     ^^^^ required by this bound in `requires_send`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/traits/enum-negative-sync-impl.rs b/tests/ui/traits/enum-negative-sync-impl.rs
new file mode 100644
index 0000000..aa81a9f
--- /dev/null
+++ b/tests/ui/traits/enum-negative-sync-impl.rs
@@ -0,0 +1,22 @@
+//! Test that enums inherit Sync/!Sync properties from their variants.
+//!
+//! Uses the unstable `negative_impls` feature to explicitly opt-out of Sync.
+
+#![feature(negative_impls)]
+
+use std::marker::Sync;
+
+struct NoSync;
+impl !Sync for NoSync {}
+
+enum Container {
+    WithNoSync(NoSync),
+}
+
+fn requires_sync<T: Sync>(_: T) {}
+
+fn main() {
+    let container = Container::WithNoSync(NoSync);
+    requires_sync(container);
+    //~^ ERROR `NoSync` cannot be shared between threads safely [E0277]
+}
diff --git a/tests/ui/traits/enum-negative-sync-impl.stderr b/tests/ui/traits/enum-negative-sync-impl.stderr
new file mode 100644
index 0000000..a97b7a3
--- /dev/null
+++ b/tests/ui/traits/enum-negative-sync-impl.stderr
@@ -0,0 +1,23 @@
+error[E0277]: `NoSync` cannot be shared between threads safely
+  --> $DIR/enum-negative-sync-impl.rs:20:19
+   |
+LL |     requires_sync(container);
+   |     ------------- ^^^^^^^^^ `NoSync` cannot be shared between threads safely
+   |     |
+   |     required by a bound introduced by this call
+   |
+   = help: within `Container`, the trait `Sync` is not implemented for `NoSync`
+note: required because it appears within the type `Container`
+  --> $DIR/enum-negative-sync-impl.rs:12:6
+   |
+LL | enum Container {
+   |      ^^^^^^^^^
+note: required by a bound in `requires_sync`
+  --> $DIR/enum-negative-sync-impl.rs:16:21
+   |
+LL | fn requires_sync<T: Sync>(_: T) {}
+   |                     ^^^^ required by this bound in `requires_sync`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/traits/eval-caching-error-region.rs b/tests/ui/traits/eval-caching-error-region.rs
new file mode 100644
index 0000000..831b5ab
--- /dev/null
+++ b/tests/ui/traits/eval-caching-error-region.rs
@@ -0,0 +1,23 @@
+// Regression test for #132882.
+
+use std::ops::Add;
+
+pub trait Numoid: Sized
+where
+    &'missing Self: Add<Self>,
+    //~^ ERROR use of undeclared lifetime name `'missing`
+{
+}
+
+// Proving `N: Numoid`'s well-formedness causes us to have to prove `&'missing N: Add<N>`.
+// Since `'missing` is a region error, that will lead to us consider the predicate to hold,
+// since it references errors. Since the freshener turns error regions into fresh regions,
+// this means that subsequent lookups of `&'?0 N: Add<N>` will also hit this cache entry
+// even if candidate assembly can't assemble anything for `&'?0 N: Add<?1>` anyways. This
+// led to an ICE.
+pub fn compute<N: Numoid>(a: N) {
+    let _ = &a + a;
+    //~^ ERROR cannot add `N` to `&N`
+}
+
+fn main() {}
diff --git a/tests/ui/traits/eval-caching-error-region.stderr b/tests/ui/traits/eval-caching-error-region.stderr
new file mode 100644
index 0000000..6365d24
--- /dev/null
+++ b/tests/ui/traits/eval-caching-error-region.stderr
@@ -0,0 +1,33 @@
+error[E0261]: use of undeclared lifetime name `'missing`
+  --> $DIR/eval-caching-error-region.rs:7:6
+   |
+LL |     &'missing Self: Add<Self>,
+   |      ^^^^^^^^ undeclared lifetime
+   |
+   = note: for more information on higher-ranked polymorphism, visit https://doc.rust-lang.org/nomicon/hrtb.html
+help: consider making the bound lifetime-generic with a new `'missing` lifetime
+   |
+LL |     for<'missing> &'missing Self: Add<Self>,
+   |     +++++++++++++
+help: consider introducing lifetime `'missing` here
+   |
+LL | pub trait Numoid<'missing>: Sized
+   |                 ++++++++++
+
+error[E0369]: cannot add `N` to `&N`
+  --> $DIR/eval-caching-error-region.rs:19:16
+   |
+LL |     let _ = &a + a;
+   |             -- ^ - N
+   |             |
+   |             &N
+   |
+help: consider introducing a `where` clause, but there might be an alternative better way to express this requirement
+   |
+LL | pub fn compute<N: Numoid>(a: N) where &N: Add<N> {
+   |                                 ++++++++++++++++
+
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0261, E0369.
+For more information about an error, try `rustc --explain E0261`.
diff --git a/tests/ui/traits/issue-105231.stderr b/tests/ui/traits/issue-105231.stderr
index e113f83..b048548 100644
--- a/tests/ui/traits/issue-105231.stderr
+++ b/tests/ui/traits/issue-105231.stderr
@@ -1,3 +1,14 @@
+error: type parameter `T` is only used recursively
+  --> $DIR/issue-105231.rs:1:15
+   |
+LL | struct A<T>(B<T>);
+   |          -    ^
+   |          |
+   |          type parameter must be used non-recursively in the definition
+   |
+   = help: consider removing `T`, referring to it in a field, or using a marker such as `PhantomData`
+   = note: all type parameters must be used in a non-recursive way in order to constrain their variance
+
 error[E0072]: recursive types `A` and `B` have infinite size
   --> $DIR/issue-105231.rs:1:1
    |
@@ -16,17 +27,6 @@
    |
 
 error: type parameter `T` is only used recursively
-  --> $DIR/issue-105231.rs:1:15
-   |
-LL | struct A<T>(B<T>);
-   |          -    ^
-   |          |
-   |          type parameter must be used non-recursively in the definition
-   |
-   = help: consider removing `T`, referring to it in a field, or using a marker such as `PhantomData`
-   = note: all type parameters must be used in a non-recursive way in order to constrain their variance
-
-error: type parameter `T` is only used recursively
   --> $DIR/issue-105231.rs:4:17
    |
 LL | struct B<T>(A<A<T>>);
diff --git a/tests/ui/traits/issue-78372.stderr b/tests/ui/traits/issue-78372.stderr
index fbc60ce..a1c772f 100644
--- a/tests/ui/traits/issue-78372.stderr
+++ b/tests/ui/traits/issue-78372.stderr
@@ -56,6 +56,12 @@
    = help: add `#![feature(dispatch_from_dyn)]` to the crate attributes to enable
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
+error[E0377]: the trait `DispatchFromDyn` may only be implemented for a coercion between structures
+  --> $DIR/issue-78372.rs:3:1
+   |
+LL | impl<T> DispatchFromDyn<Smaht<U, MISC>> for T {}
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
 error[E0307]: invalid `self` parameter type: `Smaht<Self, T>`
   --> $DIR/issue-78372.rs:9:18
    |
@@ -65,12 +71,6 @@
    = note: type of `self` must be `Self` or a type that dereferences to it
    = help: consider changing to `self`, `&self`, `&mut self`, `self: Box<Self>`, `self: Rc<Self>`, `self: Arc<Self>`, or `self: Pin<P>` (where P is one of the previous types except `Self`)
 
-error[E0377]: the trait `DispatchFromDyn` may only be implemented for a coercion between structures
-  --> $DIR/issue-78372.rs:3:1
-   |
-LL | impl<T> DispatchFromDyn<Smaht<U, MISC>> for T {}
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
 error: aborting due to 7 previous errors
 
 Some errors have detailed explanations: E0307, E0377, E0412, E0658.
diff --git a/tests/ui/traits/issue-87558.stderr b/tests/ui/traits/issue-87558.stderr
index 4cc3ec2..dc5bd6e 100644
--- a/tests/ui/traits/issue-87558.stderr
+++ b/tests/ui/traits/issue-87558.stderr
@@ -24,6 +24,14 @@
 LL | impl Fn(&isize) for Error {
    |      ^^^^^^^^^^
 
+error[E0046]: not all trait items implemented, missing: `call`
+  --> $DIR/issue-87558.rs:3:1
+   |
+LL | impl Fn(&isize) for Error {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^ missing `call` in implementation
+   |
+   = help: implement the missing item: `fn call(&self, _: (&isize,)) -> <Self as FnOnce<(&isize,)>>::Output { todo!() }`
+
 error[E0277]: expected a `FnMut(&isize)` closure, found `Error`
   --> $DIR/issue-87558.rs:3:21
    |
@@ -34,14 +42,6 @@
 note: required by a bound in `Fn`
   --> $SRC_DIR/core/src/ops/function.rs:LL:COL
 
-error[E0046]: not all trait items implemented, missing: `call`
-  --> $DIR/issue-87558.rs:3:1
-   |
-LL | impl Fn(&isize) for Error {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^ missing `call` in implementation
-   |
-   = help: implement the missing item: `fn call(&self, _: (&isize,)) -> <Self as FnOnce<(&isize,)>>::Output { todo!() }`
-
 error: aborting due to 5 previous errors
 
 Some errors have detailed explanations: E0046, E0183, E0229, E0277, E0407.
diff --git a/tests/ui/traits/maybe-trait-bounds-forbidden-locations.rs b/tests/ui/traits/maybe-trait-bounds-forbidden-locations.rs
new file mode 100644
index 0000000..04963c9
--- /dev/null
+++ b/tests/ui/traits/maybe-trait-bounds-forbidden-locations.rs
@@ -0,0 +1,18 @@
+//! Test that ?Trait bounds are forbidden in supertraits and trait object types.
+//!
+//! While `?Sized` and other maybe bounds are allowed in type parameter bounds and where clauses,
+//! they are explicitly forbidden in certain syntactic positions:
+//! - As supertraits in trait definitions
+//! - In trait object type expressions
+//!
+//! See https://github.com/rust-lang/rust/issues/20503
+
+trait Tr: ?Sized {}
+//~^ ERROR `?Trait` is not permitted in supertraits
+
+type A1 = dyn Tr + (?Sized);
+//~^ ERROR `?Trait` is not permitted in trait object types
+type A2 = dyn for<'a> Tr + (?Sized);
+//~^ ERROR `?Trait` is not permitted in trait object types
+
+fn main() {}
diff --git a/tests/ui/maybe-bounds.stderr b/tests/ui/traits/maybe-trait-bounds-forbidden-locations.stderr
similarity index 85%
rename from tests/ui/maybe-bounds.stderr
rename to tests/ui/traits/maybe-trait-bounds-forbidden-locations.stderr
index 230d11f..bd0baa5 100644
--- a/tests/ui/maybe-bounds.stderr
+++ b/tests/ui/traits/maybe-trait-bounds-forbidden-locations.stderr
@@ -1,5 +1,5 @@
 error[E0658]: `?Trait` is not permitted in supertraits
-  --> $DIR/maybe-bounds.rs:1:11
+  --> $DIR/maybe-trait-bounds-forbidden-locations.rs:10:11
    |
 LL | trait Tr: ?Sized {}
    |           ^^^^^^
@@ -9,7 +9,7 @@
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: `?Trait` is not permitted in trait object types
-  --> $DIR/maybe-bounds.rs:4:20
+  --> $DIR/maybe-trait-bounds-forbidden-locations.rs:13:20
    |
 LL | type A1 = dyn Tr + (?Sized);
    |                    ^^^^^^^^
@@ -18,7 +18,7 @@
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0658]: `?Trait` is not permitted in trait object types
-  --> $DIR/maybe-bounds.rs:6:28
+  --> $DIR/maybe-trait-bounds-forbidden-locations.rs:15:28
    |
 LL | type A2 = dyn for<'a> Tr + (?Sized);
    |                            ^^^^^^^^
diff --git a/tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr b/tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr
index d535c39..6472ac7 100644
--- a/tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr
+++ b/tests/ui/traits/method-argument-mismatch-variance-ice-119867.stderr
@@ -1,4 +1,4 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/method-argument-mismatch-variance-ice-119867.rs:8:23
    |
 LL |     fn deserialize(s: _) {}
diff --git a/tests/ui/traits/next-solver/issue-118950-root-region.stderr b/tests/ui/traits/next-solver/issue-118950-root-region.stderr
index 45fa33d..391272b 100644
--- a/tests/ui/traits/next-solver/issue-118950-root-region.stderr
+++ b/tests/ui/traits/next-solver/issue-118950-root-region.stderr
@@ -14,10 +14,10 @@
    = note: `#[warn(incomplete_features)]` on by default
 
 error[E0277]: the trait bound `*const T: ToUnit<'a>` is not satisfied
-  --> $DIR/issue-118950-root-region.rs:14:21
+  --> $DIR/issue-118950-root-region.rs:14:1
    |
 LL | type Assoc<'a, T> = <*const T as ToUnit<'a>>::Unit;
-   |                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `ToUnit<'a>` is not implemented for `*const T`
+   | ^^^^^^^^^^^^^^^^^ the trait `ToUnit<'a>` is not implemented for `*const T`
    |
 help: this trait has no implementations, consider adding one
   --> $DIR/issue-118950-root-region.rs:8:1
diff --git a/tests/ui/traits/rc-not-send.rs b/tests/ui/traits/rc-not-send.rs
new file mode 100644
index 0000000..83084c6
--- /dev/null
+++ b/tests/ui/traits/rc-not-send.rs
@@ -0,0 +1,11 @@
+//! Test that `Rc<T>` does not implement `Send`.
+
+use std::rc::Rc;
+
+fn requires_send<T: Send>(_: T) {}
+
+fn main() {
+    let rc_value = Rc::new(5);
+    requires_send(rc_value);
+    //~^ ERROR `Rc<{integer}>` cannot be sent between threads safely
+}
diff --git a/tests/ui/traits/rc-not-send.stderr b/tests/ui/traits/rc-not-send.stderr
new file mode 100644
index 0000000..d6171a3
--- /dev/null
+++ b/tests/ui/traits/rc-not-send.stderr
@@ -0,0 +1,22 @@
+error[E0277]: `Rc<{integer}>` cannot be sent between threads safely
+  --> $DIR/rc-not-send.rs:9:19
+   |
+LL |     requires_send(rc_value);
+   |     ------------- ^^^^^^^^ `Rc<{integer}>` cannot be sent between threads safely
+   |     |
+   |     required by a bound introduced by this call
+   |
+   = help: the trait `Send` is not implemented for `Rc<{integer}>`
+note: required by a bound in `requires_send`
+  --> $DIR/rc-not-send.rs:5:21
+   |
+LL | fn requires_send<T: Send>(_: T) {}
+   |                     ^^^^ required by this bound in `requires_send`
+help: consider dereferencing here
+   |
+LL |     requires_send(*rc_value);
+   |                   +
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/traits/struct-negative-sync-impl.rs b/tests/ui/traits/struct-negative-sync-impl.rs
new file mode 100644
index 0000000..d328462
--- /dev/null
+++ b/tests/ui/traits/struct-negative-sync-impl.rs
@@ -0,0 +1,21 @@
+//! Test negative Sync implementation on structs.
+//!
+//! Uses the unstable `negative_impls` feature to explicitly opt-out of Sync.
+
+#![feature(negative_impls)]
+
+use std::marker::Sync;
+
+struct NotSync {
+    value: isize,
+}
+
+impl !Sync for NotSync {}
+
+fn requires_sync<T: Sync>(_: T) {}
+
+fn main() {
+    let not_sync = NotSync { value: 5 };
+    requires_sync(not_sync);
+    //~^ ERROR `NotSync` cannot be shared between threads safely [E0277]
+}
diff --git a/tests/ui/traits/struct-negative-sync-impl.stderr b/tests/ui/traits/struct-negative-sync-impl.stderr
new file mode 100644
index 0000000..c5fd13f
--- /dev/null
+++ b/tests/ui/traits/struct-negative-sync-impl.stderr
@@ -0,0 +1,18 @@
+error[E0277]: `NotSync` cannot be shared between threads safely
+  --> $DIR/struct-negative-sync-impl.rs:19:19
+   |
+LL |     requires_sync(not_sync);
+   |     ------------- ^^^^^^^^ `NotSync` cannot be shared between threads safely
+   |     |
+   |     required by a bound introduced by this call
+   |
+   = help: the trait `Sync` is not implemented for `NotSync`
+note: required by a bound in `requires_sync`
+  --> $DIR/struct-negative-sync-impl.rs:15:21
+   |
+LL | fn requires_sync<T: Sync>(_: T) {}
+   |                     ^^^^ required by this bound in `requires_sync`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr
index b9988e2..4264f26 100644
--- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr
+++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr
@@ -9,7 +9,7 @@
   --> $DIR/cyclic-trait-resolution.rs:1:1
    |
 LL | trait A: B + A {}
-   | ^^^^^^^^^^^^^^^^^
+   | ^^^^^^^^^^^^^^
    = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error[E0391]: cycle detected when computing the implied predicates of `A`
diff --git a/tests/ui/traits/trait-upcasting/dyn-to-dyn-star.rs b/tests/ui/traits/trait-upcasting/dyn-to-dyn-star.rs
deleted file mode 100644
index 5936c93e..0000000
--- a/tests/ui/traits/trait-upcasting/dyn-to-dyn-star.rs
+++ /dev/null
@@ -1,19 +0,0 @@
-// While somewhat nonsensical, this is a cast from a wide pointer to a thin pointer.
-// Thus, we don't need to check an unsize goal here; there isn't any vtable casting
-// happening at all.
-
-// Regression test for <https://github.com/rust-lang/rust/issues/137579>.
-
-//@ check-pass
-
-#![allow(incomplete_features)]
-#![feature(dyn_star)]
-
-trait Foo {}
-trait Bar {}
-
-fn cast(x: *const dyn Foo) {
-    x as *const dyn* Bar;
-}
-
-fn main() {}
diff --git a/tests/ui/traits/unconstrained-projection-normalization-2.current.stderr b/tests/ui/traits/unconstrained-projection-normalization-2.current.stderr
index 2bb389c..9ce0e8d 100644
--- a/tests/ui/traits/unconstrained-projection-normalization-2.current.stderr
+++ b/tests/ui/traits/unconstrained-projection-normalization-2.current.stderr
@@ -4,6 +4,31 @@
 LL | impl<T: ?Sized> Every for Thing {
    |      ^ unconstrained type parameter
 
-error: aborting due to 1 previous error
+error[E0277]: the size for values of type `T` cannot be known at compilation time
+  --> $DIR/unconstrained-projection-normalization-2.rs:16:18
+   |
+LL | impl<T: ?Sized> Every for Thing {
+   |      - this type parameter needs to be `Sized`
+LL |
+LL |     type Assoc = T;
+   |                  ^ doesn't have a size known at compile-time
+   |
+note: required by a bound in `Every::Assoc`
+  --> $DIR/unconstrained-projection-normalization-2.rs:12:5
+   |
+LL |     type Assoc;
+   |     ^^^^^^^^^^^ required by this bound in `Every::Assoc`
+help: consider removing the `?Sized` bound to make the type parameter `Sized`
+   |
+LL - impl<T: ?Sized> Every for Thing {
+LL + impl<T> Every for Thing {
+   |
+help: consider relaxing the implicit `Sized` restriction
+   |
+LL |     type Assoc: ?Sized;
+   |               ++++++++
 
-For more information about this error, try `rustc --explain E0207`.
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0207, E0277.
+For more information about an error, try `rustc --explain E0207`.
diff --git a/tests/ui/traits/unconstrained-projection-normalization-2.next.stderr b/tests/ui/traits/unconstrained-projection-normalization-2.next.stderr
index 3eacab3..2da655a 100644
--- a/tests/ui/traits/unconstrained-projection-normalization-2.next.stderr
+++ b/tests/ui/traits/unconstrained-projection-normalization-2.next.stderr
@@ -4,13 +4,37 @@
 LL | impl<T: ?Sized> Every for Thing {
    |      ^ unconstrained type parameter
 
+error[E0277]: the size for values of type `T` cannot be known at compilation time
+  --> $DIR/unconstrained-projection-normalization-2.rs:16:18
+   |
+LL | impl<T: ?Sized> Every for Thing {
+   |      - this type parameter needs to be `Sized`
+LL |
+LL |     type Assoc = T;
+   |                  ^ doesn't have a size known at compile-time
+   |
+note: required by a bound in `Every::Assoc`
+  --> $DIR/unconstrained-projection-normalization-2.rs:12:5
+   |
+LL |     type Assoc;
+   |     ^^^^^^^^^^^ required by this bound in `Every::Assoc`
+help: consider removing the `?Sized` bound to make the type parameter `Sized`
+   |
+LL - impl<T: ?Sized> Every for Thing {
+LL + impl<T> Every for Thing {
+   |
+help: consider relaxing the implicit `Sized` restriction
+   |
+LL |     type Assoc: ?Sized;
+   |               ++++++++
+
 error[E0282]: type annotations needed
-  --> $DIR/unconstrained-projection-normalization-2.rs:19:11
+  --> $DIR/unconstrained-projection-normalization-2.rs:20:11
    |
 LL | fn foo(_: <Thing as Every>::Assoc) {}
    |           ^^^^^^^^^^^^^^^^^^^^^^^ cannot infer type for associated type `<Thing as Every>::Assoc`
 
-error: aborting due to 2 previous errors
+error: aborting due to 3 previous errors
 
-Some errors have detailed explanations: E0207, E0282.
+Some errors have detailed explanations: E0207, E0277, E0282.
 For more information about an error, try `rustc --explain E0207`.
diff --git a/tests/ui/traits/unconstrained-projection-normalization-2.rs b/tests/ui/traits/unconstrained-projection-normalization-2.rs
index 9d95c73..899d675 100644
--- a/tests/ui/traits/unconstrained-projection-normalization-2.rs
+++ b/tests/ui/traits/unconstrained-projection-normalization-2.rs
@@ -12,8 +12,9 @@ pub trait Every {
     type Assoc;
 }
 impl<T: ?Sized> Every for Thing {
-//~^ ERROR the type parameter `T` is not constrained
+    //~^ ERROR the type parameter `T` is not constrained
     type Assoc = T;
+    //~^ ERROR: the size for values of type `T` cannot be known at compilation time
 }
 
 fn foo(_: <Thing as Every>::Assoc) {}
diff --git a/tests/ui/traits/unconstrained-projection-normalization.current.stderr b/tests/ui/traits/unconstrained-projection-normalization.current.stderr
index 991f0e8..c52e8dd 100644
--- a/tests/ui/traits/unconstrained-projection-normalization.current.stderr
+++ b/tests/ui/traits/unconstrained-projection-normalization.current.stderr
@@ -4,6 +4,31 @@
 LL | impl<T: ?Sized> Every for Thing {
    |      ^ unconstrained type parameter
 
-error: aborting due to 1 previous error
+error[E0277]: the size for values of type `T` cannot be known at compilation time
+  --> $DIR/unconstrained-projection-normalization.rs:15:18
+   |
+LL | impl<T: ?Sized> Every for Thing {
+   |      - this type parameter needs to be `Sized`
+LL |
+LL |     type Assoc = T;
+   |                  ^ doesn't have a size known at compile-time
+   |
+note: required by a bound in `Every::Assoc`
+  --> $DIR/unconstrained-projection-normalization.rs:11:5
+   |
+LL |     type Assoc;
+   |     ^^^^^^^^^^^ required by this bound in `Every::Assoc`
+help: consider removing the `?Sized` bound to make the type parameter `Sized`
+   |
+LL - impl<T: ?Sized> Every for Thing {
+LL + impl<T> Every for Thing {
+   |
+help: consider relaxing the implicit `Sized` restriction
+   |
+LL |     type Assoc: ?Sized;
+   |               ++++++++
 
-For more information about this error, try `rustc --explain E0207`.
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0207, E0277.
+For more information about an error, try `rustc --explain E0207`.
diff --git a/tests/ui/traits/unconstrained-projection-normalization.next.stderr b/tests/ui/traits/unconstrained-projection-normalization.next.stderr
index 991f0e8..c52e8dd 100644
--- a/tests/ui/traits/unconstrained-projection-normalization.next.stderr
+++ b/tests/ui/traits/unconstrained-projection-normalization.next.stderr
@@ -4,6 +4,31 @@
 LL | impl<T: ?Sized> Every for Thing {
    |      ^ unconstrained type parameter
 
-error: aborting due to 1 previous error
+error[E0277]: the size for values of type `T` cannot be known at compilation time
+  --> $DIR/unconstrained-projection-normalization.rs:15:18
+   |
+LL | impl<T: ?Sized> Every for Thing {
+   |      - this type parameter needs to be `Sized`
+LL |
+LL |     type Assoc = T;
+   |                  ^ doesn't have a size known at compile-time
+   |
+note: required by a bound in `Every::Assoc`
+  --> $DIR/unconstrained-projection-normalization.rs:11:5
+   |
+LL |     type Assoc;
+   |     ^^^^^^^^^^^ required by this bound in `Every::Assoc`
+help: consider removing the `?Sized` bound to make the type parameter `Sized`
+   |
+LL - impl<T: ?Sized> Every for Thing {
+LL + impl<T> Every for Thing {
+   |
+help: consider relaxing the implicit `Sized` restriction
+   |
+LL |     type Assoc: ?Sized;
+   |               ++++++++
 
-For more information about this error, try `rustc --explain E0207`.
+error: aborting due to 2 previous errors
+
+Some errors have detailed explanations: E0207, E0277.
+For more information about an error, try `rustc --explain E0207`.
diff --git a/tests/ui/traits/unconstrained-projection-normalization.rs b/tests/ui/traits/unconstrained-projection-normalization.rs
index fa4ab7f..8e94445 100644
--- a/tests/ui/traits/unconstrained-projection-normalization.rs
+++ b/tests/ui/traits/unconstrained-projection-normalization.rs
@@ -11,8 +11,9 @@ pub trait Every {
     type Assoc;
 }
 impl<T: ?Sized> Every for Thing {
-//~^ ERROR the type parameter `T` is not constrained
+    //~^ ERROR the type parameter `T` is not constrained
     type Assoc = T;
+    //~^ ERROR: the size for values of type `T` cannot be known at compilation time
 }
 
 static I: <Thing as Every>::Assoc = 3;
diff --git a/tests/ui/type-alias-enum-variants/module-type-args-error.rs b/tests/ui/type-alias-enum-variants/module-type-args-error.rs
new file mode 100644
index 0000000..9f7dae4
--- /dev/null
+++ b/tests/ui/type-alias-enum-variants/module-type-args-error.rs
@@ -0,0 +1,16 @@
+//! Test that type arguments are properly rejected on modules.
+//!
+//! Related PR: https://github.com/rust-lang/rust/pull/56225 (RFC 2338 implementation)
+
+mod Mod {
+    pub struct FakeVariant<T>(pub T);
+}
+
+fn main() {
+    // This should work fine - normal generic struct constructor
+    Mod::FakeVariant::<i32>(0);
+
+    // This should error - type arguments not allowed on modules
+    Mod::<i32>::FakeVariant(0);
+    //~^ ERROR type arguments are not allowed on module `Mod` [E0109]
+}
diff --git a/tests/ui/mod-subitem-as-enum-variant.stderr b/tests/ui/type-alias-enum-variants/module-type-args-error.stderr
similarity index 85%
rename from tests/ui/mod-subitem-as-enum-variant.stderr
rename to tests/ui/type-alias-enum-variants/module-type-args-error.stderr
index 92d972e..4c59d19 100644
--- a/tests/ui/mod-subitem-as-enum-variant.stderr
+++ b/tests/ui/type-alias-enum-variants/module-type-args-error.stderr
@@ -1,5 +1,5 @@
 error[E0109]: type arguments are not allowed on module `Mod`
-  --> $DIR/mod-subitem-as-enum-variant.rs:7:11
+  --> $DIR/module-type-args-error.rs:14:11
    |
 LL |     Mod::<i32>::FakeVariant(0);
    |     ---   ^^^ type argument not allowed
diff --git a/tests/ui/typeck/issue-13853-5.rs b/tests/ui/typeck/issue-13853-5.rs
index fc97c6c..47596aa 100644
--- a/tests/ui/typeck/issue-13853-5.rs
+++ b/tests/ui/typeck/issue-13853-5.rs
@@ -1,4 +1,4 @@
-trait Deserializer<'a> { }
+trait Deserializer<'a> {}
 
 trait Deserializable {
     fn deserialize_token<'a, D: Deserializer<'a>>(_: D, _: &'a str) -> Self;
@@ -8,6 +8,7 @@ impl<'a, T: Deserializable> Deserializable for &'a str {
     //~^ ERROR type parameter `T` is not constrained
     fn deserialize_token<D: Deserializer<'a>>(_x: D, _y: &'a str) -> &'a str {
         //~^ ERROR mismatched types
+        //~| ERROR do not match the trait declaration
     }
 }
 
diff --git a/tests/ui/typeck/issue-13853-5.stderr b/tests/ui/typeck/issue-13853-5.stderr
index 4e483a0..bb967b0 100644
--- a/tests/ui/typeck/issue-13853-5.stderr
+++ b/tests/ui/typeck/issue-13853-5.stderr
@@ -1,3 +1,12 @@
+error[E0195]: lifetime parameters or bounds on associated function `deserialize_token` do not match the trait declaration
+  --> $DIR/issue-13853-5.rs:9:25
+   |
+LL |     fn deserialize_token<'a, D: Deserializer<'a>>(_: D, _: &'a str) -> Self;
+   |                         ------------------------- lifetimes in impl do not match this associated function in trait
+...
+LL |     fn deserialize_token<D: Deserializer<'a>>(_x: D, _y: &'a str) -> &'a str {
+   |                         ^^^^^^^^^^^^^^^^^^^^^ lifetimes do not match associated function in trait
+
 error[E0207]: the type parameter `T` is not constrained by the impl trait, self type, or predicates
   --> $DIR/issue-13853-5.rs:7:10
    |
@@ -19,7 +28,7 @@
 LL ~
    |
 
-error: aborting due to 2 previous errors
+error: aborting due to 3 previous errors
 
-Some errors have detailed explanations: E0207, E0308.
-For more information about an error, try `rustc --explain E0207`.
+Some errors have detailed explanations: E0195, E0207, E0308.
+For more information about an error, try `rustc --explain E0195`.
diff --git a/tests/ui/typeck/issue-74086.rs b/tests/ui/typeck/issue-74086.rs
index 1993cc7..c00ba81 100644
--- a/tests/ui/typeck/issue-74086.rs
+++ b/tests/ui/typeck/issue-74086.rs
@@ -1,4 +1,4 @@
 fn main() {
     static BUG: fn(_) -> u8 = |_| 8;
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for static items
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for statics
 }
diff --git a/tests/ui/typeck/issue-74086.stderr b/tests/ui/typeck/issue-74086.stderr
index 25f454a..02c4820 100644
--- a/tests/ui/typeck/issue-74086.stderr
+++ b/tests/ui/typeck/issue-74086.stderr
@@ -1,4 +1,4 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for static items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for statics
   --> $DIR/issue-74086.rs:2:20
    |
 LL |     static BUG: fn(_) -> u8 = |_| 8;
diff --git a/tests/ui/typeck/issue-75889.stderr b/tests/ui/typeck/issue-75889.stderr
index 1438f48..c76f7c6 100644
--- a/tests/ui/typeck/issue-75889.stderr
+++ b/tests/ui/typeck/issue-75889.stderr
@@ -1,10 +1,10 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for constant items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
   --> $DIR/issue-75889.rs:3:24
    |
 LL | const FOO: dyn Fn() -> _ = "";
    |                        ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for static items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for statics
   --> $DIR/issue-75889.rs:4:25
    |
 LL | static BOO: dyn Fn() -> _ = "";
diff --git a/tests/ui/typeck/issue-81885.rs b/tests/ui/typeck/issue-81885.rs
index d73c77b..d675231 100644
--- a/tests/ui/typeck/issue-81885.rs
+++ b/tests/ui/typeck/issue-81885.rs
@@ -1,7 +1,7 @@
 const TEST4: fn() -> _ = 42;
-//~^ ERROR the placeholder `_` is not allowed within types on item signatures for constant items
+//~^ ERROR the placeholder `_` is not allowed within types on item signatures for constants
 
 fn main() {
     const TEST5: fn() -> _ = 42;
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for constant items
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for constants
 }
diff --git a/tests/ui/typeck/issue-81885.stderr b/tests/ui/typeck/issue-81885.stderr
index 25a6bb6..414fe54 100644
--- a/tests/ui/typeck/issue-81885.stderr
+++ b/tests/ui/typeck/issue-81885.stderr
@@ -1,10 +1,10 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for constant items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
   --> $DIR/issue-81885.rs:1:22
    |
 LL | const TEST4: fn() -> _ = 42;
    |                      ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for constant items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
   --> $DIR/issue-81885.rs:5:26
    |
 LL |     const TEST5: fn() -> _ = 42;
diff --git a/tests/ui/typeck/issue-83621-placeholder-static-in-extern.stderr b/tests/ui/typeck/issue-83621-placeholder-static-in-extern.stderr
index a4cb530..c4a5c0d 100644
--- a/tests/ui/typeck/issue-83621-placeholder-static-in-extern.stderr
+++ b/tests/ui/typeck/issue-83621-placeholder-static-in-extern.stderr
@@ -1,4 +1,4 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for static variables
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for statics
   --> $DIR/issue-83621-placeholder-static-in-extern.rs:4:15
    |
 LL |     static x: _;
diff --git a/tests/ui/typeck/issue-88643.rs b/tests/ui/typeck/issue-88643.rs
index 4435cba..e562f3e 100644
--- a/tests/ui/typeck/issue-88643.rs
+++ b/tests/ui/typeck/issue-88643.rs
@@ -8,12 +8,12 @@
 pub trait T {}
 
 static CALLBACKS: HashMap<*const dyn T, dyn FnMut(&mut _) + 'static> = HashMap::new();
-//~^ ERROR: the placeholder `_` is not allowed within types on item signatures for static items [E0121]
+//~^ ERROR: the placeholder `_` is not allowed within types on item signatures for statics [E0121]
 
 static CALLBACKS2: Vec<dyn Fn(& _)> = Vec::new();
-//~^ ERROR: the placeholder `_` is not allowed within types on item signatures for static items [E0121]
+//~^ ERROR: the placeholder `_` is not allowed within types on item signatures for statics [E0121]
 
 static CALLBACKS3: Option<dyn Fn(& _)> = None;
-//~^ ERROR: the placeholder `_` is not allowed within types on item signatures for static items [E0121]
+//~^ ERROR: the placeholder `_` is not allowed within types on item signatures for statics [E0121]
 
 fn main() {}
diff --git a/tests/ui/typeck/issue-88643.stderr b/tests/ui/typeck/issue-88643.stderr
index d5d596b..ad11c3e 100644
--- a/tests/ui/typeck/issue-88643.stderr
+++ b/tests/ui/typeck/issue-88643.stderr
@@ -1,16 +1,16 @@
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for static items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for statics
   --> $DIR/issue-88643.rs:10:56
    |
 LL | static CALLBACKS: HashMap<*const dyn T, dyn FnMut(&mut _) + 'static> = HashMap::new();
    |                                                        ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for static items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for statics
   --> $DIR/issue-88643.rs:13:33
    |
 LL | static CALLBACKS2: Vec<dyn Fn(& _)> = Vec::new();
    |                                 ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for static items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for statics
   --> $DIR/issue-88643.rs:16:36
    |
 LL | static CALLBACKS3: Option<dyn Fn(& _)> = None;
diff --git a/tests/ui/typeck/typeck_type_placeholder_item.rs b/tests/ui/typeck/typeck_type_placeholder_item.rs
index dc79036..48547c0 100644
--- a/tests/ui/typeck/typeck_type_placeholder_item.rs
+++ b/tests/ui/typeck/typeck_type_placeholder_item.rs
@@ -41,7 +41,7 @@ fn test9(&self) -> _ { () }
     //~^ ERROR the placeholder `_` is not allowed within types on item signatures for return types
 
     fn test10(&self, _x : _) { }
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
 }
 
 fn test11(x: &usize) -> &_ {
@@ -56,10 +56,10 @@ unsafe fn test12(x: *const usize) -> *const *const _ {
 
 impl Clone for Test9 {
     fn clone(&self) -> _ { Test9 }
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
 
     fn clone_from(&mut self, other: _) { *self = Test9; }
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
 }
 
 struct Test10 {
@@ -108,15 +108,15 @@ fn fn_test9(&self) -> _ { () }
         //~^ ERROR the placeholder `_` is not allowed within types on item signatures for return types
 
         fn fn_test10(&self, _x : _) { }
-        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
     }
 
     impl Clone for FnTest9 {
         fn clone(&self) -> _ { FnTest9 }
-        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
 
         fn clone_from(&mut self, other: _) { *self = FnTest9; }
-        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+        //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
     }
 
     struct FnTest10 {
@@ -140,19 +140,19 @@ fn fn_test13(x: _) -> (i32, _) { (x, x) }
 
 trait T {
     fn method_test1(&self, x: _);
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
     fn method_test2(&self, x: _) -> _;
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
-    //~| ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
+    //~| ERROR the placeholder `_` is not allowed within types on item signatures for methods
     fn method_test3(&self) -> _;
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for methods
     fn assoc_fn_test1(x: _);
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
     fn assoc_fn_test2(x: _) -> _;
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
-    //~| ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
+    //~| ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
     fn assoc_fn_test3() -> _;
-    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for functions
+    //~^ ERROR the placeholder `_` is not allowed within types on item signatures for associated functions
 }
 
 struct BadStruct<_>(_);
diff --git a/tests/ui/typeck/typeck_type_placeholder_item.stderr b/tests/ui/typeck/typeck_type_placeholder_item.stderr
index 53476f6..87750ee 100644
--- a/tests/ui/typeck/typeck_type_placeholder_item.stderr
+++ b/tests/ui/typeck/typeck_type_placeholder_item.stderr
@@ -203,7 +203,7 @@
    |                                      |             not allowed in type signatures
    |                                      help: replace with the correct return type: `*const *const usize`
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:58:24
    |
 LL |     fn clone(&self) -> _ { Test9 }
@@ -215,7 +215,7 @@
 LL +     fn clone(&self) -> Test9 { Test9 }
    |
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:61:37
    |
 LL |     fn clone_from(&mut self, other: _) { *self = Test9; }
@@ -332,7 +332,7 @@
 LL |     fn fn_test8(_f: fn() -> _) { }
    |                             ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:115:28
    |
 LL |         fn clone(&self) -> _ { FnTest9 }
@@ -344,7 +344,7 @@
 LL +         fn clone(&self) -> FnTest9 { FnTest9 }
    |
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:118:41
    |
 LL |         fn clone_from(&mut self, other: _) { *self = FnTest9; }
@@ -389,49 +389,49 @@
    |                           |     not allowed in type signatures
    |                           help: replace with the correct return type: `(i32, i32)`
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:142:31
    |
 LL |     fn method_test1(&self, x: _);
    |                               ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:144:31
    |
 LL |     fn method_test2(&self, x: _) -> _;
    |                               ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:144:37
    |
 LL |     fn method_test2(&self, x: _) -> _;
    |                                     ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:147:31
    |
 LL |     fn method_test3(&self) -> _;
    |                               ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/typeck_type_placeholder_item.rs:149:26
    |
 LL |     fn assoc_fn_test1(x: _);
    |                          ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/typeck_type_placeholder_item.rs:151:26
    |
 LL |     fn assoc_fn_test2(x: _) -> _;
    |                          ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/typeck_type_placeholder_item.rs:151:32
    |
 LL |     fn assoc_fn_test2(x: _) -> _;
    |                                ^ not allowed in type signatures
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for associated functions
   --> $DIR/typeck_type_placeholder_item.rs:154:28
    |
 LL |     fn assoc_fn_test3() -> _;
@@ -575,7 +575,7 @@
    |                        not allowed in type signatures
    |                        help: replace with the correct return type: `()`
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:43:27
    |
 LL |     fn test10(&self, _x : _) { }
@@ -590,7 +590,7 @@
    |                               not allowed in type signatures
    |                               help: replace with the correct return type: `()`
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for functions
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for methods
   --> $DIR/typeck_type_placeholder_item.rs:110:34
    |
 LL |         fn fn_test10(&self, _x : _) { }
diff --git a/tests/ui/typeck/typeck_type_placeholder_item_help.rs b/tests/ui/typeck/typeck_type_placeholder_item_help.rs
index ab433aa..758b94f 100644
--- a/tests/ui/typeck/typeck_type_placeholder_item_help.rs
+++ b/tests/ui/typeck/typeck_type_placeholder_item_help.rs
@@ -11,7 +11,7 @@ fn test1() -> _ { Some(42) }
 //~^ ERROR the placeholder `_` is not allowed within types on item signatures for constants
 
 const TEST4: fn() -> _ = 42;
-//~^ ERROR the placeholder `_` is not allowed within types on item signatures for constant items
+//~^ ERROR the placeholder `_` is not allowed within types on item signatures for constants
 
 trait Test5 {
     const TEST5: _ = 42;
diff --git a/tests/ui/typeck/typeck_type_placeholder_item_help.stderr b/tests/ui/typeck/typeck_type_placeholder_item_help.stderr
index 5066e2e..2fce00e 100644
--- a/tests/ui/typeck/typeck_type_placeholder_item_help.stderr
+++ b/tests/ui/typeck/typeck_type_placeholder_item_help.stderr
@@ -31,7 +31,7 @@
 LL + const TEST3: Option<i32> = Some(42);
    |
 
-error[E0121]: the placeholder `_` is not allowed within types on item signatures for constant items
+error[E0121]: the placeholder `_` is not allowed within types on item signatures for constants
   --> $DIR/typeck_type_placeholder_item_help.rs:13:22
    |
 LL | const TEST4: fn() -> _ = 42;
diff --git a/tests/ui/union/issue-81199.stderr b/tests/ui/union/issue-81199.stderr
index 8b78ddc..7deba88 100644
--- a/tests/ui/union/issue-81199.stderr
+++ b/tests/ui/union/issue-81199.stderr
@@ -1,3 +1,15 @@
+error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
+  --> $DIR/issue-81199.rs:5:5
+   |
+LL |     components: PtrComponents<T>,
+   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
+help: wrap the field type in `ManuallyDrop<...>`
+   |
+LL |     components: std::mem::ManuallyDrop<PtrComponents<T>>,
+   |                 +++++++++++++++++++++++                +
+
 error[E0277]: the trait bound `T: Pointee` is not satisfied
   --> $DIR/issue-81199.rs:5:17
    |
@@ -14,18 +26,6 @@
 LL | union PtrRepr<T: ?Sized + Pointee> {
    |                         +++++++++
 
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/issue-81199.rs:5:5
-   |
-LL |     components: PtrComponents<T>,
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     components: std::mem::ManuallyDrop<PtrComponents<T>>,
-   |                 +++++++++++++++++++++++                +
-
 error: aborting due to 2 previous errors
 
 Some errors have detailed explanations: E0277, E0740.
diff --git a/tests/ui/union/union-unsized.stderr b/tests/ui/union/union-unsized.stderr
index 851ad89..89ab716 100644
--- a/tests/ui/union/union-unsized.stderr
+++ b/tests/ui/union/union-unsized.stderr
@@ -1,3 +1,15 @@
+error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
+  --> $DIR/union-unsized.rs:2:5
+   |
+LL |     a: str,
+   |     ^^^^^^
+   |
+   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
+help: wrap the field type in `ManuallyDrop<...>`
+   |
+LL |     a: std::mem::ManuallyDrop<str>,
+   |        +++++++++++++++++++++++   +
+
 error[E0277]: the size for values of type `str` cannot be known at compilation time
   --> $DIR/union-unsized.rs:2:8
    |
@@ -17,15 +29,15 @@
    |        ++++   +
 
 error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-unsized.rs:2:5
+  --> $DIR/union-unsized.rs:11:5
    |
-LL |     a: str,
+LL |     b: str,
    |     ^^^^^^
    |
    = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
 help: wrap the field type in `ManuallyDrop<...>`
    |
-LL |     a: std::mem::ManuallyDrop<str>,
+LL |     b: std::mem::ManuallyDrop<str>,
    |        +++++++++++++++++++++++   +
 
 error[E0277]: the size for values of type `str` cannot be known at compilation time
@@ -46,18 +58,6 @@
 LL |     b: Box<str>,
    |        ++++   +
 
-error[E0740]: field must implement `Copy` or be wrapped in `ManuallyDrop<...>` to be used in a union
-  --> $DIR/union-unsized.rs:11:5
-   |
-LL |     b: str,
-   |     ^^^^^^
-   |
-   = note: union fields must not have drop side-effects, which is currently enforced via either `Copy` or `ManuallyDrop<...>`
-help: wrap the field type in `ManuallyDrop<...>`
-   |
-LL |     b: std::mem::ManuallyDrop<str>,
-   |        +++++++++++++++++++++++   +
-
 error: aborting due to 4 previous errors
 
 Some errors have detailed explanations: E0277, E0740.
diff --git a/tests/ui/unpretty/exhaustive.expanded.stdout b/tests/ui/unpretty/exhaustive.expanded.stdout
index 9df027b..53ca3c8 100644
--- a/tests/ui/unpretty/exhaustive.expanded.stdout
+++ b/tests/ui/unpretty/exhaustive.expanded.stdout
@@ -15,7 +15,6 @@
 #![feature(const_trait_impl)]
 #![feature(decl_macro)]
 #![feature(deref_patterns)]
-#![feature(dyn_star)]
 #![feature(explicit_tail_calls)]
 #![feature(gen_blocks)]
 #![feature(more_qualified_paths)]
@@ -596,7 +595,6 @@
         let _: dyn Send + 'static;
         let _: dyn 'static + Send;
         let _: dyn for<'a> Send;
-        let _: dyn* Send;
     }
     /// TyKind::ImplTrait
     const fn ty_impl_trait() {
diff --git a/tests/ui/unpretty/exhaustive.hir.stderr b/tests/ui/unpretty/exhaustive.hir.stderr
index ac8079a..aa411ce 100644
--- a/tests/ui/unpretty/exhaustive.hir.stderr
+++ b/tests/ui/unpretty/exhaustive.hir.stderr
@@ -1,17 +1,17 @@
 error[E0697]: closures cannot be static
-  --> $DIR/exhaustive.rs:210:9
+  --> $DIR/exhaustive.rs:209:9
    |
 LL |         static || value;
    |         ^^^^^^^^^
 
 error[E0697]: closures cannot be static
-  --> $DIR/exhaustive.rs:211:9
+  --> $DIR/exhaustive.rs:210:9
    |
 LL |         static move || value;
    |         ^^^^^^^^^^^^^^
 
 error[E0728]: `await` is only allowed inside `async` functions and blocks
-  --> $DIR/exhaustive.rs:240:13
+  --> $DIR/exhaustive.rs:239:13
    |
 LL |     fn expr_await() {
    |     --------------- this is not `async`
@@ -20,19 +20,19 @@
    |             ^^^^^ only allowed inside `async` functions and blocks
 
 error: in expressions, `_` can only be used on the left-hand side of an assignment
-  --> $DIR/exhaustive.rs:289:9
+  --> $DIR/exhaustive.rs:288:9
    |
 LL |         _;
    |         ^ `_` not allowed here
 
 error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
-  --> $DIR/exhaustive.rs:299:9
+  --> $DIR/exhaustive.rs:298:9
    |
 LL |         x::();
    |         ^^^^^ only `Fn` traits may use parentheses
 
 error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
-  --> $DIR/exhaustive.rs:300:9
+  --> $DIR/exhaustive.rs:299:9
    |
 LL |         x::(T, T) -> T;
    |         ^^^^^^^^^^^^^^ only `Fn` traits may use parentheses
@@ -44,31 +44,31 @@
    |
 
 error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
-  --> $DIR/exhaustive.rs:301:9
+  --> $DIR/exhaustive.rs:300:9
    |
 LL |         crate::() -> ()::expressions::() -> ()::expr_path;
    |         ^^^^^^^^^^^^^^^ only `Fn` traits may use parentheses
 
 error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
-  --> $DIR/exhaustive.rs:301:26
+  --> $DIR/exhaustive.rs:300:26
    |
 LL |         crate::() -> ()::expressions::() -> ()::expr_path;
    |                          ^^^^^^^^^^^^^^^^^^^^^ only `Fn` traits may use parentheses
 
 error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
-  --> $DIR/exhaustive.rs:304:9
+  --> $DIR/exhaustive.rs:303:9
    |
 LL |         core::()::marker::()::PhantomData;
    |         ^^^^^^^^ only `Fn` traits may use parentheses
 
 error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
-  --> $DIR/exhaustive.rs:304:19
+  --> $DIR/exhaustive.rs:303:19
    |
 LL |         core::()::marker::()::PhantomData;
    |                   ^^^^^^^^^^ only `Fn` traits may use parentheses
 
 error: `yield` can only be used in `#[coroutine]` closures, or `gen` blocks
-  --> $DIR/exhaustive.rs:391:9
+  --> $DIR/exhaustive.rs:390:9
    |
 LL |         yield;
    |         ^^^^^
@@ -79,7 +79,7 @@
    |     ++++++++++++
 
 error[E0703]: invalid ABI: found `C++`
-  --> $DIR/exhaustive.rs:471:23
+  --> $DIR/exhaustive.rs:470:23
    |
 LL |         unsafe extern "C++" {}
    |                       ^^^^^ invalid ABI
@@ -87,7 +87,7 @@
    = note: invoke `rustc --print=calling-conventions` for a full list of supported calling conventions
 
 error: `..` patterns are not allowed here
-  --> $DIR/exhaustive.rs:678:13
+  --> $DIR/exhaustive.rs:677:13
    |
 LL |         let ..;
    |             ^^
@@ -95,13 +95,13 @@
    = note: only allowed in tuple, tuple struct, and slice patterns
 
 error[E0214]: parenthesized type parameters may only be used with a `Fn` trait
-  --> $DIR/exhaustive.rs:793:16
+  --> $DIR/exhaustive.rs:792:16
    |
 LL |         let _: T() -> !;
    |                ^^^^^^^^ only `Fn` traits may use parentheses
 
 error[E0562]: `impl Trait` is not allowed in the type of variable bindings
-  --> $DIR/exhaustive.rs:808:16
+  --> $DIR/exhaustive.rs:806:16
    |
 LL |         let _: impl Send;
    |                ^^^^^^^^^
@@ -112,7 +112,7 @@
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0562]: `impl Trait` is not allowed in the type of variable bindings
-  --> $DIR/exhaustive.rs:809:16
+  --> $DIR/exhaustive.rs:807:16
    |
 LL |         let _: impl Send + 'static;
    |                ^^^^^^^^^^^^^^^^^^^
@@ -123,7 +123,7 @@
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0562]: `impl Trait` is not allowed in the type of variable bindings
-  --> $DIR/exhaustive.rs:810:16
+  --> $DIR/exhaustive.rs:808:16
    |
 LL |         let _: impl 'static + Send;
    |                ^^^^^^^^^^^^^^^^^^^
@@ -134,7 +134,7 @@
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0562]: `impl Trait` is not allowed in the type of variable bindings
-  --> $DIR/exhaustive.rs:811:16
+  --> $DIR/exhaustive.rs:809:16
    |
 LL |         let _: impl ?Sized;
    |                ^^^^^^^^^^^
@@ -145,7 +145,7 @@
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0562]: `impl Trait` is not allowed in the type of variable bindings
-  --> $DIR/exhaustive.rs:812:16
+  --> $DIR/exhaustive.rs:810:16
    |
 LL |         let _: impl [const] Clone;
    |                ^^^^^^^^^^^^^^^^^^
@@ -156,7 +156,7 @@
    = note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
 
 error[E0562]: `impl Trait` is not allowed in the type of variable bindings
-  --> $DIR/exhaustive.rs:813:16
+  --> $DIR/exhaustive.rs:811:16
    |
 LL |         let _: impl for<'a> Send;
    |                ^^^^^^^^^^^^^^^^^
diff --git a/tests/ui/unpretty/exhaustive.hir.stdout b/tests/ui/unpretty/exhaustive.hir.stdout
index 2d347ec..2b8f3b2 100644
--- a/tests/ui/unpretty/exhaustive.hir.stdout
+++ b/tests/ui/unpretty/exhaustive.hir.stdout
@@ -14,7 +14,6 @@
 #![feature(const_trait_impl)]
 #![feature(decl_macro)]
 #![feature(deref_patterns)]
-#![feature(dyn_star)]
 #![feature(explicit_tail_calls)]
 #![feature(gen_blocks)]
 #![feature(more_qualified_paths)]
@@ -661,7 +660,6 @@
         let _: dyn Send + 'static;
         let _: dyn Send + 'static;
         let _: dyn for<'a> Send;
-        let _: dyn* Send;
     }
     /// TyKind::ImplTrait
     const fn ty_impl_trait() {
diff --git a/tests/ui/unpretty/exhaustive.rs b/tests/ui/unpretty/exhaustive.rs
index 5bf1118..5292dda 100644
--- a/tests/ui/unpretty/exhaustive.rs
+++ b/tests/ui/unpretty/exhaustive.rs
@@ -14,7 +14,6 @@
 #![feature(const_trait_impl)]
 #![feature(decl_macro)]
 #![feature(deref_patterns)]
-#![feature(dyn_star)]
 #![feature(explicit_tail_calls)]
 #![feature(gen_blocks)]
 #![feature(more_qualified_paths)]
@@ -800,7 +799,6 @@ fn ty_trait_object() {
         let _: dyn Send + 'static;
         let _: dyn 'static + Send;
         let _: dyn for<'a> Send;
-        let _: dyn* Send;
     }
 
     /// TyKind::ImplTrait
diff --git a/tests/ui/unsized-locals/yote.stderr b/tests/ui/unsized-locals/yote.stderr
index 8e7da64..f08a0b4a 100644
--- a/tests/ui/unsized-locals/yote.stderr
+++ b/tests/ui/unsized-locals/yote.stderr
@@ -4,7 +4,7 @@
 LL | #![feature(unsized_locals)]
    |            ^^^^^^^^^^^^^^ feature has been removed
    |
-   = note: removed in CURRENT_RUSTC_VERSION
+   = note: removed in 1.89.0
    = note: removed due to implementation concerns; see https://github.com/rust-lang/rust/issues/111942
 
 error: aborting due to 1 previous error
diff --git a/tests/ui/unsized/unsized-trait-impl-self-type.stderr b/tests/ui/unsized/unsized-trait-impl-self-type.stderr
index 3b68419..61165d4 100644
--- a/tests/ui/unsized/unsized-trait-impl-self-type.stderr
+++ b/tests/ui/unsized/unsized-trait-impl-self-type.stderr
@@ -1,3 +1,12 @@
+error[E0046]: not all trait items implemented, missing: `foo`
+  --> $DIR/unsized-trait-impl-self-type.rs:10:1
+   |
+LL |     fn foo(&self, z: &Z);
+   |     --------------------- `foo` from trait
+...
+LL | impl<X: ?Sized> T3<X> for S5<X> {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `foo` in implementation
+
 error[E0277]: the size for values of type `X` cannot be known at compilation time
   --> $DIR/unsized-trait-impl-self-type.rs:10:27
    |
@@ -24,15 +33,6 @@
 LL + impl<X> T3<X> for S5<X> {
    |
 
-error[E0046]: not all trait items implemented, missing: `foo`
-  --> $DIR/unsized-trait-impl-self-type.rs:10:1
-   |
-LL |     fn foo(&self, z: &Z);
-   |     --------------------- `foo` from trait
-...
-LL | impl<X: ?Sized> T3<X> for S5<X> {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `foo` in implementation
-
 error: aborting due to 2 previous errors
 
 Some errors have detailed explanations: E0046, E0277.
diff --git a/tests/ui/unsized/unsized-trait-impl-trait-arg.stderr b/tests/ui/unsized/unsized-trait-impl-trait-arg.stderr
index 79fc956..f46a6f6 100644
--- a/tests/ui/unsized/unsized-trait-impl-trait-arg.stderr
+++ b/tests/ui/unsized/unsized-trait-impl-trait-arg.stderr
@@ -1,3 +1,12 @@
+error[E0046]: not all trait items implemented, missing: `foo`
+  --> $DIR/unsized-trait-impl-trait-arg.rs:8:1
+   |
+LL |     fn foo(&self, z: Z);
+   |     -------------------- `foo` from trait
+...
+LL | impl<X: ?Sized> T2<X> for S4<X> {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `foo` in implementation
+
 error[E0277]: the size for values of type `X` cannot be known at compilation time
   --> $DIR/unsized-trait-impl-trait-arg.rs:8:17
    |
@@ -21,15 +30,6 @@
 LL | trait T2<Z: ?Sized> {
    |           ++++++++
 
-error[E0046]: not all trait items implemented, missing: `foo`
-  --> $DIR/unsized-trait-impl-trait-arg.rs:8:1
-   |
-LL |     fn foo(&self, z: Z);
-   |     -------------------- `foo` from trait
-...
-LL | impl<X: ?Sized> T2<X> for S4<X> {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `foo` in implementation
-
 error: aborting due to 2 previous errors
 
 Some errors have detailed explanations: E0046, E0277.
diff --git a/tests/ui/unsized/unsized7.stderr b/tests/ui/unsized/unsized7.stderr
index 6e9c052..2e65c8c 100644
--- a/tests/ui/unsized/unsized7.stderr
+++ b/tests/ui/unsized/unsized7.stderr
@@ -1,3 +1,12 @@
+error[E0046]: not all trait items implemented, missing: `dummy`
+  --> $DIR/unsized7.rs:12:1
+   |
+LL |     fn dummy(&self) -> Z;
+   |     --------------------- `dummy` from trait
+...
+LL | impl<X: ?Sized + T> T1<X> for S3<X> {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `dummy` in implementation
+
 error[E0277]: the size for values of type `X` cannot be known at compilation time
   --> $DIR/unsized7.rs:12:21
    |
@@ -21,15 +30,6 @@
 LL | trait T1<Z: T + ?Sized> {
    |               ++++++++
 
-error[E0046]: not all trait items implemented, missing: `dummy`
-  --> $DIR/unsized7.rs:12:1
-   |
-LL |     fn dummy(&self) -> Z;
-   |     --------------------- `dummy` from trait
-...
-LL | impl<X: ?Sized + T> T1<X> for S3<X> {
-   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `dummy` in implementation
-
 error: aborting due to 2 previous errors
 
 Some errors have detailed explanations: E0046, E0277.
diff --git a/tests/ui/variance/variance-regions-unused-indirect.stderr b/tests/ui/variance/variance-regions-unused-indirect.stderr
index 8cdbb3c..f942c51 100644
--- a/tests/ui/variance/variance-regions-unused-indirect.stderr
+++ b/tests/ui/variance/variance-regions-unused-indirect.stderr
@@ -1,3 +1,11 @@
+error[E0392]: lifetime parameter `'a` is never used
+  --> $DIR/variance-regions-unused-indirect.rs:3:10
+   |
+LL | enum Foo<'a> {
+   |          ^^ unused lifetime parameter
+   |
+   = help: consider removing `'a`, referring to it in a field, or using a marker such as `PhantomData`
+
 error[E0072]: recursive types `Foo` and `Bar` have infinite size
   --> $DIR/variance-regions-unused-indirect.rs:3:1
    |
@@ -22,14 +30,6 @@
    |
 
 error[E0392]: lifetime parameter `'a` is never used
-  --> $DIR/variance-regions-unused-indirect.rs:3:10
-   |
-LL | enum Foo<'a> {
-   |          ^^ unused lifetime parameter
-   |
-   = help: consider removing `'a`, referring to it in a field, or using a marker such as `PhantomData`
-
-error[E0392]: lifetime parameter `'a` is never used
   --> $DIR/variance-regions-unused-indirect.rs:8:10
    |
 LL | enum Bar<'a> {
diff --git a/tests/ui/wf/hir-wf-check-erase-regions.stderr b/tests/ui/wf/hir-wf-check-erase-regions.stderr
index e4d48bf..07304cd 100644
--- a/tests/ui/wf/hir-wf-check-erase-regions.stderr
+++ b/tests/ui/wf/hir-wf-check-erase-regions.stderr
@@ -11,10 +11,10 @@
   --> $SRC_DIR/core/src/iter/traits/collect.rs:LL:COL
 
 error[E0277]: `&'a T` is not an iterator
-  --> $DIR/hir-wf-check-erase-regions.rs:7:21
+  --> $DIR/hir-wf-check-erase-regions.rs:7:5
    |
 LL |     type IntoIter = std::iter::Flatten<std::slice::Iter<'a, T>>;
-   |                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `&'a T` is not an iterator
+   |     ^^^^^^^^^^^^^ `&'a T` is not an iterator
    |
    = help: the trait `Iterator` is not implemented for `&'a T`
    = help: the trait `Iterator` is implemented for `&mut I`
diff --git a/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122199.stderr b/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122199.stderr
index e10bb98..dc5a1cf 100644
--- a/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122199.stderr
+++ b/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122199.stderr
@@ -32,7 +32,7 @@
    |                          ^^^^^
    |
    = note: ...which immediately requires computing type of `Trait::N` again
-note: cycle used when computing explicit predicates of trait `Trait`
+note: cycle used when checking that `Trait` is well-formed
   --> $DIR/ice-hir-wf-check-anon-const-issue-122199.rs:1:1
    |
 LL | trait Trait<const N: dyn Trait = bar> {
diff --git a/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122989.stderr b/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122989.stderr
index a381f2a..a99728f 100644
--- a/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122989.stderr
+++ b/tests/ui/wf/ice-hir-wf-check-anon-const-issue-122989.stderr
@@ -37,7 +37,7 @@
 LL | trait Bar<const M: Foo<2>> {}
    |           ^^^^^^^^^^^^^^^
    = note: ...which again requires computing type of `Foo::N`, completing the cycle
-note: cycle used when computing explicit predicates of trait `Foo`
+note: cycle used when checking that `Foo` is well-formed
   --> $DIR/ice-hir-wf-check-anon-const-issue-122989.rs:2:1
    |
 LL | trait Foo<const N: Bar<2>> {
@@ -56,7 +56,7 @@
 LL | trait Bar<const M: Foo<2>> {}
    |           ^^^^^^^^^^^^^^^
    = note: ...which again requires computing type of `Foo::N`, completing the cycle
-note: cycle used when computing explicit predicates of trait `Foo`
+note: cycle used when checking that `Foo` is well-formed
   --> $DIR/ice-hir-wf-check-anon-const-issue-122989.rs:2:1
    |
 LL | trait Foo<const N: Bar<2>> {
diff --git a/tests/ui/wf/wf-impl-associated-type-region.stderr b/tests/ui/wf/wf-impl-associated-type-region.stderr
index f17d334..86e35b8 100644
--- a/tests/ui/wf/wf-impl-associated-type-region.stderr
+++ b/tests/ui/wf/wf-impl-associated-type-region.stderr
@@ -1,10 +1,10 @@
 error[E0309]: the parameter type `T` may not live long enough
-  --> $DIR/wf-impl-associated-type-region.rs:10:16
+  --> $DIR/wf-impl-associated-type-region.rs:10:5
    |
 LL | impl<'a, T> Foo<'a> for T {
    |      -- the parameter type `T` must be valid for the lifetime `'a` as defined here...
 LL |     type Bar = &'a T;
-   |                ^^^^^ ...so that the reference type `&'a T` does not outlive the data it points at
+   |     ^^^^^^^^ ...so that the reference type `&'a T` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |
diff --git a/tests/ui/wf/wf-outlives-ty-in-fn-or-trait.stderr b/tests/ui/wf/wf-outlives-ty-in-fn-or-trait.stderr
index e0cf42f..f2989ae 100644
--- a/tests/ui/wf/wf-outlives-ty-in-fn-or-trait.stderr
+++ b/tests/ui/wf/wf-outlives-ty-in-fn-or-trait.stderr
@@ -1,10 +1,10 @@
 error[E0309]: the parameter type `T` may not live long enough
-  --> $DIR/wf-outlives-ty-in-fn-or-trait.rs:9:16
+  --> $DIR/wf-outlives-ty-in-fn-or-trait.rs:9:5
    |
 LL | impl<'a, T> Trait<'a, T> for usize {
    |      -- the parameter type `T` must be valid for the lifetime `'a` as defined here...
 LL |     type Out = &'a fn(T);
-   |                ^^^^^^^^^ ...so that the reference type `&'a fn(T)` does not outlive the data it points at
+   |     ^^^^^^^^ ...so that the reference type `&'a fn(T)` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |
@@ -12,12 +12,12 @@
    |           ++++
 
 error[E0309]: the parameter type `T` may not live long enough
-  --> $DIR/wf-outlives-ty-in-fn-or-trait.rs:19:16
+  --> $DIR/wf-outlives-ty-in-fn-or-trait.rs:19:5
    |
 LL | impl<'a, T> Trait<'a, T> for u32 {
    |      -- the parameter type `T` must be valid for the lifetime `'a` as defined here...
 LL |     type Out = &'a dyn Baz<T>;
-   |                ^^^^^^^^^^^^^^ ...so that the reference type `&'a (dyn Baz<T> + 'a)` does not outlive the data it points at
+   |     ^^^^^^^^ ...so that the reference type `&'a (dyn Baz<T> + 'a)` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |
diff --git a/tests/ui/wf/wf-trait-associated-type-region.stderr b/tests/ui/wf/wf-trait-associated-type-region.stderr
index d6647b2..9589e1d 100644
--- a/tests/ui/wf/wf-trait-associated-type-region.stderr
+++ b/tests/ui/wf/wf-trait-associated-type-region.stderr
@@ -1,11 +1,11 @@
 error[E0309]: the associated type `<Self as SomeTrait<'a>>::Type1` may not live long enough
-  --> $DIR/wf-trait-associated-type-region.rs:9:18
+  --> $DIR/wf-trait-associated-type-region.rs:9:5
    |
 LL | trait SomeTrait<'a> {
    |                 -- the associated type `<Self as SomeTrait<'a>>::Type1` must be valid for the lifetime `'a` as defined here...
 LL |     type Type1;
 LL |     type Type2 = &'a Self::Type1;
-   |                  ^^^^^^^^^^^^^^^ ...so that the reference type `&'a <Self as SomeTrait<'a>>::Type1` does not outlive the data it points at
+   |     ^^^^^^^^^^ ...so that the reference type `&'a <Self as SomeTrait<'a>>::Type1` does not outlive the data it points at
    |
 help: consider adding an explicit lifetime bound
    |