Rollup merge of #130160 - Scripter17:fix-slice-first_mut-doc, r=Amanieu · qinheping/verify-rust-std@27049a0 (original) (raw)
Navigation Menu
- Explore
- Pricing
Provide feedback
Saved searches
Use saved searches to filter your results more quickly
Commit 27049a0
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"
File tree
1 file changed
lines changed
1 file changed
lines changed
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -156,7 +156,7 @@ impl [T] { | ||
156 | 156 | if let [first, ..] = self { Some(first) } else { None } |
157 | 157 | } |
158 | 158 | |
159 | -/// Returns a mutable pointer to the first element of the slice, or `None` if it is empty. | |
159 | +/// Returns a mutable reference to the first element of the slice, or `None` if it is empty. | |
160 | 160 | /// |
161 | 161 | /// # Examples |
162 | 162 | /// |