diff options
| author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-09-14 07:26:07 +0000 |
|---|---|---|
| committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-09-14 07:26:07 +0000 |
| commit | 3e3953cd66b2204c12b779b73192d7f025019cb5 (patch) | |
| tree | d98e182cc87baa01fb1d38b7dd4d10ec599db708 | |
| parent | 34530b1ad317cb522233c72cb4dc0895a0f9cf6f (diff) | |
* insnhelper.ci (vm_expandarray): assignment should be placed
after creating new array.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13443 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 5 | ||||
| -rw-r--r-- | insnhelper.ci | 4 |
2 files changed, 8 insertions, 1 deletions
@@ -1,3 +1,8 @@ +Fri Sep 14 16:24:04 2007 Koichi Sasada <ko1@atdot.net> + + * insnhelper.ci (vm_expandarray): assignment should be placed + after creating new array. + Fri Sep 14 16:17:30 2007 Koichi Sasada <ko1@atdot.net> * bootstraptest/runner.rb: add a stress test (-s). diff --git a/insnhelper.ci b/insnhelper.ci index ba12ac6236..7ab7456995 100644 --- a/insnhelper.ci +++ b/insnhelper.ci @@ -1334,7 +1334,7 @@ vm_expandarray(rb_control_frame_t *cfp, VALUE ary, int num, int flag) int is_splat = flag & 0x01; int space_size = num + is_splat; VALUE *base = cfp->sp, *ptr; - volatile VALUE tmp_ary = ary; + volatile VALUE tmp_ary; int len; cfp->sp += space_size; @@ -1342,6 +1342,8 @@ vm_expandarray(rb_control_frame_t *cfp, VALUE ary, int num, int flag) if (TYPE(ary) != T_ARRAY) { ary = rb_ary_to_ary(ary); } + + tmp_ary = ary; ptr = RARRAY_PTR(ary); len = RARRAY_LEN(ary); |
