diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2024-01-16 16:14:33 +1100 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2024-01-23 08:09:01 +1100 |
| commit | cfdea760f5ca36fdd04c8f18f3dac0bef66055cc (patch) | |
| tree | 4daba05dce1c25b379bec55475f47998984e910e /compiler/rustc_trait_selection/src/traits | |
| parent | 681b9aa363d350a4b8ecb9eedc025baa6e0bf9ca (diff) | |
| download | rust-cfdea760f5ca36fdd04c8f18f3dac0bef66055cc.tar.gz rust-cfdea760f5ca36fdd04c8f18f3dac0bef66055cc.zip | |
Rename `TyCtxt::struct_span_lint_hir` as `TyCtxt::node_span_lint`.
Diffstat (limited to 'compiler/rustc_trait_selection/src/traits')
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/object_safety.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/specialize/mod.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/object_safety.rs b/compiler/rustc_trait_selection/src/traits/object_safety.rs index 6e68dee76a2..3289dfe343e 100644 --- a/compiler/rustc_trait_selection/src/traits/object_safety.rs +++ b/compiler/rustc_trait_selection/src/traits/object_safety.rs @@ -161,7 +161,7 @@ fn lint_object_unsafe_trait( ) { // Using `CRATE_NODE_ID` is wrong, but it's hard to get a more precise id. // It's also hard to get a use site span, so we use the method definition span. - tcx.struct_span_lint_hir( + tcx.node_span_lint( WHERE_CLAUSES_OBJECT_SAFETY, hir::CRATE_HIR_ID, span, diff --git a/compiler/rustc_trait_selection/src/traits/specialize/mod.rs b/compiler/rustc_trait_selection/src/traits/specialize/mod.rs index 910fc0ee314..bfc6937a3eb 100644 --- a/compiler/rustc_trait_selection/src/traits/specialize/mod.rs +++ b/compiler/rustc_trait_selection/src/traits/specialize/mod.rs @@ -462,7 +462,7 @@ fn report_conflicting_impls<'tcx>( FutureCompatOverlapErrorKind::Issue33140 => ORDER_DEPENDENT_TRAIT_OBJECTS, FutureCompatOverlapErrorKind::LeakCheck => COHERENCE_LEAK_CHECK, }; - tcx.struct_span_lint_hir( + tcx.node_span_lint( lint, tcx.local_def_id_to_hir_id(impl_def_id), impl_span, |
