enum.c: rb_check_funcall_default for fallback value
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58970 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
76be4743ba
commit
7cdb2840df
4
enum.c
4
enum.c
@ -361,9 +361,7 @@ find_all_i(RB_BLOCK_CALL_FUNC_ARGLIST(i, ary))
|
|||||||
static VALUE
|
static VALUE
|
||||||
enum_size(VALUE self, VALUE args, VALUE eobj)
|
enum_size(VALUE self, VALUE args, VALUE eobj)
|
||||||
{
|
{
|
||||||
VALUE r;
|
return rb_check_funcall_default(self, id_size, 0, 0, Qnil);
|
||||||
r = rb_check_funcall(self, id_size, 0, 0);
|
|
||||||
return (r == Qundef) ? Qnil : r;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static long
|
static long
|
||||||
|
Loading…
x
Reference in New Issue
Block a user