Function rustc_trait_selection::traits::wf::trait_obligations

source ·
pub fn trait_obligations<'tcx>(
    infcx: &InferCtxt<'tcx>,
    param_env: ParamEnv<'tcx>,
    body_id: LocalDefId,
    trait_pred: TraitPredicate<'tcx>,
    span: Span,
    item: &'tcx Item<'tcx>
) -> Vec<PredicateObligation<'tcx>>
Expand description

Returns the obligations that make this trait reference well-formed. For example, if there is a trait Set defined like trait Set<K: Eq>, then the trait bound Foo: Set<Bar> is WF if Bar: Eq.