summary refs log tree commit diff
path: root/library/alloc/src
diff options
context:
space:
mode:
authorzachs18 <8355914+zachs18@users.noreply.github.com>2022-09-02 01:45:57 -0500
committerZachary S <zasample18+github@gmail.com>2022-11-18 12:50:41 -0600
commitf542b068f24b4129ef99162f5bcf66e8290f9aac (patch)
tree8448cb12943f40d1b3f47f17f23927ac034e6576 /library/alloc/src
parent8c38cb77090af4c876f1c021b86d6c184c80cc4f (diff)
downloadrust-f542b068f24b4129ef99162f5bcf66e8290f9aac.tar.gz
rust-f542b068f24b4129ef99162f5bcf66e8290f9aac.zip
Apply suggestions from code review
Fix spelling error.
Diffstat (limited to 'library/alloc/src')
-rw-r--r--library/alloc/src/rc.rs2
-rw-r--r--library/alloc/src/sync.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/library/alloc/src/rc.rs b/library/alloc/src/rc.rs
index 8ac1b5b488a..c1db035167b 100644
--- a/library/alloc/src/rc.rs
+++ b/library/alloc/src/rc.rs
@@ -1122,7 +1122,7 @@ impl<T: ?Sized> Rc<T> {
     ///     // this is Undefined Behavior, because x's inner type is str, not [u8]
     ///     Rc::get_mut_unchecked(&mut y).fill(0xff); // 0xff is invalid in UTF-8
     /// }
-    /// println!("{}", &*x); // Invliad UTF-8 in a str
+    /// println!("{}", &*x); // Invalid UTF-8 in a str
     /// ```
     /// Other `Rc` pointers to the same allocation must be to the exact same type, including lifetimes.
     /// ```ignore
diff --git a/library/alloc/src/sync.rs b/library/alloc/src/sync.rs
index e4d7bfdaeed..e32ce5a9891 100644
--- a/library/alloc/src/sync.rs
+++ b/library/alloc/src/sync.rs
@@ -1661,7 +1661,7 @@ impl<T: ?Sized> Arc<T> {
     ///     // this is Undefined Behavior, because x's inner type is str, not [u8]
     ///     Arc::get_mut_unchecked(&mut y).fill(0xff); // 0xff is invalid in UTF-8
     /// }
-    /// println!("{}", &*x); // Invliad UTF-8 in a str
+    /// println!("{}", &*x); // Invalid UTF-8 in a str
     /// ```
     /// Other `Arc` pointers to the same allocation must be to the exact same type, including lifetimes.
     /// ```ignore