pub fn rtrim_char_count(slc: &[u8], c: u8) -> usize
Count the number of trailing characters equal to a given value.