From e1fc028694da8aeb080ed3a1115c99ba532507dd Mon Sep 17 00:00:00 2001 From: Christoffer Lerno Date: Sat, 4 Dec 2021 01:20:27 +0100 Subject: [PATCH] Remove eager readahead. --- src/compiler/lexer.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/compiler/lexer.c b/src/compiler/lexer.c index 466128bfd..94462170b 100644 --- a/src/compiler/lexer.c +++ b/src/compiler/lexer.c @@ -1783,6 +1783,8 @@ void lexer_init_with_file(Lexer *lexer, File *file) while ((c = *(check++)) != '\0') { if (c != 0xE2) continue; + unsigned char next = check[0]; + if (next == 0) break; unsigned char type = check[1]; switch (check[0]) {