Copyright | (c) 2009 2010 Bryan O'Sullivan |
---|---|
License | BSD-style |
Maintainer | bos@serpentine.com |
Stability | experimental |
Portability | GHC |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Warning: this is an internal module, and does not have a stable API or name. Functions in this module may not check or enforce preconditions expected by public modules. Use at your own risk!
Core stream fusion functionality for text.
Synopsis
- stream :: Text -> Stream Char
- streamLn :: Text -> Stream Char
- unstream :: Stream Char -> Text
- unstreamChunks :: Int -> Stream Char -> Text
- length :: Stream Char -> Int64
- unfoldrN :: Int64 -> (a -> Maybe (Char, a)) -> a -> Stream Char
- index :: HasCallStack => Stream Char -> Int64 -> Char
- countChar :: Char -> Stream Char -> Int64
Documentation
unstream :: Stream Char -> Text Source #
O(n) Convert a 'Stream Char' into a Text
, using
defaultChunkSize
.
unstreamChunks :: Int -> Stream Char -> Text Source #
O(n) Convert a 'Stream Char' into a Text
, using the given
chunk size.