pub enum Status<T> {
Complete(T),
Partial,
}
Expand description
The result of a successful parse pass.
Complete
is used when the buffer contained the complete value.
Partial
is used when parsing did not reach the end of the expected value,
but no invalid data was found.
Variants§
Implementations§
source§impl<T> Status<T>
impl<T> Status<T>
sourcepub fn is_complete(&self) -> bool
pub fn is_complete(&self) -> bool
Convenience method to check if status is complete.
sourcepub fn is_partial(&self) -> bool
pub fn is_partial(&self) -> bool
Convenience method to check if status is partial.
Trait Implementations§
source§impl<T: PartialEq> PartialEq for Status<T>
impl<T: PartialEq> PartialEq for Status<T>
impl<T: Copy> Copy for Status<T>
impl<T: Eq> Eq for Status<T>
impl<T> StructuralPartialEq for Status<T>
Auto Trait Implementations§
impl<T> Freeze for Status<T>where
T: Freeze,
impl<T> RefUnwindSafe for Status<T>where
T: RefUnwindSafe,
impl<T> Send for Status<T>where
T: Send,
impl<T> Sync for Status<T>where
T: Sync,
impl<T> Unpin for Status<T>where
T: Unpin,
impl<T> UnwindSafe for Status<T>where
T: UnwindSafe,
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)