What do you think about adding a function:
chunksOf :: Int -> Data.ByteString.Streaming.ByteString m r -> Stream (Of Data.ByteString.ByteString) m r
This would yield consecutive chunks of n bytes as a strict bytestring. If the ByteString doesn't have n bytes, it ceases to yield and returns.
What do you think about adding a function:
This would yield consecutive chunks of
nbytes as a strict bytestring. If theByteStringdoesn't havenbytes, it ceases to yield and returns.