aboutsummaryrefslogtreecommitdiff
path: root/src/as_tokenizer.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/as_tokenizer.c')
-rw-r--r--src/as_tokenizer.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/src/as_tokenizer.c b/src/as_tokenizer.c
index 4cb695e..4a5353a 100644
--- a/src/as_tokenizer.c
+++ b/src/as_tokenizer.c
@@ -3,6 +3,7 @@
#include <string.h>
#include "as_tokenizer.h"
+#include "as_op.h"
#include "utils.h"
int InputStream_nextChar(InputStream s) {
@@ -44,19 +45,6 @@ int InputStream_peekChar(InputStream s) {
return s->buf[s->cursor];
}
-char* ops[] = {
- "add", "sub", "mul", "div", "mod", "eq"
-};
-
-int isOp(const char* str) {
- for (int i = 0; i < sizeof(ops) / sizeof(ops[0]); i++) {
- if (strcmp(ops[i], str) == 0) {
- return 1;
- }
- }
- return 0;
-}
-
int isStartOfIndentifier(int c) {
if (c >= 'a' && c <= 'z') {
return 1;