Skip to content

Commit

Permalink
fix: infinite loop in scanner
Browse files Browse the repository at this point in the history
  • Loading branch information
WhyThat committed Feb 21, 2024
1 parent 8b216a6 commit fe73258
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/scanner.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ static bool scan_comment(TSLexer *lexer) {
// Single-line comment
do {
advance(lexer);
} while (lexer->lookahead != '\n');
} while (lexer->lookahead != '\n' && !lexer->eof(lexer));
return true;

case '*':
Expand Down

0 comments on commit fe73258

Please sign in to comment.