| Safe Haskell | Safe |
|---|---|
| Language | Haskell2010 |
Sutori.Lexer.Internals
Description
- utf8Encode :: Char -> [Word8]
- type SutoriInput = (SutPosn, Char, [Word8], String)
- type AlexInput = SutoriInput
- alexInputPrevChar :: SutoriInput -> Char
- alexGetByte :: SutoriInput -> Maybe (Word8, SutoriInput)
- ignorePendingBytes :: SutoriInput -> SutoriInput
- sutTabSize :: Int
- lexerMove :: SutPosn -> Char -> SutPosn
- lexerGetInput :: SutMonad SutoriInput
- lexerSetInput :: SutoriInput -> SutMonad ()
Documentation
utf8Encode :: Char -> [Word8] Source #
Encode a Haskell String to a list of Word8 values, in UTF8 format. Taken from Alex wrapper templates
type SutoriInput = (SutPosn, Char, [Word8], String) Source #
The type of the scanner's food (Current position, Previous character, pending bytes on current character, current input)
type AlexInput = SutoriInput Source #
Alias needed by Alex
alexInputPrevChar :: SutoriInput -> Char Source #
Needed by alex for look-back. We don't use look-back now
alexGetByte :: SutoriInput -> Maybe (Word8, SutoriInput) Source #
Needed by alex to read
ignorePendingBytes :: SutoriInput -> SutoriInput Source #
Ignore the current character's pending bytes
sutTabSize :: Int Source #
Hard-coded tab size for positioning
lexerGetInput :: SutMonad SutoriInput Source #
Read input
lexerSetInput :: SutoriInput -> SutMonad () Source #
Set remaining input