pub struct TryMapWithSpan<A, F, O, U>(/* private fields */);
Trait Implementations§
Source§impl<I: InputType, O, E: ParserExtras<I>, U, F: Fn(O, Range<I::Offset>) -> Result<U, E::Error>, A: Parser<I, O, E>> Parser<I, U, E> for TryMapWithSpan<A, F, O, U>
impl<I: InputType, O, E: ParserExtras<I>, U, F: Fn(O, Range<I::Offset>) -> Result<U, E::Error>, A: Parser<I, O, E>> Parser<I, U, E> for TryMapWithSpan<A, F, O, U>
Source§fn check<'parse>(&self, input: Input<'parse, I, E>) -> IResult<'parse, I, E, ()>
fn check<'parse>(&self, input: Input<'parse, I, E>) -> IResult<'parse, I, E, ()>
Errors Read more
Source§fn parse<'parse>(&self, input: Input<'parse, I, E>) -> IResult<'parse, I, E, U>
fn parse<'parse>(&self, input: Input<'parse, I, E>) -> IResult<'parse, I, E, U>
Errors Read more
fn parse_from<'parse>(&self, input: &'parse I) -> ParseResult<'parse, I, O, E>where
E: ParserExtras<I, Context = ()>,
fn or<P: Parser<I, O, E>>(self, other: P) -> Or<Self, P>where
Self: Sized,
Source§fn map<U, F: Fn(O) -> U>(self, mapper: F) -> Map<Self, O, F, U>where
Self: Sized,
fn map<U, F: Fn(O) -> U>(self, mapper: F) -> Map<Self, O, F, U>where
Self: Sized,
Transforms this parser’s output with the
mapper
function.
The mapper
function cannot return an error. If you want to, consider using Parser::try_map
Read morefn to<U>(self, value: U) -> To<Self, O, U>where
Self: Sized,
fn ignored(self) -> Ignored<Self, O>where
Self: Sized,
fn try_map<F: Fn(U) -> Result<U, E::Error>, U>(
self,
f: F,
) -> TryMap<Self, F, O, U>where
Self: Sized,
fn try_map_with_span<F: Fn(U, Range<I::Offset>) -> Result<U, E::Error>, U>(
self,
f: F,
) -> TryMapWithSpan<Self, F, O, U>where
Self: Sized,
fn filter<F: Fn(&O) -> bool>(self, f: F) -> FilterParser<Self, F, O>where
Self: Sized,
fn repeated_custom<V: FromIterator<O>>(self) -> Repeated<Self, O, V>where
Self: Sized,
fn slice<'a>(self) -> Slice<'a, I, E, O, Self>where
I: SliceInput<'a>,
Self: Sized,
fn then<O2, P: Parser<I, O2, E>>(
self,
other: P,
) -> Then<O, O2, Self, P, true, false>where
Self: Sized,
fn ignore_then<O2, P: Parser<I, O2, E>>(
self,
other: P,
) -> Then<O, O2, Self, P, false, true>where
Self: Sized,
fn then_ignore<O2, P: Parser<I, O2, E>>(
self,
other: P,
) -> Then<O, O2, Self, P, false, false>where
Self: Sized,
fn optional(self) -> Maybe<Self>where
Self: Sized,
Auto Trait Implementations§
impl<A, F, O, U> Freeze for TryMapWithSpan<A, F, O, U>
impl<A, F, O, U> RefUnwindSafe for TryMapWithSpan<A, F, O, U>
impl<A, F, O, U> Send for TryMapWithSpan<A, F, O, U>
impl<A, F, O, U> Sync for TryMapWithSpan<A, F, O, U>
impl<A, F, O, U> Unpin for TryMapWithSpan<A, F, O, U>
impl<A, F, O, U> UnwindSafe for TryMapWithSpan<A, F, O, U>
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