From f3b0a0e266172ee5e652033ff753fd4eb34f7fac Mon Sep 17 00:00:00 2001 From: aerooneqq Date: Mon, 18 May 2026 10:41:15 +0300 Subject: [PATCH] Comments cleanup --- compiler/rustc_incremental/src/persist/clean.rs | 2 +- compiler/rustc_interface/src/passes.rs | 2 +- compiler/rustc_middle/src/hir/map.rs | 2 +- compiler/rustc_middle/src/hir/mod.rs | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/compiler/rustc_incremental/src/persist/clean.rs b/compiler/rustc_incremental/src/persist/clean.rs index e33c07b64b16..800805551af6 100644 --- a/compiler/rustc_incremental/src/persist/clean.rs +++ b/compiler/rustc_incremental/src/persist/clean.rs @@ -54,7 +54,7 @@ /// DepNodes for Hir, which is pretty much everything const BASE_HIR: &[&str] = &[ - // owner should be computed for all nodes + // hir_owner should be computed for all nodes label_strs::hir_owner, ]; diff --git a/compiler/rustc_interface/src/passes.rs b/compiler/rustc_interface/src/passes.rs index 1c181031c94d..623fb4e2c6dd 100644 --- a/compiler/rustc_interface/src/passes.rs +++ b/compiler/rustc_interface/src/passes.rs @@ -879,7 +879,7 @@ pub fn write_interface<'tcx>(tcx: TyCtxt<'tcx>) { providers.queries.analysis = analysis; providers.queries.hir_crate = rustc_ast_lowering::lower_to_hir; providers.queries.lower_delayed_owner = rustc_ast_lowering::lower_delayed_owner; - // `delayed_owner` is fed during `lower_delayed_owner`, by default it returns phantom, + // `hir_delayed_owner` is fed during `lower_delayed_owner`, by default it returns phantom, // as if this query was not fed it means that `MaybeOwner` does not exist for provided LocalDefId. providers.queries.hir_delayed_owner = |_, _| MaybeOwner::Phantom; providers.queries.resolver_for_lowering_raw = resolver_for_lowering_raw; diff --git a/compiler/rustc_middle/src/hir/map.rs b/compiler/rustc_middle/src/hir/map.rs index 5bed43d124bd..232a4e6c2f77 100644 --- a/compiler/rustc_middle/src/hir/map.rs +++ b/compiler/rustc_middle/src/hir/map.rs @@ -112,7 +112,7 @@ pub fn local_def_id_to_hir_id(self, def_id: impl IntoQueryKey) -> Hi } } - /// This function is used only inside eval-always query analysis + /// This function is used only inside eval-always query `analysis` /// (`analysis -> run_required_analysis` -> `emit_delayed_lints`), so it is safe /// to obtain delayed lints from non-eval-always `owner` query. #[inline] diff --git a/compiler/rustc_middle/src/hir/mod.rs b/compiler/rustc_middle/src/hir/mod.rs index e0b3f75ef3ca..868bd139e714 100644 --- a/compiler/rustc_middle/src/hir/mod.rs +++ b/compiler/rustc_middle/src/hir/mod.rs @@ -452,7 +452,7 @@ pub struct Hashes { pub attrs_hash: Option, } -/// Unites some of `OwnerInfo`'s fields into same struct that is used by owner `query`. +/// Unites some of `OwnerInfo`'s fields into same struct that is used by `hir_owner` query. /// `AttributeMap` is handled separately as placing it in this struct led to perf regressions: /// . /// This struct is created mainly for uniting/splitting fields of `OwnerInfo` so they are