aboutsummaryrefslogtreecommitdiff
path: root/src/parser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/parser.cpp')
-rw-r--r--src/parser.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/parser.cpp b/src/parser.cpp
index 2b2e8736be..882db56b6c 100644
--- a/src/parser.cpp
+++ b/src/parser.cpp
@@ -1423,6 +1423,7 @@ static AstNode *ast_parse_curly_suffix_expr(ParseContext *pc, int *token_index,
Token *token = &pc->tokens->at(*token_index);
if (token->id == TokenIdDot) {
+ node->data.container_init_expr.kind = ContainerInitKindStruct;
for (;;) {
if (token->id == TokenIdDot) {
ast_eat_token(pc, token_index, TokenIdDot);
@@ -1456,6 +1457,7 @@ static AstNode *ast_parse_curly_suffix_expr(ParseContext *pc, int *token_index,
}
} else {
+ node->data.container_init_expr.kind = ContainerInitKindArray;
for (;;) {
if (token->id == TokenIdRBrace) {
*token_index += 1;