Skip to main content

char_byte_offsets

Function char_byte_offsets 

Source
pub fn char_byte_offsets(text: &str) -> Vec<usize>
Expand description

The UTF-8 byte offset of each character of text, plus one for its end, so a range counted in characters becomes the byte range Hammer expects.