Permalink
Browse files

Fix segfault when using result of rest assignment

  • Loading branch information...
bouk committed Nov 24, 2016
1 parent 2cca9d3 commit fe362c1f2649c9c502d9a5998ef8c4c94893f3ea
Showing with 12 additions and 1 deletion.
  1. +3 −1 mrbgems/mruby-compiler/core/codegen.c
  2. +9 −0 test/t/codegen.rb
@@ -1061,7 +1061,9 @@ gen_vmassignment(codegen_scope *s, node *tree, int rhs, int val)
n++;
}
}
push();
if (!val) {
push();
}
}
}
View
@@ -54,3 +54,12 @@ def args_to_ary(*args)
B
assert_equal "\n", a
end
assert('splat in case splat') do
a = *case
when 0
* = 1
end
assert_equal [1], a
end

0 comments on commit fe362c1

Please sign in to comment.