Expand description
Generic crate-internal routines for the memchr
family of functions.
Structsยง
- Iter ๐
- An iterator over all occurrences of a set of bytes in a haystack.
- One ๐
- Finds all occurrences of a single byte in a haystack.
- Three ๐
- Finds all occurrences of two bytes in a haystack.
- Two ๐
- Finds all occurrences of two bytes in a haystack.
Functionsยง
- count_
byte_ ๐ โby_ byte - Performs a forward byte-at-a-time loop until
ptr >= end_ptr
and returns the number of timesconfirm(*ptr)
returnstrue
. - fwd_
byte_ ๐ โby_ byte - Performs a forward byte-at-a-time loop until either
ptr >= end_ptr
or untilconfirm(*ptr)
returnstrue
. If the former occurs, thenNone
is returned. If the latter occurs, then the pointer at whichconfirm
returnstrue
is returned. - rev_
byte_ ๐ โby_ byte - Performs a reverse byte-at-a-time loop until either
ptr < start_ptr
or untilconfirm(*ptr)
returnstrue
. If the former occurs, thenNone
is returned. If the latter occurs, then the pointer at whichconfirm
returnstrue
is returned. - search_
slice_ ๐ โwith_ raw - Search a slice using a function that operates on raw pointers.