Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion library/alloc/src/rc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1545,12 +1545,13 @@ impl<T: ?Sized> Rc<T> {
///
/// # Safety
///
/// The pointer must have been obtained through `Rc::into_raw` and must satisfy the
/// The pointer must have been obtained through [`Rc::into_raw`][into_raw] and must satisfy the
Copy link
Copy Markdown
Member

@joboet joboet May 21, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rustdoc automatically figures these things out, so

Suggested change
/// The pointer must have been obtained through [`Rc::into_raw`][into_raw] and must satisfy the
/// The pointer must have been obtained through [`Rc::into_raw`] and must satisfy the

is enough for the link to work.

View changes since the review

/// same layout requirements specified in [`Rc::from_raw_in`][from_raw_in].
/// The associated `Rc` instance must be valid (i.e. the strong count must be at
/// least 1) for the duration of this method, and `ptr` must point to a block of memory
/// allocated by the global allocator.
///
/// [into_raw]: Rc::into_raw
/// [from_raw_in]: Rc::from_raw_in
///
/// # Examples
Expand Down
Loading