summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKazuki Tsujimoto <kazuki@callcc.net>2020-06-14 09:23:43 +0900
committerKazuki Tsujimoto <kazuki@callcc.net>2020-06-14 09:23:43 +0900
commitf7906a7e31e6b1cfa135ecea69deb8827e8c8803 (patch)
tree4742d7101e8e890d9673064d836691c4fdc12b59
parenta451648b21ff9b9018ef28f9981112687ef745c5 (diff)
push_pktbl is needed for hash pattern, not for array pattern
-rw-r--r--parse.y5
1 files changed, 2 insertions, 3 deletions
diff --git a/parse.y b/parse.y
index 6d35545c9d..38640664d0 100644
--- a/parse.y
+++ b/parse.y
@@ -4048,10 +4048,9 @@ p_expr_basic : p_value
$$ = new_array_pattern_tail(p, Qnone, 0, 0, Qnone, &@$);
$$ = new_array_pattern(p, $1, Qnone, $$, &@$);
}
- | tLBRACK {$<tbl>$ = push_pktbl(p);} p_args rbracket
+ | tLBRACK p_args rbracket
{
- pop_pktbl(p, $<tbl>2);
- $$ = new_array_pattern(p, Qnone, Qnone, $3, &@$);
+ $$ = new_array_pattern(p, Qnone, Qnone, $2, &@$);
}
| tLBRACK rbracket
{