about summary refs log tree commit diff
path: root/src/librustdoc
diff options
context:
space:
mode:
authorBryanskiy <ivakin.kir@gmail.com>2024-08-04 19:52:15 +0300
committerBryanskiy <ivakin.kir@gmail.com>2024-09-02 19:59:18 +0300
commitc51953f4d8618c9db6ef383a537814ee37977b58 (patch)
treef7e365d20faaa8cccc76b0375f60410d76776b30 /src/librustdoc
parent717aec0f8eebdc5eb51756e5129dde15e8b25710 (diff)
downloadrust-c51953f4d8618c9db6ef383a537814ee37977b58.tar.gz
rust-c51953f4d8618c9db6ef383a537814ee37977b58.zip
Use `DeepRejectCtxt` to quickly reject `ParamEnv` candidates
Diffstat (limited to 'src/librustdoc')
-rw-r--r--src/librustdoc/html/render/write_shared.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/librustdoc/html/render/write_shared.rs b/src/librustdoc/html/render/write_shared.rs
index a18b7a252a4..b68d7d8759c 100644
--- a/src/librustdoc/html/render/write_shared.rs
+++ b/src/librustdoc/html/render/write_shared.rs
@@ -29,7 +29,7 @@ use itertools::Itertools;
 use regex::Regex;
 use rustc_data_structures::flock;
 use rustc_data_structures::fx::{FxHashMap, FxHashSet};
-use rustc_middle::ty::fast_reject::{DeepRejectCtxt, TreatParams};
+use rustc_middle::ty::fast_reject::DeepRejectCtxt;
 use rustc_middle::ty::TyCtxt;
 use rustc_span::def_id::DefId;
 use rustc_span::Symbol;
@@ -826,7 +826,7 @@ impl<'cx, 'cache> DocVisitor for TypeImplCollector<'cx, 'cache> {
             // Be aware of `tests/rustdoc/type-alias/deeply-nested-112515.rs` which might regress.
             let Some(impl_did) = impl_item_id.as_def_id() else { continue };
             let for_ty = self.cx.tcx().type_of(impl_did).skip_binder();
-            let reject_cx = DeepRejectCtxt::new(self.cx.tcx(), TreatParams::AsCandidateKey);
+            let reject_cx = DeepRejectCtxt::relate_infer_infer(self.cx.tcx());
             if !reject_cx.types_may_unify(aliased_ty, for_ty) {
                 continue;
             }