Struct Check
pub struct Check;
Applies the parser, but do not a produce a value
This has the effect of greatly reducing the amount of code generated and the parser memory usage. Some combinators check for an error in a child parser but discard the error, and for those, using [Check] makes sure the error is not even generated, only the fact that an error happened remains
Trait Implementations
impl Mode for Check
type Output<T> = ();fn bind<T, F: FnOnce() -> T>(F) -> Self::Output<T>fn map<T, U, F: FnOnce(T) -> U>(Self::Output<T>, F) -> Self::Output<U>fn combine<T, U, V, F: FnOnce(T, U) -> V>(Self::Output<T>, Self::Output<U>, F) -> Self::Output<V>
Auto Trait Implementations
impl Freeze for Check
impl RefUnwindSafe for Check
impl Send for Check
impl Sync for Check
impl Unpin for Check
impl UnsafeUnpin for Check
impl UnwindSafe for Check
Blanket Implementations
impl<T> Any for Check
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for Check
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for Check
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> From<T> for Check
fn from(t: T) -> TReturns the argument unchanged.
impl<T, U> Into<U> for Check
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for Check
where
U: Into<T>,
type Error = never;fn try_from(value: U) -> Result<T, never>
impl<T, U> TryInto<U> for Check
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>