mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* random.c (rb_random_int32): suppress warning on LP64 platforms.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29103 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
b3545895d1
commit
0eb31be681
1 changed files with 1 additions and 1 deletions
2
random.c
2
random.c
|
@ -894,7 +894,7 @@ rb_random_int32(VALUE obj)
|
|||
#else
|
||||
VALUE lim = rb_big_plus(ULONG2NUM(0xffffffff), INT2FIX(1));
|
||||
#endif
|
||||
return NUM2ULONG(rb_funcall2(obj, id_rand, 1, &lim));
|
||||
return (unsigned int)NUM2ULONG(rb_funcall2(obj, id_rand, 1, &lim));
|
||||
}
|
||||
return genrand_int32(&rnd->mt);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue