Skip to main content

resolve_param_origin

Function resolve_param_origin 

Source
pub(super) fn resolve_param_origin(
    tcx: TyCtxt<'_>,
    caller: DefId,
    origin: &PlaceKey,
) -> Option<usize>
Expand description

Resolve origin to a parameter MIR local, tracing through local-copy origins when the base is not itself a parameter.

Returns a 1-based MIR local index (usable directly with Local::from_usize), or None when the origin does not trace back to a parameter.