#[non_exhaustive]pub enum SkippableSliceError {
Truncated,
BadMagicNumber(u32),
}Expand description
Errors surfaced by parse_skippable_frame.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Truncated
The buffer ends before the 8-byte header or the declared payload.
BadMagicNumber(u32)
The first 4 bytes are not a skippable-frame magic in the
0x184D2A50..=0x184D2A5F range.
Trait Implementations§
Source§impl Clone for SkippableSliceError
impl Clone for SkippableSliceError
impl Copy for SkippableSliceError
Source§impl Debug for SkippableSliceError
impl Debug for SkippableSliceError
Source§impl Display for SkippableSliceError
impl Display for SkippableSliceError
impl Eq for SkippableSliceError
Source§impl Error for SkippableSliceError
Available on crate feature std only.
impl Error for SkippableSliceError
Available on crate feature
std only.1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for SkippableSliceError
impl PartialEq for SkippableSliceError
impl StructuralPartialEq for SkippableSliceError
Auto Trait Implementations§
impl Freeze for SkippableSliceError
impl RefUnwindSafe for SkippableSliceError
impl Send for SkippableSliceError
impl Sync for SkippableSliceError
impl Unpin for SkippableSliceError
impl UnsafeUnpin for SkippableSliceError
impl UnwindSafe for SkippableSliceError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more