X-Git-Url: https://git.nihav.org/?a=blobdiff_plain;f=src%2Fio%2Fbyteio.rs;h=e172a325d223e19ff512a6f553b9c4aa083293f1;hb=5eb3cc6035c6c247ffd7e0ac2e3f0f49f1e2ee7b;hp=ca591acf7f10ad94d8564b489ed4b6cf9fd92ed8;hpb=4c6c19cb19126ed8c95f1077472e81991de8bb1c;p=nihav.git diff --git a/src/io/byteio.rs b/src/io/byteio.rs index ca591ac..e172a32 100644 --- a/src/io/byteio.rs +++ b/src/io/byteio.rs @@ -370,8 +370,8 @@ pub struct MemoryWriter<'a> { pos: usize, } -pub struct FileWriter<'a> { - file: &'a File, +pub struct FileWriter { + file: File, } impl<'a> ByteWriter<'a> { @@ -519,13 +519,13 @@ impl<'a> ByteIO for MemoryWriter<'a> { } } -impl<'a> FileWriter<'a> { - pub fn new_write(file: &'a mut File) -> Self { +impl FileWriter { + pub fn new_write(file: File) -> Self { FileWriter { file: file } } } -impl<'a> ByteIO for FileWriter<'a> { +impl ByteIO for FileWriter { #[allow(unused_variables)] fn read_byte(&mut self) -> ByteIOResult { Err(ByteIOError::NotImplemented)