-
Notifications
You must be signed in to change notification settings - Fork 85
/
Copy pathtokens.hs
28 lines (27 loc) · 931 Bytes
/
tokens.hs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
module Tokens where
data Token =
WhitespaceT Integer | NewlineT | LexErrorT
| HashT | LparT | RparT | StarT | CommaT | ArrowT | DotsT | ColonT | SealT
| SemicolonT | EqualsT | DarrowT | LbrackT | RbrackT | UnderbarT | LbraceT
| BarT | RbraceT | AbstypeT | AndT | AndalsoT | AsT | CaseT | DatatypeT | DoT
| ElseT | EndT | EqtypeT | ExceptionT | FnT | FunT | FunctorT | HandleT | IfT
| InT | IncludeT | InfixT | InfixrT | LetT | LocalT | NonfixT | OfT | OpT
| OpenT | OrelseT | RaiseT | RecT | SharingT | SigT | SignatureT | StructT
| StructureT | ThenT | TypeT | ValT | WhereT | WhileT | WithT | WithtypeT
| ZeroT
| DigitT String
| NumericT String
| IntT Integer
| HexintT String
| WordT String
| HexwordT String
| RealT String
| StringT String
| CharT String
| TyvarT String
| AlphaT String
| SymbolT String
| LongidT String String
| NoneT
deriving (Eq,Show)
-- TODO improve Show