(&mut self)
| 163 | } |
| 164 | |
| 165 | fn read_array<const N: usize>(&mut self) -> Result<&[u8; N]> { |
| 166 | let (chunk, rest) = self.split_first_chunk::<N>().ok_or(MarshalError::Eof)?; |
| 167 | *self = rest; |
| 168 | Ok(chunk) |
| 169 | } |
| 170 | } |
| 171 | |
| 172 | impl<'a> ReadBorrowed<'a> for &'a [u8] { |