diff options
| author | Steve Klabnik <steve@steveklabnik.com> | 2016-02-14 18:02:32 -0500 |
|---|---|---|
| committer | Steve Klabnik <steve@steveklabnik.com> | 2016-02-14 18:02:32 -0500 |
| commit | c244acceb45e0b739d8ad6a896870c93dbb9acec (patch) | |
| tree | 4e0f73e1bd967d4d0e8e18d53002588c0f6a2a70 | |
| parent | 6ba5d9cfd5a76deae0adc1e28260d9821a94a3a7 (diff) | |
| parent | 9673ace3395c39d1605342b4cc5dcfe73f4468f2 (diff) | |
| download | rust-c244acceb45e0b739d8ad6a896870c93dbb9acec.tar.gz rust-c244acceb45e0b739d8ad6a896870c93dbb9acec.zip | |
Rollup merge of #31655 - ollie27:patch-4, r=steveklabnik
r? @steveklabnik
| -rw-r--r-- | src/libcore/num/mod.rs | 2 | ||||
| -rw-r--r-- | src/libcore/str/mod.rs | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/libcore/num/mod.rs b/src/libcore/num/mod.rs index d094f05374b..ed370bb9164 100644 --- a/src/libcore/num/mod.rs +++ b/src/libcore/num/mod.rs @@ -479,7 +479,7 @@ macro_rules! int_impl { } } - /// Checked negation. Computes `!self`, returning `None` if `self == + /// Checked negation. Computes `-self`, returning `None` if `self == /// MIN`. /// /// # Examples diff --git a/src/libcore/str/mod.rs b/src/libcore/str/mod.rs index fa169416a10..4d367cfd432 100644 --- a/src/libcore/str/mod.rs +++ b/src/libcore/str/mod.rs @@ -157,7 +157,7 @@ impl Utf8Error { /// // std::str::from_utf8 returns a Utf8Error /// let error = str::from_utf8(&sparkle_heart).unwrap_err(); /// - /// // the first byte is invalid here + /// // the second byte is invalid here /// assert_eq!(1, error.valid_up_to()); /// ``` #[stable(feature = "utf8_error", since = "1.5.0")] @@ -174,10 +174,10 @@ impl Utf8Error { /// /// If you are sure that the byte slice is valid UTF-8, and you don't want to /// incur the overhead of the validity check, there is an unsafe version of -/// this function, [`from_utf8_unchecked()`][fromutf8], which has the same +/// this function, [`from_utf8_unchecked()`][fromutf8u], which has the same /// behavior but skips the check. /// -/// [fromutf8]: fn.from_utf8.html +/// [fromutf8u]: fn.from_utf8_unchecked.html /// /// If you need a `String` instead of a `&str`, consider /// [`String::from_utf8()`][string]. @@ -275,7 +275,7 @@ unsafe fn from_raw_parts_mut<'a>(p: *mut u8, len: usize) -> &'a mut str { /// Converts a slice of bytes to a string slice without checking /// that the string contains valid UTF-8. /// -/// See the safe version, [`from_utf8()`][fromutf8], for more. +/// See the safe version, [`from_utf8()`][fromutf8], for more information. /// /// [fromutf8]: fn.from_utf8.html /// |
