summaryrefslogtreecommitdiff
path: root/compile.c
diff options
context:
space:
mode:
authorKazuki Tsujimoto <[email protected]>2021-03-21 15:12:54 +0900
committerKazuki Tsujimoto <[email protected]>2021-03-21 15:14:31 +0900
commit21863470d965b8cc299b1f82417c70d5d26f8ab2 (patch)
tree727faf202cf818d796602b526e17fb9bfea0cb29 /compile.c
parent232433f22423fb6a3ff7a610140c711a964d3b3d (diff)
Pattern matching pin operator against expression [Feature #17411]
This commit is based on the patch by @nobu.
Diffstat (limited to 'compile.c')
-rw-r--r--compile.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/compile.c b/compile.c
index 78870ee051..230b800529 100644
--- a/compile.c
+++ b/compile.c
@@ -6211,6 +6211,7 @@ iseq_compile_pattern_each(rb_iseq_t *iseq, LINK_ANCHOR *const ret, const NODE *c
case NODE_NIL:
case NODE_COLON2:
case NODE_COLON3:
+ case NODE_BEGIN:
CHECK(COMPILE(ret, "case in literal", node));
ADD_INSN1(ret, line, checkmatch, INT2FIX(VM_CHECKMATCH_TYPE_CASE));
ADD_INSNL(ret, line, branchif, matched);