@@ -2091,6 +2091,12 @@ data WordsByState st fs b
20912091 | WordsByDone
20922092 | WordsByYield !b (WordsByState st fs b)
20932093
2094+-- | Split the stream after stripping leading, trailing, and repeated separators
2095+-- as per the fold supplied.
2096+-- Therefore, @".a..b."@ with '.' as the separator would be parsed as
2097+-- @["a","b"]@. In other words, its like parsing words from whitespace
2098+-- separated text.
2099+
20942100{-# INLINE_NORMAL wordsBy #-}
20952101wordsBy :: Monad m => (a -> Bool) -> Fold m a b -> Stream m a -> Stream m b
20962102wordsBy predicate (Fold fstep initial done) (Stream step state) =