Lines Matching refs:VarZeroVecFormatError
5 use super::VarZeroVecFormatError;
229 pub fn parse_bytes(slice: &'a [u8]) -> Result<Self, VarZeroVecFormatError> { in parse_bytes() argument
241 .ok_or(VarZeroVecFormatError::Metadata)?; in parse_bytes()
243 F::Len::parse_bytes_to_slice(len_bytes).map_err(|_| VarZeroVecFormatError::Metadata)?; in parse_bytes()
247 .ok_or(VarZeroVecFormatError::Metadata)? in parse_bytes()
252 .ok_or(VarZeroVecFormatError::Metadata)?; in parse_bytes()
253 let len_u32 = u32::try_from(len).map_err(|_| VarZeroVecFormatError::Metadata); in parse_bytes()
269 ) -> Result<Self, VarZeroVecFormatError> { in parse_bytes_with_length() argument
284 .ok_or(VarZeroVecFormatError::Metadata)?; in parse_bytes_with_length()
287 .ok_or(VarZeroVecFormatError::Metadata)?; in parse_bytes_with_length()
436 fn check_indices_and_things(self) -> Result<(), VarZeroVecFormatError> { in check_indices_and_things() argument
439 return Err(VarZeroVecFormatError::Metadata); in check_indices_and_things()
462 return Err(VarZeroVecFormatError::Metadata); in check_indices_and_things()
465 return Err(VarZeroVecFormatError::Metadata); in check_indices_and_things()
469 T::parse_bytes(bytes).map_err(VarZeroVecFormatError::Values)?; in check_indices_and_things()