diff options
| author | Santiago Pastorino <spastorino@gmail.com> | 2022-03-22 10:35:17 -0300 |
|---|---|---|
| committer | Santiago Pastorino <spastorino@gmail.com> | 2022-03-22 10:35:17 -0300 |
| commit | 64df2ee1eb3fb9eee420b13b48d59fdb5ae2c23d (patch) | |
| tree | a0a818b7c2e21c62b5ad2ed51ccdb2827d63d91a | |
| parent | 0cd03c917cd728844048edb41a3d30d414214ad8 (diff) | |
| download | rust-64df2ee1eb3fb9eee420b13b48d59fdb5ae2c23d.tar.gz rust-64df2ee1eb3fb9eee420b13b48d59fdb5ae2c23d.zip | |
impl_header -> impl_subject
| -rw-r--r-- | compiler/rustc_middle/src/hir/mod.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/coherence.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_middle/src/hir/mod.rs b/compiler/rustc_middle/src/hir/mod.rs index 4bc0d3a4d86..a9e22d16ee0 100644 --- a/compiler/rustc_middle/src/hir/mod.rs +++ b/compiler/rustc_middle/src/hir/mod.rs @@ -55,7 +55,7 @@ impl<'tcx> TyCtxt<'tcx> { self.parent_module_from_def_id(id.owner) } - pub fn impl_header(self, def_id: DefId) -> ImplSubject<'tcx> { + pub fn impl_subject(self, def_id: DefId) -> ImplSubject<'tcx> { self.impl_trait_ref(def_id) .map(ImplSubject::Trait) .unwrap_or_else(|| ImplSubject::Inherent(self.type_of(def_id))) diff --git a/compiler/rustc_trait_selection/src/traits/coherence.rs b/compiler/rustc_trait_selection/src/traits/coherence.rs index a0fbf94c01d..559401c0bd1 100644 --- a/compiler/rustc_trait_selection/src/traits/coherence.rs +++ b/compiler/rustc_trait_selection/src/traits/coherence.rs @@ -307,7 +307,7 @@ fn negative_impl<'cx, 'tcx>( // create a parameter environment corresponding to a (placeholder) instantiation of impl1 let impl1_env = tcx.param_env(impl1_def_id); - match tcx.impl_header(impl1_def_id) { + match tcx.impl_subject(impl1_def_id) { ImplSubject::Trait(impl1_trait_ref) => { // Normalize the trait reference. The WF rules ought to ensure // that this always succeeds. |
