Function stringzilla::sz::rfind_char_not_from
source · pub fn rfind_char_not_from<H, N>(haystack: H, needles: N) -> Option<usize>Expand description
Finds the index of the last character in haystack that is not present in needles.
Useful for text processing tasks such as trimming trailing characters that belong to
a specified set.
§Arguments
haystack: The byte slice to search.needles: The set of bytes that should not be matched within the haystack.
§Returns
An Option<usize> representing the index of the last occurrence of any byte not in
needles within haystack, if found, otherwise None.