Haskell Core Libraries (base package)ParentContentsIndex
Text.Read.Lex
Portability portable
Stability provisional
Maintainer libraries@haskell.org
Description
The cut-down Haskell lexer, used by Text.Read
Synopsis
data Lexeme
= Char Char
| String String
| Punc String
| Ident String
| Symbol String
| Int Integer
| Rat Rational
| EOF
lex :: ReadP Lexeme
hsLex :: ReadP String
readIntP :: (Num a) => a -> (Char -> Bool) -> (Char -> Int) -> ReadP a
readOctP :: (Num a) => ReadP a
readDecP :: (Num a) => ReadP a
readHexP :: (Num a) => ReadP a
Documentation
data Lexeme
Constructors
Char Char
String String
Punc String
Ident String
Symbol String
Int Integer
Rat Rational
EOF
Instances
Read Lexeme
lex :: ReadP Lexeme
hsLex :: ReadP String
Haskell lexer: returns the lexed string, rather than the lexeme
readIntP :: (Num a) => a -> (Char -> Bool) -> (Char -> Int) -> ReadP a
readOctP :: (Num a) => ReadP a
readDecP :: (Num a) => ReadP a
readHexP :: (Num a) => ReadP a
Produced by Haddock version 0.4