merge revision(s) 39376: [Backport #7903]

* random.c (rb_random_ulong_limited): fix error message for negative
	  value.  [ruby-dev:47061] [Bug #7903]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@39674 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nagachika 2013-03-09 14:52:33 +00:00
parent b78c7fa106
commit 8767705eb2
6 changed files with 32 additions and 1 deletions

View file

@ -185,6 +185,12 @@ negative_int_p(VALUE num)
return RTEST(rb_funcall(num, mid, 1, INT2FIX(0)));
}
int
rb_num_negative_p(VALUE num)
{
return negative_int_p(num);
}
/*
* call-seq:
* num.coerce(numeric) -> array