[][src]Function pear::parsers::take_while_some_window

pub fn take_while_some_window<I, F>(
    input: &mut Pear<I>,
    n: usize,
    f: F
) -> Result<I::Many, I> where
    I: Input + Rewind,
    F: FnMut(&I::Slice) -> bool

Consumes tokens while cond matches on a window of tokens of size n and returns them. Fails if there aren't at least n tokens, otherwise always otherwise always succeeds. If no tokens match, the result will be empty.