fn check_explicit_predicates<'tcx>(
tcx: TyCtxt<'tcx>,
def_id: DefId,
args: &[GenericArg<'tcx>],
required_predicates: &mut FxIndexMap<OutlivesPredicate<'tcx, GenericArg<'tcx>>, Span>,
explicit_map: &mut ExplicitPredicatesMap<'tcx>,
ignored_self_ty: Option<Ty<'tcx>>,
)
Expand description
Check the explicit predicates declared on the type.
§Example
ⓘ
struct Outer<'a, T> {
field: Inner<T>,
}
struct Inner<U> where U: 'static, U: Outer {
// ...
}
Here, we should fetch the explicit predicates, which
will give us U: 'static
and U: Outer
. The latter we
can ignore, but we will want to process U: 'static
,
applying the instantiation as above.