]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_infer/src/infer/opaque_types.rs
Add bound_explicit_item_bounds and bound_item_bounds
[rust.git] / compiler / rustc_infer / src / infer / opaque_types.rs
index d25484efabc5fd613c1eb76817ab68855008177a..92c0ed84057a6f572478c1669860963ca6c1256f 100644 (file)
@@ -561,9 +561,9 @@ pub fn register_hidden_type(
             obligations = self.at(&cause, param_env).eq(prev, hidden_ty)?.obligations;
         }
 
-        let item_bounds = tcx.explicit_item_bounds(def_id);
+        let item_bounds = tcx.bound_explicit_item_bounds(def_id);
 
-        for (predicate, _) in item_bounds {
+        for predicate in item_bounds.transpose_iter().map(|e| e.map_bound(|(p, _)| *p)) {
             debug!(?predicate);
             let predicate = predicate.subst(tcx, substs);