lexer adjustments

This commit is contained in:
Marvin Schlegel 2024-05-02 22:21:53 +02:00
parent 95063ac64f
commit db2b4a142c

View File

@ -118,6 +118,8 @@ tokens :-
"<<=" { \_ -> SHIFTLEFTEQUAL } "<<=" { \_ -> SHIFTLEFTEQUAL }
">>" { \_ -> SHIFTRIGHT } ">>" { \_ -> SHIFTRIGHT }
">>=" { \_ -> SHIFTRIGHTEQUAL } ">>=" { \_ -> SHIFTRIGHTEQUAL }
">>>" { \_ -> UNSIGNEDSHIFTRIGHT }
">>>=" { \_ -> UNSIGNEDSHIFTRIGHTEQUAL }
{ {
@ -173,7 +175,7 @@ data Token
| VOLATILE | VOLATILE
| WHILE | WHILE
| IDENTIFIER String | IDENTIFIER String
| INTEGERLITERAL Integer | INTEGERLITERAL Int
| CHARLITERAL Char | CHARLITERAL Char
| BOOLLITERAL Bool | BOOLLITERAL Bool
| NULLLITERAL | NULLLITERAL
@ -219,6 +221,8 @@ data Token
| SHIFTLEFTEQUAL | SHIFTLEFTEQUAL
| SHIFTRIGHT | SHIFTRIGHT
| SHIFTRIGHTEQUAL | SHIFTRIGHTEQUAL
| UNSIGNEDSHIFTRIGHT
| UNSIGNEDSHIFTRIGHTEQUAL
deriving(Eq,Show) deriving(Eq,Show)
} }