pub fn word_level_changed_ranges(
old: &str,
new: &str,
) -> (Vec<(usize, usize)>, Vec<(usize, usize)>)Expand description
Computes byte-safe word-level changed ranges for a line pair.
ยงContract
- Requires: nothing beyond valid
&strinputs. - Ensures: every returned range is a char-boundary range within its side,
and an empty input or an over-budget pair (
> 16_384bytes) yields no ranges. Overflow-free: offsets advance withsaturating_add. - Termination: single pass over
similarchanges.