pub fn runs_are_valid(text: &str, runs: &[TextRun]) -> Result<(), String>Expand description
Are these runs well formed for text: ascending, non-overlapping, inside the string, and on
character boundaries?
Checked once in the pieces layer rather than in eight backends. A backend handed overlapping
ranges would produce a different wrong answer per platform, and a range splitting a multi-byte
character would panic on str slicing in some and render mojibake in others.