mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* vm_insnhelper.c (vm_getivar): fix to use `aux.index' instead of
`aux.opt_pc'. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37244 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
9a82db49eb
commit
000ff5b3ce
2 changed files with 7 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
Wed Oct 17 16:23:17 2012 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* vm_insnhelper.c (vm_getivar): fix to use `aux.index' instead of
|
||||
`aux.opt_pc'.
|
||||
|
||||
Wed Oct 17 16:03:54 2012 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* vm_insnhelper.c (vm_call_method_missing): make a refactoring
|
||||
|
|
|
@ -502,7 +502,7 @@ vm_getivar(VALUE obj, ID id, IC ic, rb_call_info_t *ci, int is_attr)
|
|||
|
||||
if (LIKELY((!is_attr && (ic->ic_class == klass && ic->ic_vmstat == GET_VM_STATE_VERSION())) ||
|
||||
(is_attr && ci->aux.index > 0))) {
|
||||
long index = !is_attr ? ic->ic_value.index : ci->aux.opt_pc - 1;
|
||||
long index = !is_attr ? ic->ic_value.index : ci->aux.index - 1;
|
||||
long len = ROBJECT_NUMIV(obj);
|
||||
VALUE *ptr = ROBJECT_IVPTR(obj);
|
||||
|
||||
|
@ -527,7 +527,7 @@ vm_getivar(VALUE obj, ID id, IC ic, rb_call_info_t *ci, int is_attr)
|
|||
ic->ic_vmstat = GET_VM_STATE_VERSION();
|
||||
}
|
||||
else { /* call_info */
|
||||
ci->aux.opt_pc = index + 1;
|
||||
ci->aux.index = index + 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue