This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
compiler/rustc_trait_selection/src Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -69,9 +69,15 @@ impl<'tcx> InferCtxt<'tcx> {
6969 /// .must_apply_modulo_regions();
7070 /// ```
7171 ///
72- /// In most cases you should instead create an [Obligation](traits::Obligation)
73- /// and check whether it holds, because it properly handles higher ranked traits
74- /// and it is more convenient and safer when your `params` are inside a `Binder`.
72+ /// In most cases you should instead create an [Obligation] and check whether
73+ /// it holds via [`evaluate_obligation`] or one of its helper functions like
74+ /// [`predicate_must_hold_modulo_regions`], because it properly handles higher ranked traits
75+ /// and it is more convenient and safer when your `params` are inside a [`Binder`].
76+ ///
77+ /// [Obligation]: traits::Obligation
78+ /// [`evaluate_obligation`]: crate::traits::query::evaluate_obligation::InferCtxtExt::evaluate_obligation
79+ /// [`predicate_must_hold_modulo_regions`]: crate::traits::query::evaluate_obligation::InferCtxtExt::predicate_must_hold_modulo_regions
80+ /// [`Binder`]: ty::Binder
7581 #[ instrument( level = "debug" , skip( self , params) , ret) ]
7682 fn type_implements_trait (
7783 & self ,
You can’t perform that action at this time.
0 commit comments