about summary refs log tree commit diff
diff options
context:
space:
mode:
authorDylan DPC <99973273+Dylan-DPC@users.noreply.github.com>2023-01-30 15:11:46 +0530
committerGitHub <noreply@github.com>2023-01-30 15:11:46 +0530
commitf01b8f5cf447fcf1fbcb698a1807e92691d61523 (patch)
tree06976c0fedb7732a6950317fdaf4e5ef6c1fec81
parentd94698cb378feb86e1309eb913bad603cf2089e8 (diff)
parent61b18b58abf4ba5439e7df91d3a39907c1286565 (diff)
downloadrust-f01b8f5cf447fcf1fbcb698a1807e92691d61523.tar.gz
rust-f01b8f5cf447fcf1fbcb698a1807e92691d61523.zip
Rollup merge of #107452 - y21:get-mut-unchecked-typo, r=Mark-Simulacrum
Fix typo in `{Rc, Arc}::get_mut_unchecked` docs

Just a correction in the documentation of `{Rc, Arc}::get_mut_unchecked`.
-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 c9aa23fc4af..fd1e3e0f75b 100644
--- a/library/alloc/src/rc.rs
+++ b/library/alloc/src/rc.rs
@@ -1092,7 +1092,7 @@ impl<T: ?Sized> Rc<T> {
     /// # Safety
     ///
     /// If any other `Rc` or [`Weak`] pointers to the same allocation exist, then
-    /// they must be must not be dereferenced or have active borrows for the duration
+    /// they must not be dereferenced or have active borrows for the duration
     /// of the returned borrow, and their inner type must be exactly the same as the
     /// inner type of this Rc (including lifetimes). This is trivially the case if no
     /// such pointers exist, for example immediately after `Rc::new`.
diff --git a/library/alloc/src/sync.rs b/library/alloc/src/sync.rs
index 9bc9182f7b5..f20486ca9e4 100644
--- a/library/alloc/src/sync.rs
+++ b/library/alloc/src/sync.rs
@@ -1733,7 +1733,7 @@ impl<T: ?Sized> Arc<T> {
     /// # Safety
     ///
     /// If any other `Arc` or [`Weak`] pointers to the same allocation exist, then
-    /// they must be must not be dereferenced or have active borrows for the duration
+    /// they must not be dereferenced or have active borrows for the duration
     /// of the returned borrow, and their inner type must be exactly the same as the
     /// inner type of this Rc (including lifetimes). This is trivially the case if no
     /// such pointers exist, for example immediately after `Arc::new`.