Skip to content

Commit

Permalink
Unrolled build for rust-lang#130160
Browse files Browse the repository at this point in the history
Rollup merge of rust-lang#130160 - Scripter17:fix-slice-first_mut-doc, r=Amanieu

Fix `slice::first_mut` docs

Changes `pointer` to `reference` since that's the actual type it returns.

`slice::last_mut` does correctly say "reference"
  • Loading branch information
rust-timer authored Sep 12, 2024
2 parents f753bc7 + 99cad12 commit a29da28
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/core/src/slice/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ impl<T> [T] {
if let [first, ..] = self { Some(first) } else { None }
}

/// Returns a mutable pointer to the first element of the slice, or `None` if it is empty.
/// Returns a mutable reference to the first element of the slice, or `None` if it is empty.
///
/// # Examples
///
Expand Down

0 comments on commit a29da28

Please sign in to comment.