Enum bytemuck::checked::CheckedCastError
source · pub enum CheckedCastError {
PodCastError(PodCastError),
InvalidBitPattern,
}
Expand description
The things that can go wrong when casting between CheckedBitPattern
data
forms.
Variants§
PodCastError(PodCastError)
An error occurred during a true-[Pod
] cast
InvalidBitPattern
When casting to a CheckedBitPattern
type, it is possible that the
original data contains an invalid bit pattern. If so, the cast will
fail and this error will be returned. Will never happen on casts
between [Pod
] types.
Trait Implementations§
source§impl Clone for CheckedCastError
impl Clone for CheckedCastError
source§fn clone(&self) -> CheckedCastError
fn clone(&self) -> CheckedCastError
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for CheckedCastError
impl Debug for CheckedCastError
source§impl Display for CheckedCastError
impl Display for CheckedCastError
source§impl From<PodCastError> for CheckedCastError
impl From<PodCastError> for CheckedCastError
source§fn from(err: PodCastError) -> CheckedCastError
fn from(err: PodCastError) -> CheckedCastError
Converts to this type from the input type.