diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-02-05 04:41:05 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-02-05 04:41:05 +0000 |
commit | 738ce30f99bf034468606d2e0fb56af7a217c549 (patch) | |
tree | 06ab534efbb9c570ff231ca90901b3c6dcc4ae11 /vm_insnhelper.c | |
parent | 73645c1c51847198e2195d36cc8be17fbe63db25 (diff) | |
download | ruby-738ce30f99bf034468606d2e0fb56af7a217c549.tar.gz |
convert method name to a Symbol
* vm_eval.c (send_internal), vm_insnhelper.c (vm_call_opt_send):
convert String method name into a Symbol, as method_missing
method expects its first argument to be a Symbol. [Bug #10828]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49506 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm_insnhelper.c')
-rw-r--r-- | vm_insnhelper.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/vm_insnhelper.c b/vm_insnhelper.c index 869796eac5..02a4503f56 100644 --- a/vm_insnhelper.c +++ b/vm_insnhelper.c @@ -1544,6 +1544,7 @@ vm_call_opt_send(rb_thread_t *th, rb_control_frame_t *reg_cfp, rb_call_info_t *c VALUE exc = make_no_method_exception(rb_eNoMethodError, NULL, ci->recv, rb_long2int(ci->argc), &TOPN(i)); rb_exc_raise(exc); } + TOPN(i) = rb_str_intern(sym); ci->mid = idMethodMissing; th->method_missing_reason = ci->aux.missing_reason = ci_missing_reason(ci); } |