-
Notifications
You must be signed in to change notification settings - Fork 0
/
keywords.h
37 lines (37 loc) · 1021 Bytes
/
keywords.h
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
#ifndef __APPLE__
#include <malloc.h>
#endif
typedef struct keyword {
char* scword;
char* cword;
}keyword;
keyword keywords[10];
void InitKeywords() {
for (int i = 0; i < 10; i++)
{
keyword* k = (keyword*)malloc(sizeof(keyword));
keywords[i] = *k;
}
keywords[0].cword = "if(";
keywords[0].scword = "if ";
keywords[1].cword = "){";
keywords[1].scword = "then";
keywords[2].cword = "}";
keywords[2].scword = "end";
keywords[3].cword = "int main(";
keywords[3].scword = "main ";
keywords[4].cword = "switch(";
keywords[4].scword = "switch ";
keywords[5].cword = "} else {";
keywords[5].scword = "else ";
keywords[6].cword = "unsigned int";
keywords[6].scword = "uint ";
keywords[7].cword = " ";
keywords[7].scword = "Call ";
keywords[8].cword = " ";
keywords[8].scword = "declare ";
keywords[9].cword = " && ";
keywords[9].scword = " and ";
keywords[9].cword = " || ";
keywords[9].scword = " or ";
}