Function pear::parsers::take_some_while_some_window
source · pub fn take_some_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,Expand description
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 or if no tokens
match, otherwise returns all of the tokens before the first failure.