MCPcopy Create free account
hub / github.com/bedroombuilds/python2rust / open

Method open

0d_files/rust/bufread_iterator.rs:28–34  ·  view source on GitHub ↗
(path: impl AsRef<std::path::Path>)

Source from the content-addressed store, hash-verified

26
27 impl BufReader {
28 pub fn open(path: impl AsRef<std::path::Path>) -> io::Result<Self> {
29 let file = File::open(path)?;
30 let reader = io::BufReader::new(file);
31 let buf = new_buf();
32
33 Ok(Self { reader, buf })
34 }
35 }
36
37 impl Iterator for BufReader {

Callers

nothing calls this directly

Calls 1

new_bufFunction · 0.85

Tested by

no test coverage detected