about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/liballoc/rc.rs6
-rw-r--r--src/liballoc/sync.rs6
2 files changed, 8 insertions, 4 deletions
diff --git a/src/liballoc/rc.rs b/src/liballoc/rc.rs
index abb09684260..1509afa4889 100644
--- a/src/liballoc/rc.rs
+++ b/src/liballoc/rc.rs
@@ -719,8 +719,10 @@ impl<T: ?Sized> Rc<T> {
     ///
     /// # Safety
     ///
-    /// There must be no other `Rc` or [`Weak`] pointers to the same value.
-    /// This is the case for example immediately after `Rc::new`.
+    /// Any other `Rc` or [`Weak`] pointers to the same value must not be dereferenced
+    /// for the duration of the returned borrow.
+    /// This is trivially the case if no such pointer exist,
+    /// for example immediately after `Rc::new`.
     ///
     /// # Examples
     ///
diff --git a/src/liballoc/sync.rs b/src/liballoc/sync.rs
index bb4d1499014..078ddc27da9 100644
--- a/src/liballoc/sync.rs
+++ b/src/liballoc/sync.rs
@@ -1104,8 +1104,10 @@ impl<T: ?Sized> Arc<T> {
     ///
     /// # Safety
     ///
-    /// There must be no other `Arc` or [`Weak`] pointers to the same value.
-    /// This is the case for example immediately after `Rc::new`.
+    /// Any other `Arc` or [`Weak`] pointers to the same value must not be dereferenced
+    /// for the duration of the returned borrow.
+    /// This is trivially the case if no such pointer exist,
+    /// for example immediately after `Arc::new`.
     ///
     /// # Examples
     ///