summaryrefslogtreecommitdiff
path: root/compile.c
diff options
context:
space:
mode:
Diffstat (limited to 'compile.c')
-rw-r--r--compile.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/compile.c b/compile.c
index e102dc8daf..dbdb4b9127 100644
--- a/compile.c
+++ b/compile.c
@@ -6344,6 +6344,9 @@ compile_case3(rb_iseq_t *iseq, LINK_ANCHOR *const ret, const NODE *const orig_no
while (type == NODE_IN) {
LABEL *l1;
+ if (branch_id) {
+ ADD_INSN(body_seq, line, putnil);
+ }
l1 = NEW_LABEL(line);
ADD_LABEL(body_seq, l1);
ADD_INSN(body_seq, line, pop);