[][src]Trait autumn::Parser

pub trait Parser<T, E = ()> {
    fn parse<'s>(
        &self,
        source: &'s str,
        location: Span
    ) -> ParseResult<'s, T, E>; }

A parser takes an input source and produces an array of potential tagged values and an array of errors.

Required methods

fn parse<'s>(&self, source: &'s str, location: Span) -> ParseResult<'s, T, E>

Loading content...

Implementations on Foreign Types

impl<E> Parser<char, E> for char[src]

impl<'_, E> Parser<char, E> for &'_ char[src]

impl<E> Parser<Span, E> for str[src]

impl<'_, E> Parser<Span, E> for &'_ str[src]

impl<E> Parser<Span, E> for String[src]

Loading content...

Implementors

impl<'p, T, E> Parser<T, E> for Boxed<dyn Parser<T, E> + 'p>[src]

impl<'p, T, E, P: Parser<T, E>> Parser<T, E> for Referenced<'p, P, E>[src]

impl<A, B, PA, PB, E> Parser<(A, B), E> for Pair<PA, PB, E> where
    A: Clone,
    PA: Parser<A, E>,
    PB: Parser<B, E>, 
[src]

impl<A, B, T, E> Parser<T, E> for And<A, B, E> where
    T: Concat + Clone,
    A: Parser<T, E>,
    B: Parser<T, E>, 
[src]

impl<A, B, T: Clone, E> Parser<T, E> for OnFailure<A, B, E> where
    A: Parser<T, E>,
    B: Parser<T, E>, 
[src]

impl<A, B, T: Clone, E> Parser<T, E> for OnNone<A, B, E> where
    A: Parser<T, E>,
    B: Parser<T, E>, 
[src]

impl<A, B, T: Clone, E> Parser<T, E> for Or<A, B, E> where
    A: Parser<T, E>,
    B: Parser<T, E>, 
[src]

impl<A, B, T: Clone, V, E> Parser<T, E> for Drop<A, B, V, E> where
    A: Parser<T, E>,
    B: Parser<V, E>, 
[src]

impl<A, B, T: Clone, V, E> Parser<T, E> for MaybeDrop<A, B, V, E> where
    A: Parser<T, E>,
    B: Parser<V, E>, 
[src]

impl<E, P: Parser<Span, E>> Parser<String, E> for StringMap<P, E>[src]

impl<E, P: Parser<Span, E>, F: Fn(&str) -> bool> Parser<Span, E> for StrCondition<P, F, E>[src]

impl<P, F, T, E, Q> Parser<T, E> for Fold<P, F, E> where
    T: Clone,
    P: Parser<T, E>,
    Q: Parser<T, E>,
    F: Fn(T) -> Q + Clone
[src]

impl<P, F, T, E, Q, V> Parser<V, E> for AndThen<P, F, T, E> where
    P: Parser<T, E>,
    Q: Parser<V, E>,
    F: Fn(T) -> Q, 
[src]

impl<P, F, T, E, V> Parser<V, E> for Map<P, F, T, E> where
    P: Parser<T, E>,
    F: Fn(T) -> V, 
[src]

impl<P, Q, T, V, E> Parser<V, E> for Skip<P, Q, T, E> where
    P: Parser<T, E>,
    Q: Parser<V, E>, 
[src]

impl<T, D, E, R, P, S> Parser<List<T>, E> for DelimitedBy<P, S, D, R, E> where
    T: Clone,
    R: RangeBounds<usize> + Clone,
    P: Parser<T, E>,
    S: Parser<D, E>, 
[src]

impl<T, D, E, R, P, S> Parser<List<T>, E> for StrictlyDelimitedBy<P, S, D, R, E> where
    T: Clone,
    R: RangeBounds<usize> + Clone,
    P: Parser<T, E>,
    S: Parser<D, E>, 
[src]

impl<T, E, F> Parser<T, E> for F where
    F: for<'s> Fn(&'s str, Span) -> ParseResult<'s, T, E>, 
[src]

impl<T, E, P: Parser<T, E>> Parser<List<T>, E> for ListMap<P, E>[src]

impl<T, E, P: Parser<T, E>> Parser<Meta<T, Span>, E> for MetaMap<P, E>[src]

impl<T, E, P: Parser<T, E>> Parser<T, E> for Catch<P, E>[src]

impl<T, E, P: Parser<T, E>> Parser<T, E> for End<P, E>[src]

impl<T, E, P: Parser<T, E>> Parser<T, E> for SpaceBefore<P, E>[src]

impl<T, E, P: Parser<T, E>, F: Fn(&T) -> bool> Parser<T, E> for Condition<P, F, E>[src]

impl<T, I: FromIterator<T>, E, P: Parser<List<T>, E>> Parser<I, E> for Collect<P, T, I, E>[src]

impl<T, O, C, P, OP, CP, E> Parser<T, E> for SurroundedBy<P, OP, CP, O, C, E> where
    T: Clone,
    P: Parser<T, E>,
    OP: Parser<C, E>,
    CP: Parser<C, E>, 
[src]

impl<T: Concat + Clone, E, P: Parser<T, E>> Parser<T, E> for Multiple<P, E>[src]

impl<T: Concat + Clone, E, R: RangeBounds<usize>, P: Parser<T, E>> Parser<T, E> for Repeat<P, R, E>[src]

impl<T: Concat, E, P: Parser<T, E>> Parser<T, E> for Maybe<P, E>[src]

impl<T: Clone, E, P: Parser<T, E>> Parser<T, E> for MaybeSpaceAfter<P, E>[src]

impl<T: Clone, E, P: Parser<T, E>> Parser<T, E> for MaybeSpaceAround<P, E>[src]

impl<T: Clone, E, P: Parser<T, E>> Parser<T, E> for MaybeSpaceBefore<P, E>[src]

impl<T: Clone, E, P: Parser<T, E>> Parser<T, E> for SpaceAfter<P, E>[src]

impl<T: Clone, E, P: Parser<T, E>> Parser<T, E> for SpaceAround<P, E>[src]

impl<T: PartialEq<V>, V, E, P: Parser<T, E>> Parser<T, E> for Matching<P, V, E>[src]

Loading content...