about summary refs log tree commit diff
diff options
context:
space:
mode:
authorscottmcm <scottmcm@users.noreply.github.com>2023-11-07 18:39:09 -0800
committerGitHub <noreply@github.com>2023-11-07 18:39:09 -0800
commit545175ce87a9de4ea371f9d88bafd4d35984a533 (patch)
treeb8fa378b1d8f19326de60fdc8b68f6374f5a92ba
parent01ca7a0cb05e5684049a1ebb6179d63796e24e5c (diff)
downloadrust-545175ce87a9de4ea371f9d88bafd4d35984a533.tar.gz
rust-545175ce87a9de4ea371f9d88bafd4d35984a533.zip
Fix addition formatting
-rw-r--r--library/core/src/slice/mod.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/library/core/src/slice/mod.rs b/library/core/src/slice/mod.rs
index fdf265cb3bf..6cf5d48a167 100644
--- a/library/core/src/slice/mod.rs
+++ b/library/core/src/slice/mod.rs
@@ -642,7 +642,7 @@ impl<T> [T] {
     ///
     /// You can think of this like `.get(index).unwrap_unchecked()`.  It's UB
     /// to call `.get_unchecked(len)`, even if you immediately convert to a
-    /// pointer.  And it's UB to call `.get_unchecked(..len +1)`,
+    /// pointer.  And it's UB to call `.get_unchecked(..len + 1)`,
     /// `.get_unchecked(..=len)`, or similar.
     ///
     /// [`get`]: slice::get
@@ -682,7 +682,7 @@ impl<T> [T] {
     ///
     /// You can think of this like `.get_mut(index).unwrap_unchecked()`.  It's
     /// UB to call `.get_unchecked_mut(len)`, even if you immediately convert
-    /// to a pointer.  And it's UB to call `.get_unchecked_mut(..len +1)`,
+    /// to a pointer.  And it's UB to call `.get_unchecked_mut(..len + 1)`,
     /// `.get_unchecked_mut(..=len)`, or similar.
     ///
     /// [`get_mut`]: slice::get_mut