Fix larger than necessary allocations in streamer (#8187) (#8192)

automerge
This commit is contained in:
mergify[bot]
2020-02-10 13:06:28 -08:00
committed by GitHub
parent 7bd95019ef
commit 2f54f57b7a
4 changed files with 43 additions and 10 deletions

View File

@@ -151,6 +151,10 @@ impl<T: Clone + Default + Sized> PinnedVec<T> {
pub fn iter_mut(&mut self) -> PinnedIterMut<T> {
PinnedIterMut(self.x.iter_mut())
}
pub fn capacity(&self) -> usize {
self.x.capacity()
}
}
impl<'a, T: Clone + Send + Sync + Default + Sized> IntoParallelIterator for &'a PinnedVec<T> {