diff options
| author | 2025-10-18 18:12:19 +0200 | |
|---|---|---|
| committer | 2025-10-18 18:12:19 +0200 | |
| commit | 99adb48d94c59cb2e5701ca39d7c40d4f63459b3 (patch) | |
| tree | be3c432db54dd7f4e1ceab70848543bba1a4ead8 /lex.h | |
| parent | ffca6b54a9654005a121c3557bb8b245ae65ce55 (diff) | |
#pragma once
Diffstat (limited to 'lex.h')
| -rw-r--r-- | lex.h | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -98,11 +98,17 @@ struct lexer { struct arena **tmparena; }; +enum initlexer { + LXOK, + LXFILESEEN, + LXERR, +}; + const char *intern(const char *); int lex(struct lexer *, struct token *); int lexpeek(struct lexer *, struct token *); enum typetag parsenumlit(uvlong *, double *, const struct token *, bool ispp); -const char *initlexer(struct lexer *, const struct span *span, const char *file); +enum initlexer initlexer(struct lexer *, const char **err, const char *file); void lexerdump(struct lexer *, struct wbuf *out); void lexerfreetemps(struct lexer *); |