Updated ~[T] to Vec<T> to match newer rust.