diff options
| author | bors <bors@rust-lang.org> | 2025-07-28 16:38:15 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2025-07-28 16:38:15 +0000 |
| commit | e3514bde96d2d13586337a48db77fa64b850d249 (patch) | |
| tree | 4b7ae3db59d7fc366645a22c922598df2970357d /compiler/rustc_codegen_ssa/src | |
| parent | 9ba00e0f9e00990fb88c1beac7172afe93b15609 (diff) | |
| parent | cdcfdd1a1b3f267a98c693fc03b4411934b60674 (diff) | |
| download | rust-e3514bde96d2d13586337a48db77fa64b850d249.tar.gz rust-e3514bde96d2d13586337a48db77fa64b850d249.zip | |
Auto merge of #144377 - camsteffen:simplify-impl-of-method, r=fee1-dead
Rename impl_of_method and trait_of_item This PR used to tweak the implementation of impl_of_method, but that introduced a perf regression. Rename impl_of_method and trait_of_item to impl_of_assoc and trait_of_assoc respectively. This reflects how the two functions are closely related. And it reflects the behavior more accurately as the functions check whether the input is an associated item.
Diffstat (limited to 'compiler/rustc_codegen_ssa/src')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/back/symbol_export.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_ssa/src/back/symbol_export.rs b/compiler/rustc_codegen_ssa/src/back/symbol_export.rs index 2f5eca2d6b2..297bdec2bc2 100644 --- a/compiler/rustc_codegen_ssa/src/back/symbol_export.rs +++ b/compiler/rustc_codegen_ssa/src/back/symbol_export.rs @@ -86,7 +86,7 @@ fn reachable_non_generics_provider(tcx: TyCtxt<'_>, _: LocalCrate) -> DefIdMap<S // Only consider nodes that actually have exported symbols. match tcx.def_kind(def_id) { DefKind::Fn | DefKind::Static { .. } => {} - DefKind::AssocFn if tcx.impl_of_method(def_id.to_def_id()).is_some() => {} + DefKind::AssocFn if tcx.impl_of_assoc(def_id.to_def_id()).is_some() => {} _ => return None, }; |
