summaryrefslogtreecommitdiff
path: root/source/lexer/lexer.h
diff options
context:
space:
mode:
Diffstat (limited to 'source/lexer/lexer.h')
-rw-r--r--source/lexer/lexer.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/source/lexer/lexer.h b/source/lexer/lexer.h
new file mode 100644
index 0000000..86f8427
--- /dev/null
+++ b/source/lexer/lexer.h
@@ -0,0 +1,23 @@
1#ifndef ENGINE_LEXER_H
2#define ENGINE_LEXER_H
3
4typedef enum token_type token_type;
5enum token_type
6{
7 // first 255 tokens for ascii characters
8 TOKEN_UNDEFINED = 255,
9 TOKEN_IDENTIFIER,
10 TOKEN_VALUE,
11
12};
13
14typedef struct token token;
15struct token
16{
17 string8 lexeme;
18 token_type type;
19
20};
21
22
23#endif /* ENGINE_LEXER_H */