ableos/hblang/tests/lexer_tests_arithmetic.txt

32 lines
316 B
Plaintext
Raw Normal View History

2024-05-10 15:54:12 -05:00
Ident "main"
Decl ":="
2024-05-11 15:22:08 -05:00
Fn "fn"
LParen "("
RParen ")"
2024-05-10 15:54:12 -05:00
Colon ":"
Ident "int"
LBrace "{"
Return "return"
Number "10"
2024-05-15 03:37:39 -05:00
Sub "-"
2024-05-10 15:54:12 -05:00
Number "20"
2024-05-15 03:37:39 -05:00
Div "/"
2024-05-10 15:54:12 -05:00
Number "2"
2024-05-15 03:37:39 -05:00
Add "+"
2024-05-10 15:54:12 -05:00
Number "4"
2024-05-15 03:37:39 -05:00
Mul "*"
2024-05-10 15:54:12 -05:00
LParen "("
Number "2"
2024-05-15 03:37:39 -05:00
Add "+"
2024-05-10 15:54:12 -05:00
Number "2"
RParen ")"
2024-05-15 03:37:39 -05:00
Sub "-"
2024-05-10 15:54:12 -05:00
Number "4"
2024-05-15 03:37:39 -05:00
Mul "*"
2024-05-10 15:54:12 -05:00
Number "4"
2024-05-15 03:37:39 -05:00
Add "+"
2024-05-10 15:54:12 -05:00
Number "1"
Semi ";"
RBrace "}"
Eof ""