File tree 1 file changed +4
-6
lines changed
compiler/rustc_middle/src/query
1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -442,12 +442,10 @@ rustc_queries! {
442
442
desc { |tcx| "computing the super traits of `{}`" , tcx. def_path_str( key) }
443
443
}
444
444
445
- /// Maps from the `DefId` of a trait to the list of
446
- /// super-predicates. This is a subset of the full list of
447
- /// predicates. We store these in a separate map because we must
448
- /// evaluate them even during type conversion, often before the
449
- /// full predicates are available (note that supertraits have
450
- /// additional acyclicity requirements).
445
+ /// The `Option<Ident>` is the name of an associated type. If it is `None`, then this query
446
+ /// returns the full set of predicates. If `Some<Ident>`, then the query returns only the
447
+ /// subset of super-predicates that reference traits that define the given associated type.
448
+ /// This is used to avoid cycles in resolving types like `T::Item`.
451
449
query super_predicates_that_define_assoc_type( key: ( DefId , Option <rustc_span:: symbol:: Ident >) ) -> ty:: GenericPredicates <' tcx> {
452
450
desc { |tcx| "computing the super traits of `{}`{}" ,
453
451
tcx. def_path_str( key. 0 ) ,
You can’t perform that action at this time.
0 commit comments