File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ fn repeat_byte(b: u8) -> usize {
56
56
rep
57
57
}
58
58
59
- /// Return the first index matching the byte `a ` in `text`.
59
+ /// Return the first index matching the byte `x ` in `text`.
60
60
pub fn memchr ( x : u8 , text : & [ u8 ] ) -> Option < usize > {
61
61
// Scan for a single byte value by reading two `usize` words at a time.
62
62
//
@@ -101,7 +101,7 @@ pub fn memchr(x: u8, text: &[u8]) -> Option<usize> {
101
101
text[ offset..] . iter ( ) . position ( |elt| * elt == x) . map ( |i| offset + i)
102
102
}
103
103
104
- /// Return the last index matching the byte `a ` in `text`.
104
+ /// Return the last index matching the byte `x ` in `text`.
105
105
pub fn memrchr ( x : u8 , text : & [ u8 ] ) -> Option < usize > {
106
106
// Scan for a single byte value by reading two `usize` words at a time.
107
107
//
You can’t perform that action at this time.
0 commit comments