зеркало из https://github.com/github/ruby.git
* bignum.c (rb_big_even_p, rb_big_odd_p): make them public functions
to be available in other source files. * include/ruby/intern.h (rb_big_even_p, rb_big_odd_p): add prototype declarations. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54163 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
087a393fa5
Коммит
a3c9cda6d7
|
@ -1,3 +1,11 @@
|
|||
Fri Mar 18 01:51:00 2016 Kenta Murata <mrkn@mrkn.jp>
|
||||
|
||||
* bignum.c (rb_big_even_p, rb_big_odd_p): make them public functions
|
||||
to be available in other source files.
|
||||
|
||||
* include/ruby/intern.h (rb_big_even_p, rb_big_odd_p): add prototype
|
||||
declarations.
|
||||
|
||||
Fri Mar 18 00:25:56 2016 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* enum.c (ary_inject_op): Implement the specialized code for sum of
|
||||
|
|
4
bignum.c
4
bignum.c
|
@ -7006,7 +7006,7 @@ rb_big_bit_length(VALUE big)
|
|||
* Returns <code>true</code> if <i>big</i> is an odd number.
|
||||
*/
|
||||
|
||||
static VALUE
|
||||
VALUE
|
||||
rb_big_odd_p(VALUE num)
|
||||
{
|
||||
if (BIGNUM_LEN(num) != 0 && BDIGITS(num)[0] & 1) {
|
||||
|
@ -7022,7 +7022,7 @@ rb_big_odd_p(VALUE num)
|
|||
* Returns <code>true</code> if <i>big</i> is an even number.
|
||||
*/
|
||||
|
||||
static VALUE
|
||||
VALUE
|
||||
rb_big_even_p(VALUE num)
|
||||
{
|
||||
if (BIGNUM_LEN(num) != 0 && BDIGITS(num)[0] & 1) {
|
||||
|
|
|
@ -131,6 +131,8 @@ VALUE rb_big_or(VALUE, VALUE);
|
|||
VALUE rb_big_xor(VALUE, VALUE);
|
||||
VALUE rb_big_lshift(VALUE, VALUE);
|
||||
VALUE rb_big_rshift(VALUE, VALUE);
|
||||
VALUE rb_big_odd_p(VALUE);
|
||||
VALUE rb_big_even_p(VALUE);
|
||||
|
||||
/* For rb_integer_pack and rb_integer_unpack: */
|
||||
/* "MS" in MSWORD and MSBYTE means "most significant" */
|
||||
|
|
Загрузка…
Ссылка в новой задаче