rustc_trait_selection::traits::query::type_op::custom

Function scrape_region_constraints

Source
pub fn scrape_region_constraints<'tcx, Op, R>(
    infcx: &InferCtxt<'tcx>,
    op: impl FnOnce(&ObligationCtxt<'_, 'tcx>) -> Result<R, NoSolution>,
    name: &'static str,
    span: Span,
) -> Result<(TypeOpOutput<'tcx, Op>, RegionConstraintData<'tcx>), ErrorGuaranteed>
where R: TypeFoldable<TyCtxt<'tcx>>, Op: TypeOp<'tcx, Output = R>,
Expand description

Executes op and then scrapes out all the “old style” region constraints that result, creating query-region-constraints.