Safe Haskell | Safe-Infered |
---|
DDC.Base.Lexer
Contents
Description
Lexer utilities.
- data SourcePos = SourcePos {}
- data Token t = Token {
- tokenTok :: t
- tokenSourcePos :: SourcePos
- takeParsecSourcePos :: Token k -> SourcePos
Documentation
A position in the source file.
If there is no file path then we assume that the input has been read from an interactive session and display ''<interactive>'' when pretty printing.
Constructors
SourcePos | |
Fields
|
Tokens
Wrapper for primitive token type that gives it a source position.
Constructors
Token | |
Fields
|
takeParsecSourcePos :: Token k -> SourcePosSource
Take the parsec style source position from a token.