diff --git a/src/generic_storage/mmap_vec.rs b/src/generic_storage/mmap_vec.rs index dd7beeb..d9cac42 100644 --- a/src/generic_storage/mmap_vec.rs +++ b/src/generic_storage/mmap_vec.rs @@ -1,6 +1,8 @@ -use std::fs::{File, OpenOptions}; -use std::ops::{Deref, DerefMut}; -use std::path::Path; +use std::{ + fs::{File, OpenOptions}, + ops::{Deref, DerefMut}, + path::Path, +}; use bytemuck::Pod; use color_eyre::eyre::{ensure, Context}; @@ -11,10 +13,10 @@ const META_SIZE: usize = std::mem::size_of::(); pub struct MmapVec { // This must be Option to properly uphold aliasing access safety guarantees // Look at the `resize` method for more details - mmap: Option, - file: File, + mmap: Option, + file: File, capacity: usize, - phantom: std::marker::PhantomData, + phantom: std::marker::PhantomData, } // Public API