mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-27 18:57:42 +03:00
Rollup merge of #154221 - DanielEScherzer:isize-lc, r=Mark-Simulacrum
`vec::as_mut_slice()`: use lowercase "isize" in safety comment To match other references to that type
This commit is contained in:
@@ -1853,7 +1853,7 @@ pub const fn as_mut_slice(&mut self) -> &mut [T] {
|
||||
// SAFETY: `slice::from_raw_parts_mut` requires pointee is a contiguous, aligned buffer of
|
||||
// size `len` containing properly-initialized `T`s. Data must not be accessed through any
|
||||
// other pointer for the returned lifetime. Further, `len * size_of::<T>` <=
|
||||
// `ISIZE::MAX` and allocation does not "wrap" through overflowing memory addresses.
|
||||
// `isize::MAX` and allocation does not "wrap" through overflowing memory addresses.
|
||||
//
|
||||
// * Vec API guarantees that self.buf:
|
||||
// * contains only properly-initialized items within 0..len
|
||||
|
||||
Reference in New Issue
Block a user