# Function rustc_trait_selection::traits::util::impl_subject_and_oblig

source ·

    pub fn impl_subject_and_oblig<'a, 'tcx>(
        selcx: &SelectionContext<'a, 'tcx>,
        param_env: ParamEnv<'tcx>,
        impl_def_id: DefId,
        impl_args: GenericArgsRef<'tcx>,
        cause: impl Fn(usize, Span) -> ObligationCause<'tcx>
    ) -> (ImplSubject<'tcx>, impl Iterator<Item = PredicateObligation<'tcx>>)

Expand description

Instantiate all bound parameters of the impl subject with the given args, returning the resulting subject and all obligations that arise. The obligations are closed under normalization.