take_while

Function take_while 

Source
pub fn take_while<I, E>(
    f: impl FnMut(I::Atom) -> bool,
    qty: impl TryInto<Repetition, Error = impl StdError>,
) -> impl Pipe<I, (I::Container,), E, I::Container>
where I: TakeAtom, Incomplete: Into<E>,
Expand description

Returns the longest input that matches the predicate

If quantity condition is not attained an error is returned