pub fn count_changes(src: &[u8], dst: &[u8]) -> (usize, usize)Expand description
Sum, over every hash present in both maps, the smaller of the two byte
counts. This is git’s src_copied: the number of bytes that appear on both
sides (counting multiplicity via the per-hash byte totals).
git diffcore_count_changes(): span-hash byte accounting between two
blobs. Returns (src_copied, literal_added) — the bytes of src that
survive into dst, and the bytes of dst not accounted for by src.
--dirstat’s default “changes” damage is
(src.len() - src_copied) + literal_added.