Skip to content

Commit a3cc435

Browse files
committed
Remove RawVec::double_in_place.
It's unused.
1 parent 99cb9cc commit a3cc435

File tree

1 file changed

+0
-18
lines changed

1 file changed

+0
-18
lines changed

src/liballoc/raw_vec.rs

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -269,24 +269,6 @@ impl<T, A: AllocRef> RawVec<T, A> {
269269
}
270270
}
271271

272-
/// Attempts to double the size of the type's backing allocation in place. This is common
273-
/// enough to want to do that it's easiest to just have a dedicated method. Slightly
274-
/// more efficient logic can be provided for this than the general case.
275-
///
276-
/// Returns `true` if the reallocation attempt has succeeded.
277-
///
278-
/// # Panics
279-
///
280-
/// * Panics if `T` is zero-sized on the assumption that you managed to exhaust
281-
/// all `usize::MAX` slots in your imaginary buffer.
282-
/// * Panics on 32-bit platforms if the requested capacity exceeds
283-
/// `isize::MAX` bytes.
284-
#[inline(never)]
285-
#[cold]
286-
pub fn double_in_place(&mut self) -> bool {
287-
self.grow(Double, InPlace, Uninitialized).is_ok()
288-
}
289-
290272
/// Ensures that the buffer contains at least enough space to hold
291273
/// `used_capacity + needed_extra_capacity` elements. If it doesn't already have
292274
/// enough capacity, will reallocate enough space plus comfortable slack

0 commit comments

Comments
 (0)