Opposite of `pack_bytes`. Needs to know the `length` in bytes. `out` is overwritten with the bytes.
(
input: &mut &'a [u8],
length: usize,
out: &mut CowSlice<'a, T>,
)
| 142 | |
| 143 | /// Opposite of `pack_bytes`. Needs to know the `length` in bytes. `out` is overwritten with the bytes. |
| 144 | pub fn unpack_bytes<'a, T: Byte>( |
| 145 | input: &mut &'a [u8], |
| 146 | length: usize, |
| 147 | out: &mut CowSlice<'a, T>, |
| 148 | ) -> Result<()> { |
| 149 | unpack_bytes_unsigned(input, length, out.cast_mut()) |
| 150 | } |
| 151 | |
| 152 | /// [`unpack_bytes`] but after i8s have been cast to u8s. |
| 153 | fn unpack_bytes_unsigned<'a>( |