aboutsummaryrefslogtreecommitdiffstats
path: root/vm_insnhelper.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-10-31 01:32:02 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-10-31 01:32:02 +0000
commit175279c114e5cda9fd55cb7b9f6e1b339c826817 (patch)
treef996a91bbf59cb2c05c72ce2aa99af35a83865f8 /vm_insnhelper.c
parent7e5f02634010b269b698bc32db8d8a6ecded5210 (diff)
downloadruby-175279c114e5cda9fd55cb7b9f6e1b339c826817.tar.gz
* vm_insnhelper.c (vm_search_super_method): do not touch `ci' here.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52402 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r--vm_insnhelper.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c
index ae6195ef4c..9a615df26f 100644
--- a/vm_insnhelper.c
+++ b/vm_insnhelper.c
@@ -2246,11 +2246,12 @@ vm_super_outside(void)
static void
vm_search_super_method(rb_thread_t *th, rb_control_frame_t *reg_cfp,
- struct rb_calling_info *calling, struct rb_call_info *ci, struct rb_call_cache *cc)
+ struct rb_calling_info *calling, const struct rb_call_info *ci, struct rb_call_cache *cc)
{
VALUE current_defined_class, klass;
VALUE sigval = TOPN(calling->argc);
const rb_callable_method_entry_t *me = rb_vm_frame_method_entry(reg_cfp);
+ ID mid;
if (!me) {
vm_super_outside();
@@ -2282,7 +2283,7 @@ vm_search_super_method(rb_thread_t *th, rb_control_frame_t *reg_cfp,
" Specify all arguments explicitly.");
}
- ci->mid = me->def->original_id;
+ mid = me->def->original_id;
klass = vm_search_normal_superclass(me->defined_class);
if (!klass) {
@@ -2292,7 +2293,7 @@ vm_search_super_method(rb_thread_t *th, rb_control_frame_t *reg_cfp,
}
else {
/* TODO: use inline cache */
- cc->me = rb_callable_method_entry(klass, ci->mid);
+ cc->me = rb_callable_method_entry(klass, mid);
CI_SET_FASTPATH(cc, vm_call_super_method, 1);
}
}