pub fn scan_mir(tcx: TyCtxt<'_>, def_id: DefId) -> Option<UnsafeRoot>Expand description
Full MIR-level detection: scan the function body for all unsafe operations.
Returns None if the function has no unsafe callees, no raw pointer
dereferences, and no static mutable accesses.