rustc_lint::non_local_def

Function did_has_local_parent

source
fn did_has_local_parent(
    did: DefId,
    tcx: TyCtxt<'_>,
    impl_parent: DefId,
    outermost_impl_parent: Option<DefId>,
) -> bool
Expand description

Given a def id this checks if the parent def id (modulo modules) correspond to the def id of the parent impl definition (the direct one and the outermost one).