mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* vm_eval.c (vm_call0): fix for VM_METHOD_TYPE_NOTIMPLEMENTED.
[ruby-dev:41953] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28895 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
93426cd6e8
commit
fd0485acf7
5 changed files with 33 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
Sat Aug 7 13:33:25 2010 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* vm_eval.c (vm_call0): fix for VM_METHOD_TYPE_NOTIMPLEMENTED.
|
||||||
|
[ruby-dev:41953]
|
||||||
|
|
||||||
Sat Aug 7 09:47:06 2010 Masaki Suketa <masaki.suketa@nifty.ne.jp>
|
Sat Aug 7 09:47:06 2010 Masaki Suketa <masaki.suketa@nifty.ne.jp>
|
||||||
|
|
||||||
* ext/win32ole/win32ole.c: fix checking version of GCC.
|
* ext/win32ole/win32ole.c: fix checking version of GCC.
|
||||||
|
|
16
ext/-test-/bug-3662/bug.c
Normal file
16
ext/-test-/bug-3662/bug.c
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
#include <ruby.h>
|
||||||
|
|
||||||
|
static VALUE
|
||||||
|
bug_funcall(int argc, VALUE *argv, VALUE self)
|
||||||
|
{
|
||||||
|
if (argc < 1) rb_raise(rb_eArgError, "not enough argument");
|
||||||
|
return rb_funcall2(self, rb_to_id(*argv), argc-1, argv+1);
|
||||||
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
Init_bug(void)
|
||||||
|
{
|
||||||
|
VALUE mBug = rb_define_module("Bug");
|
||||||
|
rb_define_module_function(mBug, "funcall", bug_funcall, -1);
|
||||||
|
rb_define_module_function(mBug, "notimplement", rb_f_notimplement, -1);
|
||||||
|
}
|
1
ext/-test-/bug-3662/extconf.rb
Normal file
1
ext/-test-/bug-3662/extconf.rb
Normal file
|
@ -0,0 +1 @@
|
||||||
|
create_makefile("-test-/bug-3662/bug")
|
10
test/-ext-/test_bug-3662.rb
Normal file
10
test/-ext-/test_bug-3662.rb
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
require '-test-/bug-3662/bug'
|
||||||
|
|
||||||
|
class Test_BUG_3662 < Test::Unit::TestCase
|
||||||
|
def test_funcall_notimplement
|
||||||
|
bug3662 = '[ruby-dev:41953]'
|
||||||
|
assert_raise(NotImplementedError, bug3662) {
|
||||||
|
Bug.funcall(:notimplement)
|
||||||
|
}
|
||||||
|
end
|
||||||
|
end
|
|
@ -66,6 +66,7 @@ vm_call0(rb_thread_t* th, VALUE recv, VALUE id, int argc, const VALUE *argv,
|
||||||
val = vm_exec(th);
|
val = vm_exec(th);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case VM_METHOD_TYPE_NOTIMPLEMENTED:
|
||||||
case VM_METHOD_TYPE_CFUNC: {
|
case VM_METHOD_TYPE_CFUNC: {
|
||||||
EXEC_EVENT_HOOK(th, RUBY_EVENT_C_CALL, recv, id, klass);
|
EXEC_EVENT_HOOK(th, RUBY_EVENT_C_CALL, recv, id, klass);
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue