Fix is_char_boundary documentation

This commit is contained in:
Mikko Rantanen 2020-05-27 16:21:30 +03:00
parent de6060b09d
commit 66e9984938
No known key found for this signature in database
GPG key ID: B680E9CE10A55798

View file

@ -2270,12 +2270,11 @@ impl str {
self.len() == 0
}
/// Checks that `index`-th byte lies at the start and/or end of a
/// UTF-8 code point sequence.
/// Checks that `index`-th byte is the first byte in a UTF-8 code point
/// sequence or the end of the string.
///
/// The start and end of the string (when `index == self.len()`) are
/// considered to be
/// boundaries.
/// considered to be boundaries.
///
/// Returns `false` if `index` is greater than `self.len()`.
///