fn is_registry(tcx: TyCtxt<'_>, def_id: DefId) -> bool
Whether def_id is defined in a crate from crates.io or a git dependency, rather than in the user’s workspace or a path dependency.
def_id