Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- lexer :: (Token -> LexAction a) -> LexAction a
- data Token
- = TLeftPar SrcSpan
- | TRightPar SrcSpan
- | TLeftArrayPar SrcSpan
- | TRightArrayPar SrcSpan
- | TComma SrcSpan
- | TDot SrcSpan
- | TPercent SrcSpan
- | TColon SrcSpan
- | TInclude SrcSpan
- | TProgram SrcSpan
- | TFunction SrcSpan
- | TSubroutine SrcSpan
- | TBlockData SrcSpan
- | TStructure SrcSpan
- | TRecord SrcSpan
- | TUnion SrcSpan
- | TMap SrcSpan
- | TEndProgram SrcSpan
- | TEndFunction SrcSpan
- | TEndSubroutine SrcSpan
- | TEndStructure SrcSpan
- | TEndUnion SrcSpan
- | TEndMap SrcSpan
- | TEnd SrcSpan
- | TAssign SrcSpan
- | TOpAssign SrcSpan
- | TTo SrcSpan
- | TGoto SrcSpan
- | TIf SrcSpan
- | TThen SrcSpan
- | TElse SrcSpan
- | TElsif SrcSpan
- | TEndif SrcSpan
- | TCall SrcSpan
- | TReturn SrcSpan
- | TSave SrcSpan
- | TContinue SrcSpan
- | TStop SrcSpan
- | TCycle SrcSpan
- | TExit SrcSpan
- | TCase SrcSpan
- | TCaseDefault SrcSpan
- | TSelectCase SrcSpan
- | TEndSelect SrcSpan
- | TPause SrcSpan
- | TDo SrcSpan
- | TDoWhile SrcSpan
- | TWhile SrcSpan
- | TEndDo SrcSpan
- | TRead SrcSpan
- | TWrite SrcSpan
- | TRewind SrcSpan
- | TBackspace SrcSpan
- | TEndfile SrcSpan
- | TInquire SrcSpan
- | TOpen SrcSpan
- | TClose SrcSpan
- | TPrint SrcSpan
- | TTypePrint SrcSpan
- | TDimension SrcSpan
- | TCommon SrcSpan
- | TEquivalence SrcSpan
- | TPointer SrcSpan
- | TExternal SrcSpan
- | TIntrinsic SrcSpan
- | TType SrcSpan String
- | TEntry SrcSpan
- | TImplicit SrcSpan
- | TNone SrcSpan
- | TParameter SrcSpan
- | TData SrcSpan
- | TStatic SrcSpan
- | TAutomatic SrcSpan
- | TFormat SrcSpan
- | TBlob SrcSpan String
- | TInt SrcSpan String
- | TBozLiteral SrcSpan Boz
- | TExponent SrcSpan String
- | TBool SrcSpan Bool
- | TOpPlus SrcSpan
- | TOpMinus SrcSpan
- | TOpExp SrcSpan
- | TStar SrcSpan
- | TSlash SrcSpan
- | TAmpersand SrcSpan
- | TOpOr SrcSpan
- | TOpAnd SrcSpan
- | TOpXOr SrcSpan
- | TOpNot SrcSpan
- | TOpEquivalent SrcSpan
- | TOpNotEquivalent SrcSpan
- | TOpLT SrcSpan
- | TOpLE SrcSpan
- | TOpEQ SrcSpan
- | TOpNE SrcSpan
- | TOpGT SrcSpan
- | TOpGE SrcSpan
- | TId SrcSpan String
- | TComment SrcSpan String
- | TString SrcSpan String
- | THollerith SrcSpan String
- | TLabel SrcSpan String
- | TNewline SrcSpan
- | TEOF SrcSpan
- vanillaAlexInput :: String -> FortranVersion -> ByteString -> AlexInput
- data AlexInput = AlexInput {
- aiSourceBytes :: ByteString
- aiEndOffset :: Int
- aiPosition :: Position
- aiBytes :: [Word8]
- aiPreviousChar :: Char
- aiLexeme :: Lexeme
- aiWhiteSensitiveCharCount :: Int
- aiStartCode :: Int
- aiPreviousToken :: Maybe Token
- aiPreviousTokensInLine :: [Token]
- aiCaseSensitive :: Bool
- aiInComment :: Bool
- aiInFormat :: Bool
- aiFortranVersion :: FortranVersion
- type LexAction a = Parse AlexInput Token a
- lexN :: Int -> LexAction (Maybe String)
- lexemeMatch :: Lexeme -> String
- lexer' :: LexAction Token
Main interface
Instances
vanillaAlexInput :: String -> FortranVersion -> ByteString -> AlexInput Source #
AlexInput | |
|
Exposed internals for testing
lexemeMatch :: Lexeme -> String Source #