clippy_utils::hir_utils

Function count_eq

Source
pub fn count_eq<X: Sized>(
    left: &mut dyn Iterator<Item = X>,
    right: &mut dyn Iterator<Item = X>,
    eq_fn: impl FnMut(&X, &X) -> bool,
) -> usize
Expand description

Counts how many elements of the slices are equal as per eq_fn.