diff options
| author | nsfisis <nsfisis@gmail.com> | 2025-08-13 04:17:46 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2025-08-15 10:06:21 +0900 |
| commit | 80e1d0fc957a2f254ca94232cca0269567888ddb (patch) | |
| tree | 92ba2a4de23a9978c55fc375df739c4ac736cacd /tokenize.c | |
| parent | 15c8a2f45b3916f840665b317afb344cbc08f5a4 (diff) | |
| download | ducc-80e1d0fc957a2f254ca94232cca0269567888ddb.tar.gz ducc-80e1d0fc957a2f254ca94232cca0269567888ddb.tar.zst ducc-80e1d0fc957a2f254ca94232cca0269567888ddb.zip | |
feat: implement block-based variable scope
Diffstat (limited to 'tokenize.c')
| -rw-r--r-- | tokenize.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -14,8 +14,6 @@ Lexer* lexer_new(Token* pp_tokens) { } void tokenize_all(Lexer* l) { - int ch; - int start; while (l->src[l->pos].kind != TokenKind_eof) { Token* pp_tok = l->src + l->pos; Token* tok = l->tokens + l->n_tokens; @@ -24,7 +22,7 @@ void tokenize_all(Lexer* l) { ++l->pos; if (k == TokenKind_character_constant) { tok->kind = TokenKind_literal_int; - ch = pp_tok->raw.data[1]; + int ch = pp_tok->raw.data[1]; if (ch == '\\') { ch = pp_tok->raw.data[2]; if (ch == 'a') { |
