ruby-changes:42804
From: akr <ko1@a...>
Date: Mon, 2 May 2016 06:03:10 +0900 (JST)
Subject: [ruby-changes:42804] akr:r54878 (trunk): complex.c don't refer rb_cFixnum and rb_cBignum.
akr 2016-05-02 06:59:41 +0900 (Mon, 02 May 2016) New Revision: 54878 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=54878 Log: complex.c don't refer rb_cFixnum and rb_cBignum. * complex.c: Don't refer rb_cFixnum and rb_cBignum. (k_fixnum_p): Use FIXNUM_P. (k_bignum_p): Use RB_TYPE_P. Modified files: trunk/ChangeLog trunk/complex.c Index: complex.c =================================================================== --- complex.c (revision 54877) +++ complex.c (revision 54878) @@ -238,13 +238,13 @@ k_numeric_p(VALUE x) https://github.com/ruby/ruby/blob/trunk/complex.c#L238 inline static VALUE k_fixnum_p(VALUE x) { - return f_kind_of_p(x, rb_cFixnum); + return FIXNUM_P(x); } inline static VALUE k_bignum_p(VALUE x) { - return f_kind_of_p(x, rb_cBignum); + return RB_TYPE_P(x, T_BIGNUM); } inline static VALUE Index: ChangeLog =================================================================== --- ChangeLog (revision 54877) +++ ChangeLog (revision 54878) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Mon May 2 06:58:38 2016 Tanaka Akira <akr@f...> + + * complex.c: Don't refer rb_cFixnum and rb_cBignum. + (k_fixnum_p): Use FIXNUM_P. + (k_bignum_p): Use RB_TYPE_P. + Mon May 2 01:27:59 2016 Tanaka Akira <akr@f...> * test/ruby/test_numeric.rb (test_step): Use Integer::FIXNUM_MAX. -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/