Function clippy_utils::visitors::expr_visitor
source · pub fn expr_visitor<'tcx>(
cx: &LateContext<'tcx>,
f: impl FnMut(&'tcx Expr<'tcx>) -> bool
) -> impl Visitor<'tcx>
Expand description
Convenience method for creating a Visitor
with just visit_expr
overridden and nested
bodies (i.e. closures) are visited.
If the callback returns true
, the expr just provided to the callback is walked.