aboutsummaryrefslogtreecommitdiff
path: root/src/as_tokenizer.h
diff options
context:
space:
mode:
authorMistivia <i@mistivia.com>2025-03-26 19:11:10 +0800
committerMistivia <i@mistivia.com>2025-03-26 19:11:10 +0800
commit97d4462ac24b726d9313ec52ca0f11711ead553b (patch)
tree1bba7f6d4f2690d673b810bda4ec34523034bcaa /src/as_tokenizer.h
parent312716a295626f2b60b41777728c7f220fee843d (diff)
delete fvm-asHEADmaster
Diffstat (limited to 'src/as_tokenizer.h')
-rw-r--r--src/as_tokenizer.h52
1 files changed, 0 insertions, 52 deletions
diff --git a/src/as_tokenizer.h b/src/as_tokenizer.h
deleted file mode 100644
index 1027530..0000000
--- a/src/as_tokenizer.h
+++ /dev/null
@@ -1,52 +0,0 @@
-#ifndef FMV_AS_TOKENIZER_H_
-#define FMV_AS_TOKENIZER_H_
-
-#include <stdint.h>
-#include <stdio.h>
-
-#include "utils.h"
-
-enum token_type {
- TK_OP, TK_ARG, TK_TAG, TK_COLON, TK_NEWLINE, TK_ENDOFFILE
-};
-typedef enum token_type token_type;
-
-struct token {
- enum token_type type;
- int line;
- int col;
- char *sval;
- int64_t ival;
- double fval;
-};
-typedef struct token token;
-
-#define INPUT_STREAM_BUF_SIZE 1024
-
-struct input_stream{
- FILE *fp;
- char *buf;
- int buf_pos;
- int cursor;
- int line;
- int col;
-};
-typedef struct input_stream input_stream;
-
-struct token_stream {
- token *buf;
- input_stream *s;
-};
-typedef struct token_stream token_stream;
-
-// result<token*>
-result next_token(allocator * alct, token_stream * ts);
-
-// result<token*>
-result peek_token(allocator * alct, token_stream * ts);
-
-void print_token(struct token *t);
-
-token_stream* new_token_stream(allocator * alct, FILE* fp);
-
-#endif // FMV_AS_TOKENIZER_H_