summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-07-29 11:57:14 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-07-29 11:57:14 +0000
commitc463366dfd75056885028a95e8e2fc6e135d9194 (patch)
tree684f70d3ecfe562d0a3c48d29c69309f7ac92748
parent26de0b131e57952d29664de4453e2f04ec3df2bc (diff)
rb_funcallv
* *.c: rename rb_funcall2 to rb_funcallv, except for extensions which are/will be/may be gems. [Fix GH-1406] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--complex.c4
-rw-r--r--dir.c2
-rw-r--r--enumerator.c12
-rw-r--r--eval.c2
-rw-r--r--ext/-test-/funcall/passing_block.c2
-rw-r--r--ext/-test-/notimplement/bug.c2
-rw-r--r--ext/digest/bubblebabble/bubblebabble.c2
-rw-r--r--ext/digest/digest.c2
-rw-r--r--ext/pathname/pathname.c20
-rw-r--r--ext/socket/unixsocket.c2
-rw-r--r--ext/win32ole/win32ole.c2
-rw-r--r--hash.c4
-rw-r--r--io.c14
-rw-r--r--iseq.c2
-rw-r--r--random.c8
-rw-r--r--rational.c2
-rw-r--r--ruby.c2
-rw-r--r--string.c2
-rw-r--r--thread_sync.c2
-rw-r--r--vm_eval.c4
-rw-r--r--vm_insnhelper.c2
-rw-r--r--vm_method.c2
23 files changed, 53 insertions, 48 deletions
diff --git a/ChangeLog b/ChangeLog
index 4e03844..76fa803 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Fri Jul 29 20:57:12 2016 chuanshuo <lilijreey@126.com>
+
+ * *.c: rename rb_funcall2 to rb_funcallv, except for extensions
+ which are/will be/may be gems. [Fix GH-1406]
+
Fri Jul 29 10:51:34 2016 Koichi Sasada <ko1@atdot.net>
* proc.c (env_write): remove unused function.
diff --git a/complex.c b/complex.c
index def0758..7a9c56d 100644
--- a/complex.c
+++ b/complex.c
@@ -468,7 +468,7 @@ f_complex_new2(VALUE klass, VALUE x, VALUE y)
static VALUE
nucomp_f_complex(int argc, VALUE *argv, VALUE klass)
{
- return rb_funcall2(rb_cComplex, id_convert, argc, argv);
+ return rb_funcallv(rb_cComplex, id_convert, argc, argv);
}
#define imp1(n) \
@@ -1582,7 +1582,7 @@ nucomp_rationalize(int argc, VALUE *argv, VALUE self)
rb_raise(rb_eRangeError, "can't convert %"PRIsVALUE" into Rational",
self);
}
- return rb_funcall2(dat->real, rb_intern("rationalize"), argc, argv);
+ return rb_funcallv(dat->real, rb_intern("rationalize"), argc, argv);
}
/*
diff --git a/dir.c b/dir.c
index d1bd2e4..90fc1efe 100644
--- a/dir.c
+++ b/dir.c
@@ -2364,7 +2364,7 @@ dir_s_glob(int argc, VALUE *argv, VALUE obj)
static VALUE
dir_open_dir(int argc, VALUE *argv)
{
- VALUE dir = rb_funcall2(rb_cDir, rb_intern("open"), argc, argv);
+ VALUE dir = rb_funcallv(rb_cDir, rb_intern("open"), argc, argv);
rb_check_typeddata(dir, &dir_data_type);
return dir;
diff --git a/enumerator.c b/enumerator.c
index 2d692e5..7b83af4 100644
--- a/enumerator.c
+++ b/enumerator.c
@@ -1528,7 +1528,7 @@ lazy_map(VALUE obj)
static VALUE
lazy_flat_map_i(RB_BLOCK_CALL_FUNC_ARGLIST(i, yielder))
{
- return rb_funcall2(yielder, id_yield, argc, argv);
+ return rb_funcallv(yielder, id_yield, argc, argv);
}
static VALUE
@@ -1830,7 +1830,7 @@ lazy_take_func(RB_BLOCK_CALL_FUNC_ARGLIST(val, args))
memo = args;
}
- rb_funcall2(argv[0], id_yield, argc - 1, argv + 1);
+ rb_funcallv(argv[0], id_yield, argc - 1, argv + 1);
if ((remain = NUM2LONG(memo)-1) == 0) {
return Qundef;
}
@@ -1875,7 +1875,7 @@ lazy_take_while_func(RB_BLOCK_CALL_FUNC_ARGLIST(val, args))
{
VALUE result = rb_yield_values2(argc - 1, &argv[1]);
if (!RTEST(result)) return Qundef;
- rb_funcall2(argv[0], id_yield, argc - 1, argv + 1);
+ rb_funcallv(argv[0], id_yield, argc - 1, argv + 1);
return Qnil;
}
@@ -1913,7 +1913,7 @@ lazy_drop_func(RB_BLOCK_CALL_FUNC_ARGLIST(val, args))
memo = args;
}
if ((remain = NUM2LONG(memo)) == 0) {
- rb_funcall2(argv[0], id_yield, argc - 1, argv + 1);
+ rb_funcallv(argv[0], id_yield, argc - 1, argv + 1);
}
else {
rb_ivar_set(argv[0], id_memo, LONG2NUM(--remain));
@@ -1942,7 +1942,7 @@ lazy_drop_while_func(RB_BLOCK_CALL_FUNC_ARGLIST(val, args))
rb_ivar_set(argv[0], id_memo, memo = Qtrue);
}
if (memo == Qtrue) {
- rb_funcall2(argv[0], id_yield, argc - 1, argv + 1);
+ rb_funcallv(argv[0], id_yield, argc - 1, argv + 1);
}
return Qnil;
}
@@ -1963,7 +1963,7 @@ lazy_uniq_i(VALUE i, VALUE hash, int argc, const VALUE *argv, VALUE yielder)
{
if (rb_hash_add_new_element(hash, i, Qfalse))
return Qnil;
- return rb_funcall2(yielder, id_yield, argc, argv);
+ return rb_funcallv(yielder, id_yield, argc, argv);
}
static VALUE
diff --git a/eval.c b/eval.c
index db7552c..d0f14b0 100644
--- a/eval.c
+++ b/eval.c
@@ -1315,7 +1315,7 @@ void
rb_obj_call_init(VALUE obj, int argc, const VALUE *argv)
{
PASS_PASSED_BLOCK_HANDLER();
- rb_funcall2(obj, idInitialize, argc, argv);
+ rb_funcallv(obj, idInitialize, argc, argv);
}
void
diff --git a/ext/-test-/funcall/passing_block.c b/ext/-test-/funcall/passing_block.c
index 0200f80..70cb210 100644
--- a/ext/-test-/funcall/passing_block.c
+++ b/ext/-test-/funcall/passing_block.c
@@ -5,7 +5,7 @@ VALUE rb_funcall_passing_block(VALUE, ID, int, const VALUE*);
static VALUE
with_funcall2(int argc, VALUE *argv, VALUE self)
{
- return rb_funcall2(self, rb_intern("target"), argc, argv);
+ return rb_funcallv(self, rb_intern("target"), argc, argv);
}
static VALUE
diff --git a/ext/-test-/notimplement/bug.c b/ext/-test-/notimplement/bug.c
index 34731bc..8e9cae7 100644
--- a/ext/-test-/notimplement/bug.c
+++ b/ext/-test-/notimplement/bug.c
@@ -4,7 +4,7 @@ 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);
+ return rb_funcallv(self, rb_to_id(*argv), argc-1, argv+1);
}
void
diff --git a/ext/digest/bubblebabble/bubblebabble.c b/ext/digest/bubblebabble/bubblebabble.c
index 4b8263d..8f43690 100644
--- a/ext/digest/bubblebabble/bubblebabble.c
+++ b/ext/digest/bubblebabble/bubblebabble.c
@@ -101,7 +101,7 @@ rb_digest_s_bubblebabble(VALUE klass, VALUE str)
static VALUE
rb_digest_class_s_bubblebabble(int argc, VALUE *argv, VALUE klass)
{
- return bubblebabble_str_new(rb_funcall2(klass, id_digest, argc, argv));
+ return bubblebabble_str_new(rb_funcallv(klass, id_digest, argc, argv));
}
/* Document-method: Digest::Instance#bubblebabble
diff --git a/ext/digest/digest.c b/ext/digest/digest.c
index a02eb12..012c0cc 100644
--- a/ext/digest/digest.c
+++ b/ext/digest/digest.c
@@ -486,7 +486,7 @@ rb_digest_class_s_digest(int argc, VALUE *argv, VALUE klass)
static VALUE
rb_digest_class_s_hexdigest(int argc, VALUE *argv, VALUE klass)
{
- return hexencode_str_new(rb_funcall2(klass, id_digest, argc, argv));
+ return hexencode_str_new(rb_funcallv(klass, id_digest, argc, argv));
}
/* :nodoc: */
diff --git a/ext/pathname/pathname.c b/ext/pathname/pathname.c
index d560e73..4fe8859 100644
--- a/ext/pathname/pathname.c
+++ b/ext/pathname/pathname.c
@@ -202,7 +202,7 @@ path_sub(int argc, VALUE *argv, VALUE self)
str = rb_block_call(str, rb_intern("sub"), argc, argv, 0, 0);
}
else {
- str = rb_funcall2(str, rb_intern("sub"), argc, argv);
+ str = rb_funcallv(str, rb_intern("sub"), argc, argv);
}
return rb_class_new_instance(1, &str, rb_obj_class(self));
}
@@ -299,7 +299,7 @@ path_each_line(int argc, VALUE *argv, VALUE self)
return rb_block_call(rb_cIO, rb_intern("foreach"), 1+n, args, 0, 0);
}
else {
- return rb_funcall2(rb_cIO, rb_intern("foreach"), 1+n, args);
+ return rb_funcallv(rb_cIO, rb_intern("foreach"), 1+n, args);
}
}
@@ -321,7 +321,7 @@ path_read(int argc, VALUE *argv, VALUE self)
args[0] = get_strpath(self);
n = rb_scan_args(argc, argv, "03", &args[1], &args[2], &args[3]);
- return rb_funcall2(rb_cIO, rb_intern("read"), 1+n, args);
+ return rb_funcallv(rb_cIO, rb_intern("read"), 1+n, args);
}
/*
@@ -341,7 +341,7 @@ path_binread(int argc, VALUE *argv, VALUE self)
args[0] = get_strpath(self);
n = rb_scan_args(argc, argv, "02", &args[1], &args[2]);
- return rb_funcall2(rb_cIO, rb_intern("binread"), 1+n, args);
+ return rb_funcallv(rb_cIO, rb_intern("binread"), 1+n, args);
}
/*
@@ -362,7 +362,7 @@ path_write(int argc, VALUE *argv, VALUE self)
args[0] = get_strpath(self);
n = rb_scan_args(argc, argv, "03", &args[1], &args[2], &args[3]);
- return rb_funcall2(rb_cIO, rb_intern("write"), 1+n, args);
+ return rb_funcallv(rb_cIO, rb_intern("write"), 1+n, args);
}
/*
@@ -383,7 +383,7 @@ path_binwrite(int argc, VALUE *argv, VALUE self)
args[0] = get_strpath(self);
n = rb_scan_args(argc, argv, "03", &args[1], &args[2], &args[3]);
- return rb_funcall2(rb_cIO, rb_intern("binwrite"), 1+n, args);
+ return rb_funcallv(rb_cIO, rb_intern("binwrite"), 1+n, args);
}
/*
@@ -405,7 +405,7 @@ path_readlines(int argc, VALUE *argv, VALUE self)
args[0] = get_strpath(self);
n = rb_scan_args(argc, argv, "03", &args[1], &args[2], &args[3]);
- return rb_funcall2(rb_cIO, rb_intern("readlines"), 1+n, args);
+ return rb_funcallv(rb_cIO, rb_intern("readlines"), 1+n, args);
}
/*
@@ -423,7 +423,7 @@ path_sysopen(int argc, VALUE *argv, VALUE self)
args[0] = get_strpath(self);
n = rb_scan_args(argc, argv, "02", &args[1], &args[2]);
- return rb_funcall2(rb_cIO, rb_intern("sysopen"), 1+n, args);
+ return rb_funcallv(rb_cIO, rb_intern("sysopen"), 1+n, args);
}
/*
@@ -608,7 +608,7 @@ path_open(int argc, VALUE *argv, VALUE self)
return rb_block_call(rb_cFile, rb_intern("open"), 1+n, args, 0, 0);
}
else {
- return rb_funcall2(rb_cFile, rb_intern("open"), 1+n, args);
+ return rb_funcallv(rb_cFile, rb_intern("open"), 1+n, args);
}
}
@@ -1013,7 +1013,7 @@ path_s_glob(int argc, VALUE *argv, VALUE klass)
else {
VALUE ary;
long i;
- ary = rb_funcall2(rb_cDir, rb_intern("glob"), n, args);
+ ary = rb_funcallv(rb_cDir, rb_intern("glob"), n, args);
ary = rb_convert_type(ary, T_ARRAY, "Array", "to_ary");
for (i = 0; i < RARRAY_LEN(ary); i++) {
VALUE elt = RARRAY_AREF(ary, i);
diff --git a/ext/socket/unixsocket.c b/ext/socket/unixsocket.c
index f73f127..d1cf1e2 100644
--- a/ext/socket/unixsocket.c
+++ b/ext/socket/unixsocket.c
@@ -422,7 +422,7 @@ unix_recv_io(int argc, VALUE *argv, VALUE sock)
ff_argc = mode == Qnil ? 1 : 2;
ff_argv[0] = INT2FIX(fd);
ff_argv[1] = mode;
- return rb_funcall2(klass, for_fd, ff_argc, ff_argv);
+ return rb_funcallv(klass, for_fd, ff_argc, ff_argv);
}
}
#else
diff --git a/ext/win32ole/win32ole.c b/ext/win32ole/win32ole.c
index 4dcd22e..229780d 100644
--- a/ext/win32ole/win32ole.c
+++ b/ext/win32ole/win32ole.c
@@ -383,7 +383,7 @@ static /* [local] */ HRESULT ( STDMETHODCALLTYPE Invoke )(
mid = rb_intern("value");
}
}
- v = rb_funcall2(p->obj, mid, args, parg);
+ v = rb_funcallv(p->obj, mid, args, parg);
ole_val2variant(v, pVarResult);
return S_OK;
}
diff --git a/hash.c b/hash.c
index cab0b9e..963d9ae 100644
--- a/hash.c
+++ b/hash.c
@@ -2588,10 +2588,10 @@ rb_hash_flatten(int argc, VALUE *argv, VALUE hash)
rb_hash_foreach(hash, flatten_i, ary);
if (level - 1 > 0) {
*argv = INT2FIX(level - 1);
- rb_funcall2(ary, id_flatten_bang, argc, argv);
+ rb_funcallv(ary, id_flatten_bang, argc, argv);
}
else if (level < 0) {
- rb_funcall2(ary, id_flatten_bang, 0, 0);
+ rb_funcallv(ary, id_flatten_bang, 0, 0);
}
}
else {
diff --git a/io.c b/io.c
index 19a0c9d..fbd24f6 100644
--- a/io.c
+++ b/io.c
@@ -6606,7 +6606,7 @@ rb_f_open(int argc, VALUE *argv)
}
}
if (redirect) {
- VALUE io = rb_funcall2(argv[0], to_open, argc-1, argv+1);
+ VALUE io = rb_funcallv(argv[0], to_open, argc-1, argv+1);
if (rb_block_given_p()) {
return rb_ensure(rb_yield, io, io_close, io);
@@ -7079,7 +7079,7 @@ rb_f_putc(VALUE recv, VALUE ch)
if (recv == rb_stdout) {
return rb_io_putc(recv, ch);
}
- return rb_funcall2(rb_stdout, rb_intern("putc"), 1, &ch);
+ return rb_funcallv(rb_stdout, rb_intern("putc"), 1, &ch);
}
@@ -7184,7 +7184,7 @@ rb_f_puts(int argc, VALUE *argv, VALUE recv)
if (recv == rb_stdout) {
return rb_io_puts(argc, argv, recv);
}
- return rb_funcall2(rb_stdout, rb_intern("puts"), argc, argv);
+ return rb_funcallv(rb_stdout, rb_intern("puts"), argc, argv);
}
void
@@ -8206,7 +8206,7 @@ rb_f_gets(int argc, VALUE *argv, VALUE recv)
if (recv == argf) {
return argf_gets(argc, argv, argf);
}
- return rb_funcall2(argf, idGets, argc, argv);
+ return rb_funcallv(argf, idGets, argc, argv);
}
/*
@@ -8279,7 +8279,7 @@ rb_f_readline(int argc, VALUE *argv, VALUE recv)
if (recv == argf) {
return argf_readline(argc, argv, argf);
}
- return rb_funcall2(argf, rb_intern("readline"), argc, argv);
+ return rb_funcallv(argf, rb_intern("readline"), argc, argv);
}
@@ -8332,7 +8332,7 @@ rb_f_readlines(int argc, VALUE *argv, VALUE recv)
if (recv == argf) {
return argf_readlines(argc, argv, argf);
}
- return rb_funcall2(argf, rb_intern("readlines"), argc, argv);
+ return rb_funcallv(argf, rb_intern("readlines"), argc, argv);
}
/*
@@ -10864,7 +10864,7 @@ rb_io_set_encoding(int argc, VALUE *argv, VALUE io)
VALUE v1, v2, opt;
if (!RB_TYPE_P(io, T_FILE)) {
- return rb_funcall2(io, id_set_encoding, argc, argv);
+ return rb_funcallv(io, id_set_encoding, argc, argv);
}
argc = rb_scan_args(argc, argv, "11:", &v1, &v2, &opt);
diff --git a/iseq.c b/iseq.c
index 0f98107..e4698f5 100644
--- a/iseq.c
+++ b/iseq.c
@@ -325,7 +325,7 @@ cleanup_iseq_build(rb_iseq_t *iseq)
compile_data_free(data);
if (RTEST(err)) {
- rb_funcall2(err, rb_intern("set_backtrace"), 1, &iseq->body->location.path);
+ rb_funcallv(err, rb_intern("set_backtrace"), 1, &iseq->body->location.path);
rb_exc_raise(err);
}
return Qtrue;
diff --git a/random.c b/random.c
index bc6474f..ee91c53 100644
--- a/random.c
+++ b/random.c
@@ -957,7 +957,7 @@ rb_random_real(VALUE obj)
{
rb_random_t *rnd = try_get_rnd(obj);
if (!rnd) {
- VALUE v = rb_funcall2(obj, id_rand, 0, 0);
+ VALUE v = rb_funcallv(obj, id_rand, 0, 0);
double d = NUM2DBL(v);
if (d < 0.0) {
rb_raise(rb_eRangeError, "random number too small %g", d);
@@ -1018,7 +1018,7 @@ rb_random_ulong_limited(VALUE obj, unsigned long limit)
rb_random_t *rnd = try_get_rnd(obj);
if (!rnd) {
VALUE lim = ulong_to_num_plus_1(limit);
- VALUE v = rb_to_int(rb_funcall2(obj, id_rand, 1, &lim));
+ VALUE v = rb_to_int(rb_funcallv(obj, id_rand, 1, &lim));
unsigned long r = NUM2ULONG(v);
if (rb_num_negative_p(v)) {
rb_raise(rb_eRangeError, "random number too small %ld", r);
@@ -1121,7 +1121,7 @@ range_values(VALUE vmax, VALUE *begp, VALUE *endp, int *exclp)
if (!rb_range_values(vmax, begp, &end, exclp)) return Qfalse;
if (endp) *endp = end;
if (!rb_respond_to(end, id_minus)) return Qfalse;
- r = rb_funcall2(end, id_minus, 1, begp);
+ r = rb_funcallv(end, id_minus, 1, begp);
if (NIL_P(r)) return Qfalse;
return r;
}
@@ -1270,7 +1270,7 @@ rand_range(VALUE obj, rb_random_t* rnd, VALUE range)
}
}
default:
- return rb_funcall2(beg, id_plus, 1, &v);
+ return rb_funcallv(beg, id_plus, 1, &v);
}
return v;
diff --git a/rational.c b/rational.c
index 1909536..f0e8d56 100644
--- a/rational.c
+++ b/rational.c
@@ -605,7 +605,7 @@ f_rational_new_no_reduce2(VALUE klass, VALUE x, VALUE y)
static VALUE
nurat_f_rational(int argc, VALUE *argv, VALUE klass)
{
- return rb_funcall2(rb_cRational, id_convert, argc, argv);
+ return rb_funcallv(rb_cRational, id_convert, argc, argv);
}
/*
diff --git a/ruby.c b/ruby.c
index 797fa79..8f88339 100644
--- a/ruby.c
+++ b/ruby.c
@@ -634,7 +634,7 @@ require_libraries(VALUE *req_list)
rb_enc_associate(feature, extenc);
RBASIC_SET_CLASS_RAW(feature, rb_cString);
OBJ_FREEZE(feature);
- rb_funcall2(self, require, 1, &feature);
+ rb_funcallv(self, require, 1, &feature);
}
*req_list = 0;
}
diff --git a/string.c b/string.c
index a5b1279..26f2324 100644
--- a/string.c
+++ b/string.c
@@ -3526,7 +3526,7 @@ rb_str_match_m(int argc, VALUE *argv, VALUE str)
rb_check_arity(argc, 1, 2);
re = argv[0];
argv[0] = str;
- result = rb_funcall2(get_pat(re), rb_intern("match"), argc, argv);
+ result = rb_funcallv(get_pat(re), rb_intern("match"), argc, argv);
if (!NIL_P(result) && rb_block_given_p()) {
return rb_yield(result);
}
diff --git a/thread_sync.c b/thread_sync.c
index ed81a31..efa6208 100644
--- a/thread_sync.c
+++ b/thread_sync.c
@@ -1157,7 +1157,7 @@ static VALUE
do_sleep(VALUE args)
{
struct sleep_call *p = (struct sleep_call *)args;
- return rb_funcall2(p->mutex, id_sleep, 1, &p->timeout);
+ return rb_funcallv(p->mutex, id_sleep, 1, &p->timeout);
}
static VALUE
diff --git a/vm_eval.c b/vm_eval.c
index 4ef4d6e..264c092 100644
--- a/vm_eval.c
+++ b/vm_eval.c
@@ -853,7 +853,7 @@ rb_funcallv(VALUE recv, ID mid, int argc, const VALUE *argv)
/*!
* Calls a method.
*
- * Same as rb_funcall2 but this function can call only public methods.
+ * Same as rb_funcallv but this function can call only public methods.
* \param recv receiver of the method
* \param mid an ID that represents the name of the method
* \param argc the number of arguments
@@ -1543,7 +1543,7 @@ rb_eval_cmd(VALUE cmd, VALUE arg, int level)
rb_set_safe_level_force(level);
if ((state = TH_EXEC_TAG()) == 0) {
if (!RB_TYPE_P(cmd, T_STRING)) {
- val = rb_funcall2(cmd, idCall, RARRAY_LENINT(arg),
+ val = rb_funcallv(cmd, idCall, RARRAY_LENINT(arg),
RARRAY_CONST_PTR(arg));
}
else {
diff --git a/vm_insnhelper.c b/vm_insnhelper.c
index 9b29124..1b41234 100644
--- a/vm_insnhelper.c
+++ b/vm_insnhelper.c
@@ -1303,7 +1303,7 @@ check_match(VALUE pattern, VALUE target, enum vm_check_match_type type)
}
else {
/* fallback to funcall (e.g. method_missing) */
- return rb_funcall2(pattern, idEqq, 1, &target);
+ return rb_funcallv(pattern, idEqq, 1, &target);
}
}
default:
diff --git a/vm_method.c b/vm_method.c
index acdd976..b5a6f53 100644
--- a/vm_method.c
+++ b/vm_method.c
@@ -610,7 +610,7 @@ rb_method_entry_make(VALUE klass, ID mid, VALUE defined_class, rb_method_visibil
recv_class = rb_ivar_get((klass), attached); \
hook_id = singleton_##hook; \
} \
- rb_funcall2(recv_class, hook_id, 1, &arg); \
+ rb_funcallv(recv_class, hook_id, 1, &arg); \
} while (0)
static void