fn open_file_reader<P: AsRef<Path>>(path: P) -> Result<Cursor<memmap::Mmap>> {
    let file = File::open(path)?;
    unsafe {
        let mmapped_file = MmapOptions::new().map(&file)?;
        let cursor = Cursor::new(mmapped_file);
        Ok(cursor)
    }
}
/// Open a file reader to the given file
Open a file reader to the given file
Open a file reader to the given file
fn open_file_reader<P: AsRef<Path>>(path: P) -> Result<Cursor<memmap::Mmap>> {
    let file = File::open(path)?;
    unsafe {
        let mmapped_file = MmapOptions::new().map(&file)?;
        let cursor = Cursor::new(mmapped_file);
        Ok(cursor)
    }
}
fn open_file_reader < P : AsRef < Path > > ( path : P ) -> Result < Cursor < memmap :: Mmap > > { let file = File :: open ( path ) ? ; unsafe { let mmapped_file = MmapOptions :: new ( ) . map ( & file ) ? ; let cursor = Cursor :: new ( mmapped_file ) ; Ok ( cursor ) } }
Open a file reader to the given file
Open a file reader to the given file
path
P