mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
proc.c: no temporary args array
* proc.c (bmcall): method proc is always lambda, args is the array which is made from argc and argv. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54918 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
cfc29cf289
commit
6112b29003
1 changed files with 1 additions and 10 deletions
11
proc.c
11
proc.c
|
@ -2529,16 +2529,7 @@ mlambda(VALUE method)
|
|||
static VALUE
|
||||
bmcall(VALUE args, VALUE method, int argc, VALUE *argv, VALUE passed_proc)
|
||||
{
|
||||
volatile VALUE a;
|
||||
VALUE ret;
|
||||
|
||||
if (CLASS_OF(args) != rb_cArray) {
|
||||
return rb_method_call_with_block(1, &args, method, passed_proc);
|
||||
}
|
||||
argc = check_argc(RARRAY_LEN(args));
|
||||
ret = rb_method_call_with_block(argc, RARRAY_PTR(args), method, passed_proc);
|
||||
RB_GC_GUARD(a) = args;
|
||||
return ret;
|
||||
return rb_method_call_with_block(argc, argv, method, passed_proc);
|
||||
}
|
||||
|
||||
VALUE
|
||||
|
|
Loading…
Reference in a new issue