clippy_utils

Function pat_is_wild

Source
pub fn pat_is_wild<'tcx>(
    cx: &LateContext<'tcx>,
    pat: &'tcx PatKind<'_>,
    body: impl Visitable<'tcx>,
) -> bool
Expand description

Returns true if the pattern is a PatWild, or is an ident prefixed with _ that is not locally used.