Skip to content

Commit

Permalink
(TODO) trait impls
Browse files Browse the repository at this point in the history
  • Loading branch information
daladim committed Sep 10, 2021
1 parent be9d109 commit 776b70f
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/read/read_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,15 @@ impl<'a, R: Read + Seek> ReadRef<'a> for &'a ReadCache<R> {
// This is OK because we never mutate or remove entries.
Ok(unsafe { mem::transmute::<&[u8], &[u8]>(buf) })
}

fn read_bytes_at_until_sequence(
self,
offset: usize,
needle: &[u8],
max_end: usize,
) -> Result<&'a [u8], ()> {
todo!()
}
}

/// An implementation of `ReadRef` for a range of data in a stream that
Expand Down Expand Up @@ -182,4 +191,13 @@ impl<'a, R: Read + Seek> ReadRef<'a> for ReadCacheRange<'a, R> {
}
Ok(bytes)
}

fn read_bytes_at_until_sequence(
self,
offset: usize,
needle: &[u8],
max_end: usize,
) -> Result<&'a [u8], ()> {
todo!()
}
}

0 comments on commit 776b70f

Please sign in to comment.