TryReadError

Type Alias TryReadError 

Source
pub type TryReadError<Src, Dst>
where Dst: TryFromBytes + ?Sized,
= ConvertError<Infallible, SizeError<Src, Dst>, ValidityError<Src, Dst>>;
Expand description

The error type of fallible read-conversions.

Fallible read-conversions, like TryFromBytes::try_read_from_bytes may emit size and validity errors, but not alignment errors.

Aliased Type§

pub enum TryReadError<Src, Dst>
where Dst: TryFromBytes + ?Sized,
{ Alignment(Infallible), Size(SizeError<Src, Dst>), Validity(ValidityError<Src, Dst>), }

Variants§

§

Alignment(Infallible)

The conversion source was improperly aligned.

§

Size(SizeError<Src, Dst>)

The conversion source was of incorrect size.

§

Validity(ValidityError<Src, Dst>)

The conversion source contained invalid data.