@@ -1327,10 +1327,13 @@ impl<T: ?Sized> Rc<T> {
13271327 ///
13281328 /// # Safety
13291329 ///
1330- /// The pointer must have been obtained through `Rc::into_raw`, the
1331- /// associated `Rc` instance must be valid (i.e. the strong count must be at
1330+ /// The pointer must have been obtained through `Rc::into_raw` and must satisfy the
1331+ /// same layout requirements specified in [`Rc::from_raw_in`][from_raw_in].
1332+ /// The associated `Rc` instance must be valid (i.e. the strong count must be at
13321333 /// least 1) for the duration of this method, and `ptr` must point to a block of memory
1333- /// allocated by the global allocator.
1334+ /// allocated by `alloc`.
1335+ ///
1336+ /// [from_raw_in]: Rc::from_raw_in
13341337 ///
13351338 /// # Examples
13361339 ///
@@ -1360,12 +1363,15 @@ impl<T: ?Sized> Rc<T> {
13601363 ///
13611364 /// # Safety
13621365 ///
1363- /// The pointer must have been obtained through `Rc::into_raw`, the
1364- /// associated `Rc` instance must be valid (i.e. the strong count must be at
1366+ /// The pointer must have been obtained through `Rc::into_raw`and must satisfy the
1367+ /// same layout requirements specified in [`Rc::from_raw_in`][from_raw_in].
1368+ /// The associated `Rc` instance must be valid (i.e. the strong count must be at
13651369 /// least 1) when invoking this method, and `ptr` must point to a block of memory
13661370 /// allocated by the global allocator. This method can be used to release the final `Rc` and
13671371 /// backing storage, but **should not** be called after the final `Rc` has been released.
13681372 ///
1373+ /// [from_raw_in]: Rc::from_raw_in
1374+ ///
13691375 /// # Examples
13701376 ///
13711377 /// ```
@@ -1623,10 +1629,13 @@ impl<T: ?Sized, A: Allocator> Rc<T, A> {
16231629 ///
16241630 /// # Safety
16251631 ///
1626- /// The pointer must have been obtained through `Rc::into_raw`, the
1627- /// associated `Rc` instance must be valid (i.e. the strong count must be at
1632+ /// The pointer must have been obtained through `Rc::into_raw` and must satisfy the
1633+ /// same layout requirements specified in [`Rc::from_raw_in`][from_raw_in].
1634+ /// The associated `Rc` instance must be valid (i.e. the strong count must be at
16281635 /// least 1) for the duration of this method, and `ptr` must point to a block of memory
1629- /// allocated by `alloc`
1636+ /// allocated by `alloc`.
1637+ ///
1638+ /// [from_raw_in]: Rc::from_raw_in
16301639 ///
16311640 /// # Examples
16321641 ///
@@ -1665,11 +1674,14 @@ impl<T: ?Sized, A: Allocator> Rc<T, A> {
16651674 ///
16661675 /// # Safety
16671676 ///
1668- /// The pointer must have been obtained through `Rc::into_raw`, the
1669- /// associated `Rc` instance must be valid (i.e. the strong count must be at
1677+ /// The pointer must have been obtained through `Rc::into_raw`and must satisfy the
1678+ /// same layout requirements specified in [`Rc::from_raw_in`][from_raw_in].
1679+ /// The associated `Rc` instance must be valid (i.e. the strong count must be at
16701680 /// least 1) when invoking this method, and `ptr` must point to a block of memory
1671- /// allocated by `alloc`. This method can be used to release the final `Rc` and backing storage,
1672- /// but **should not** be called after the final `Rc` has been released.
1681+ /// allocated by the global allocator. This method can be used to release the final `Rc` and
1682+ /// backing storage, but **should not** be called after the final `Rc` has been released.
1683+ ///
1684+ /// [from_raw_in]: Rc::from_raw_in
16731685 ///
16741686 /// # Examples
16751687 ///
0 commit comments