diff options
| author | Tom Harley | 2020-02-26 02:33:42 +0000 |
|---|---|---|
| committer | Tom Harley | 2020-02-26 02:33:42 +0000 |
| commit | 7808807313b33dee301b2eff5cb749147dd47ae0 (patch) | |
| tree | 618375061123c858c638416aa78f1583850f85af /lexer.h | |
| download | sheets-master.tar.gz sheets-master.zip | |
Diffstat (limited to 'lexer.h')
| -rw-r--r-- | lexer.h | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -0,0 +1,12 @@ +/*!max:re2c*/ +#define BUFSIZE 50 + +typedef struct { + FILE *file; + char buf[BUFSIZE + 1]; + char *lim, *cur, *tok; + bool eof; +} lexer_t; + +void init_lexer(lexer_t *in, FILE *file); +int lex(lexer_t *in); |
