about summary refs log tree commit diff
path: root/compiler/rustc_query_impl/src/keys.rs
diff options
context:
space:
mode:
authorlcnr <rust@lcnr.de>2021-07-19 13:52:43 +0200
committerlcnr <rust@lcnr.de>2021-08-26 11:00:30 +0200
commitcaa975c89e343cb7e51f77c2710c8460ada50532 (patch)
tree7d5c957eb1d942180608f4ebe0bcfb648ec3cf11 /compiler/rustc_query_impl/src/keys.rs
parent031243898eaa138056ea7248fb37324ffaa561e1 (diff)
downloadrust-caa975c89e343cb7e51f77c2710c8460ada50532.tar.gz
rust-caa975c89e343cb7e51f77c2710c8460ada50532.zip
use `ty::Unevaluated` instead of def substs pair
Diffstat (limited to 'compiler/rustc_query_impl/src/keys.rs')
-rw-r--r--compiler/rustc_query_impl/src/keys.rs11
1 files changed, 3 insertions, 8 deletions
diff --git a/compiler/rustc_query_impl/src/keys.rs b/compiler/rustc_query_impl/src/keys.rs
index 38ab26d66ac..8523737f8db 100644
--- a/compiler/rustc_query_impl/src/keys.rs
+++ b/compiler/rustc_query_impl/src/keys.rs
@@ -217,18 +217,13 @@ impl<'tcx> Key for (DefId, SubstsRef<'tcx>) {
     }
 }
 
-impl<'tcx> Key
-    for (
-        (ty::WithOptConstParam<DefId>, SubstsRef<'tcx>),
-        (ty::WithOptConstParam<DefId>, SubstsRef<'tcx>),
-    )
-{
+impl<'tcx> Key for (ty::Unevaluated<'tcx>, ty::Unevaluated<'tcx>) {
     #[inline(always)]
     fn query_crate_is_local(&self) -> bool {
-        (self.0).0.did.krate == LOCAL_CRATE
+        (self.0).def.did.krate == LOCAL_CRATE
     }
     fn default_span(&self, tcx: TyCtxt<'_>) -> Span {
-        (self.0).0.did.default_span(tcx)
+        (self.0).def.did.default_span(tcx)
     }
 }