pub fn reserve(&mut self, additional: usize) {
        let old_cap = self.cap();
        let used_cap = self.len() + 1;
        let new_cap = used_cap
            .checked_add(additional)
            .and_then(|needed_cap| needed_cap.checked_next_power_of_two())
            .expect("capacity overflow");

        if new_cap > old_cap {
            self.buf.reserve_exact(used_cap, new_cap - used_cap);
            unsafe {
                self.handle_capacity_increase(old_cap);
            }
        }
    }
Tries to reserve capacity for at least `additional` more elements to be inserted
in the given `VecDeque<T>`. The collection may reserve more space to avoid
frequent reallocations. After calling `try_reserve`, capacity will be
greater than or equal to `self.len() + additional`. Does nothing if
capacity is already sufficient.

# Errors

If the capacity overflows `usize`, or the allocator reports a failure, then an error
is returned.

# Examples

```
#![feature(try_reserve)]
use std::collections::TryRes
benchmarks/haystacks/code/rust-library.rs