aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2022-07-25 12:12:25 +0100
committergingerBill <bill@gingerbill.org>2022-07-25 12:12:25 +0100
commit5f2b220a850c6812bb7b5e4d778be37d8dc8962b (patch)
treebdcef715461ef6ecdc5dc5bde0009ab7db96893d /src
parentecd81e8a5368321f28babd8d18e53401451b8667 (diff)
Fix minor issue with a lack of a trailing comma
Diffstat (limited to 'src')
-rw-r--r--src/parser.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/parser.cpp b/src/parser.cpp
index 247255ce8..b62ec7a74 100644
--- a/src/parser.cpp
+++ b/src/parser.cpp
@@ -3894,7 +3894,8 @@ Ast *parse_field_list(AstFile *f, isize *name_count_, u32 allowed_flags, TokenKi
while (f->curr_token.kind != follow &&
- f->curr_token.kind != Token_EOF) {
+ f->curr_token.kind != Token_EOF &&
+ f->curr_token.kind != Token_Semicolon) {
CommentGroup *docs = f->lead_comment;
u32 set_flags = parse_field_prefixes(f);
Token tag = {};
@@ -3922,7 +3923,7 @@ Ast *parse_field_list(AstFile *f, isize *name_count_, u32 allowed_flags, TokenKi
default_value = parse_expr(f, false);
if (!allow_default_parameters) {
syntax_error(f->curr_token, "Default parameters are only allowed for procedures");
- default_value = nullptr;
+ default_value = nullptr;
}
}