pub fn push(&mut self, value: T) {
        // This will panic or abort if we would allocate > isize::MAX bytes
        // or if the length increment would overflow for zero-sized types.
        if self.len == self.buf.capacity() {
            self.reserve(1);
        }
        unsafe {
            let end = self.as_mut_ptr().add(self.len);
            ptr::write(end, value);
            self.len += 1;
        }
    }
Creates a draining iterator that removes the specified range in the vector
and yields the removed items.

When the iterator **is** dropped, all elements in the range are removed
from the vector, even if the iterator was not fully consumed. If the
iterator **is not** dropped (with [`mem::forget`] for example), it is
unspecified how many elements are removed.

# Panics

Panics if the starting point is greater than the end point or if
the end point is greater than the length of the vector.

# Examples

```
let mut v = vec![1, 2, 3];
let u: Vec<_> = v.drain(1..).collect();
assert_eq!(v, &[1]);
assert_eq!(u, &[2, 3]);
benchmarks/haystacks/code/rust-library.rs