X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=compiler%2Frustc_middle%2Fsrc%2Fty%2Fstructural_impls.rs;h=934d97d00e8460ee502b3e9df1b2c13c79f44885;hb=8278314a8bf76c9d56072d294ee1d5ba76551cb6;hp=8af5792b3fb68b4be7f7a330b299cfc38dfe2290;hpb=ea6cc5aab5bec6fd48783b7d6ba08688b8497ca6;p=rust.git diff --git a/compiler/rustc_middle/src/ty/structural_impls.rs b/compiler/rustc_middle/src/ty/structural_impls.rs index 8af5792b3fb..934d97d00e8 100644 --- a/compiler/rustc_middle/src/ty/structural_impls.rs +++ b/compiler/rustc_middle/src/ty/structural_impls.rs @@ -65,7 +65,7 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { } } -impl fmt::Debug for ty::BoundRegion { +impl fmt::Debug for ty::BoundRegionKind { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { match *self { ty::BrAnon(n) => write!(f, "BrAnon({:?})", n), @@ -232,7 +232,6 @@ impl fmt::Debug for ty::PredicateKind<'tcx> { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { match *self { ty::PredicateKind::ForAll(binder) => write!(f, "ForAll({:?})", binder), - ty::PredicateKind::Atom(atom) => write!(f, "{:?}", atom), } } } @@ -308,13 +307,13 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { crate::traits::Reveal, crate::ty::adjustment::AutoBorrowMutability, crate::ty::AdtKind, - // Including `BoundRegion` is a *bit* dubious, but direct + // Including `BoundRegionKind` is a *bit* dubious, but direct // references to bound region appear in `ty::Error`, and aren't // really meant to be folded. In general, we can only fold a fully // general `Region`. - crate::ty::BoundRegion, + crate::ty::BoundRegionKind, crate::ty::AssocItem, - crate::ty::Placeholder, + crate::ty::Placeholder, crate::ty::ClosureKind, crate::ty::FreeRegion, crate::ty::InferTy, @@ -486,7 +485,6 @@ impl<'a, 'tcx> Lift<'tcx> for ty::PredicateKind<'a> { fn lift_to_tcx(self, tcx: TyCtxt<'tcx>) -> Option { match self { ty::PredicateKind::ForAll(binder) => tcx.lift(binder).map(ty::PredicateKind::ForAll), - ty::PredicateKind::Atom(atom) => tcx.lift(atom).map(ty::PredicateKind::Atom), } } }