diff --git a/library/alloc/src/raw_vec.rs b/library/alloc/src/raw_vec.rs index 36e2d18d3dd..56f4ebe57f8 100644 --- a/library/alloc/src/raw_vec.rs +++ b/library/alloc/src/raw_vec.rs @@ -232,6 +232,7 @@ impl RawVec { /// Gets a raw pointer to the start of the allocation. Note that this is /// `Unique::dangling()` if `capacity == 0` or `T` is zero-sized. In the former case, you must /// be careful. + #[inline] pub fn ptr(&self) -> *mut T { self.ptr.as_ptr() }