about summary refs log tree commit diff
path: root/compiler/rustc_middle/src
diff options
context:
space:
mode:
authorJack Huey <jack.huey@umassmed.edu>2021-01-07 00:41:55 -0500
committerJack Huey <jack.huey@umassmed.edu>2021-03-31 10:05:32 -0400
commit4955d755d3ffdfecfd2c22139c65fe1a10d60939 (patch)
tree4dedeed4ed4c636d226c13752898ee548d8b4c56 /compiler/rustc_middle/src
parenta5029ac0ab372aec515db2e718da6d7787f3d122 (diff)
downloadrust-4955d755d3ffdfecfd2c22139c65fe1a10d60939.tar.gz
rust-4955d755d3ffdfecfd2c22139c65fe1a10d60939.zip
Some rebinds and dummys
Diffstat (limited to 'compiler/rustc_middle/src')
-rw-r--r--compiler/rustc_middle/src/ty/relate.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/compiler/rustc_middle/src/ty/relate.rs b/compiler/rustc_middle/src/ty/relate.rs
index e2bbb31263a..76ba07864cf 100644
--- a/compiler/rustc_middle/src/ty/relate.rs
+++ b/compiler/rustc_middle/src/ty/relate.rs
@@ -619,10 +619,9 @@ impl<'tcx> Relate<'tcx> for &'tcx ty::List<ty::Binder<ty::ExistentialPredicate<'
         let v = iter::zip(a_v, b_v).map(|(ep_a, ep_b)| {
             use crate::ty::ExistentialPredicate::*;
             match (ep_a.skip_binder(), ep_b.skip_binder()) {
-                (Trait(a), Trait(b)) => Ok(ty::Binder::bind(Trait(
-                    relation.relate(ep_a.rebind(a), ep_b.rebind(b))?.skip_binder(),
-                ))),
-                (Projection(a), Projection(b)) => Ok(ty::Binder::bind(Projection(
+                (Trait(a), Trait(b)) => Ok(ep_a
+                    .rebind(Trait(relation.relate(ep_a.rebind(a), ep_b.rebind(b))?.skip_binder()))),
+                (Projection(a), Projection(b)) => Ok(ep_a.rebind(Projection(
                     relation.relate(ep_a.rebind(a), ep_b.rebind(b))?.skip_binder(),
                 ))),
                 (AutoTrait(a), AutoTrait(b)) if a == b => Ok(ep_a.rebind(AutoTrait(a))),