-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathToken.h
More file actions
51 lines (47 loc) · 847 Bytes
/
Token.h
File metadata and controls
51 lines (47 loc) · 847 Bytes
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#ifndef BASHCOMPILER_TOKEN_H
#define BASHCOMPILER_TOKEN_H
#include <string>
namespace TokenType {
enum {
eof,
NL,
SEMICOLON,
Comma,
Number,
Bool,
DeclareId,
DeclareFunc,
Return,
IntType,
BoolType,
FuncReturnVoid,
IfStmt,
ElseStmt,
ForLoopStmt,
Id,
FuncCall,
ROUND_BRACKET_START,
ROUND_BRACKET_END,
SQUARE_BRACKET_START,
SQUARE_BRACKET_END,
CURLY_BRACKET_START,
CURLY_BRACKET_END,
LESS,
GREATER,
Assign,
Add,
Sub,
Mul,
Div,
UnaryMinus,
BoolAND,
BoolOR,
Equal,
Break
};
}
struct Token {
int Type;
std::string Value;
};
#endif //BASHCOMPILER_TOKEN_H