Function normalize_bound_val

Source
pub fn normalize_bound_val<'tcx, T>(
    tcx: TyCtxt<'tcx>,
    typing_env: TypingEnv<'tcx>,
    x: Binder<'tcx, T>,
) -> Binder<'tcx, T>
where T: TypeFoldable<TyCtxt<'tcx>> + Copy,
Expand description

Given our currently hacky handling of binders, in order for trait resolution to work we must empty out the binders of trait refs. Specifically it’s so that we can reconnect associated type constraints with the trait ref they come from, given that the projection in question doesn’t track the right binder currently.