mirror of
https://github.com/odin-lang/Odin.git
synced 2026-07-23 16:02:38 +00:00
Fix parser failing on comments inside ternary expressions
This commit is contained in:
@@ -1529,6 +1529,9 @@ gb_internal Token advance_token(AstFile *f) {
|
||||
switch (f->curr_token.kind) {
|
||||
case Token_Comment:
|
||||
consume_comment_groups(f, prev);
|
||||
if (f->curr_token.kind == Token_Semicolon && ignore_newlines(f) && f->curr_token.string == "\n") {
|
||||
advance_token(f);
|
||||
}
|
||||
break;
|
||||
case Token_Semicolon:
|
||||
if (ignore_newlines(f) && f->curr_token.string == "\n") {
|
||||
|
||||
Reference in New Issue
Block a user