Safe Haskell | None |
---|---|
Language | Haskell2010 |
Parser from strict ByteString
to Tokens
.
Synopsis
- tokens :: ByteString -> Tokens ByteString String
- type Parser tk k = ByteString -> (ByteString -> k) -> tk k String
- showBeginning :: ByteString -> String
- skipSpace :: ByteString -> ByteString
- attoParse :: Parser a -> ByteString -> IResult ByteString a
- tkErrEOF :: AsError t => String -> t k String
- tkErrBS :: AsError t => ByteString -> String -> t k String
Documentation
tokens :: ByteString -> Tokens ByteString String Source #
Lex (and parse) the ByteString
into Tokens
stream.
The rest of input is in
. Errors are simple textual errors atm.Maybe
ByteString
- TODO: try with stack of parsers, and not making new continuations. Will it be faster?
- TODO: make an
Error
data type.
type Parser tk k = ByteString -> (ByteString -> k) -> tk k String Source #
showBeginning :: ByteString -> String Source #
skipSpace :: ByteString -> ByteString Source #
Strip leading (ASCII) space
attoParse :: Parser a -> ByteString -> IResult ByteString a Source #
Strict bytestring parse
which submits empty string to partial.