diff options
| author | bors <bors@rust-lang.org> | 2017-11-10 09:08:15 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2017-11-10 09:08:15 +0000 |
| commit | c0d326f06d562c3aedf0727a665e9f2c34ba9d0c (patch) | |
| tree | f746fee3284ccafdfe5cc190c4e46ea54fbbfda6 /src/liballoc | |
| parent | d5ff0e6422061c390a141354af8eacd540dca10b (diff) | |
| parent | 6a9931c3fbead83c7d605d978dd74ad6cca8c83e (diff) | |
| download | rust-c0d326f06d562c3aedf0727a665e9f2c34ba9d0c.tar.gz rust-c0d326f06d562c3aedf0727a665e9f2c34ba9d0c.zip | |
Auto merge of #45907 - kennytm:rollup, r=kennytm
Rollup of 9 pull requests - Successful merges: #45783, #45856, #45863, #45869, #45878, #45882, #45887, #45895, #45901 - Failed merges:
Diffstat (limited to 'src/liballoc')
| -rw-r--r-- | src/liballoc/str.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/liballoc/str.rs b/src/liballoc/str.rs index 5f0b4088fc0..a167b2e57c0 100644 --- a/src/liballoc/str.rs +++ b/src/liballoc/str.rs @@ -363,16 +363,16 @@ impl str { /// # Examples /// /// ``` - /// let mut v = String::from("🗻∈🌏"); + /// let v = String::from("🗻∈🌏"); /// /// assert_eq!(Some("🗻"), v.get(0..4)); /// /// // indices not on UTF-8 sequence boundaries - /// assert!(v.get_mut(1..).is_none()); - /// assert!(v.get_mut(..8).is_none()); + /// assert!(v.get(1..).is_none()); + /// assert!(v.get(..8).is_none()); /// /// // out of bounds - /// assert!(v.get_mut(..42).is_none()); + /// assert!(v.get(..42).is_none()); /// ``` #[stable(feature = "str_checked_slicing", since = "1.20.0")] #[inline] |
