Skip to content

Commit ea71a08

Browse files
committed
auto merge of #12708 : SimonSapin/rust/patch-6, r=huonw
Feel free to reject this if I’m mistaken, but the `count` in the for loop does look like it’s going from 0 to `end`.
2 parents 87a31f6 + c92cdad commit ea71a08

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libstd/str.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1997,8 +1997,8 @@ pub trait StrSlice<'a> {
19971997
/// handle edge cases such as leaving a combining character as the
19981998
/// first code point of the string.
19991999
///
2000-
/// Due to the design of UTF-8, this operation is `O(end -
2001-
/// begin)`. See `slice`, `slice_to` and `slice_from` for `O(1)`
2000+
/// Due to the design of UTF-8, this operation is `O(end)`.
2001+
/// See `slice`, `slice_to` and `slice_from` for `O(1)`
20022002
/// variants that use byte indices rather than code point
20032003
/// indices.
20042004
///

0 commit comments

Comments
 (0)