Allow ranges for array-like compound literals

This commit is contained in:
gingerBill
2019-10-26 14:06:29 +01:00
parent 94879ed149
commit 7fae890ef9
9 changed files with 345 additions and 170 deletions
+3
View File
@@ -2391,6 +2391,9 @@ parse_value :: proc(p: ^Parser) -> ^ast.Expr {
if p.curr_tok.kind == .Open_Brace {
return parse_literal_value(p, nil);
}
prev_allow_range = p.allow_range;
defer p.allow_range = prev_allow_range;
p.allow_range = true;
return parse_expr(p, false);
}