takeWhile -containers
takeWhile, applied to a predicate p and a list xs, returns the longest prefix (possibly empty) of xs of elements that satisfy p:
> takeWhile (< 3) [1,2,3,4,1,2,3,4] == [1,2]
> takeWhile (< 9) [1,2,3] == [1,2,3]
> takeWhile (< 0) [1,2,3] == []
takeWhile, applied to a predicate p and a ByteString xs, returns the longest prefix (possibly empty) of xs of elements that satisfy p.
O(n) takeWhile, applied to a predicate p and a Text, returns the longest prefix (possibly empty) of elements that satisfy p. Subject to fusion.
takeWhile, applied to a predicate p and a ByteString xs, returns the longest prefix (possibly empty) of xs of elements that satisfy p.