[−][src]Function serial_unit_testing::utils::byte_position_of_char
pub fn byte_position_of_char(str: &String, index: usize) -> Option<usize>
Get the starting position of a character in a string.
When working with unicode characters a character can span multiple bytes and thus the offset of characters is not the same as the number of bytes.