diff options
author | S-H-GAMELINKS <gamelinks007@gmail.com> | 2021-09-03 20:50:12 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2021-09-11 09:13:24 +0900 |
commit | 032534dbdf08c0912dffa482e29a491b8aa9276c (patch) | |
tree | 0ef482a3c7d764610ae9e3a0c737fa3133032de7 /array.c | |
parent | 56065f0686e6798fff2ee7319f0f03026f427c13 (diff) | |
download | ruby-032534dbdf08c0912dffa482e29a491b8aa9276c.tar.gz |
Using RB_BIGNUM_TYPE_P macro
Diffstat (limited to 'array.c')
-rw-r--r-- | array.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -7803,7 +7803,7 @@ rb_ary_sum(int argc, VALUE *argv, VALUE ary) n = 0; } } - else if (RB_TYPE_P(e, T_BIGNUM)) + else if (RB_BIGNUM_TYPE_P(e)) v = rb_big_plus(e, v); else if (RB_TYPE_P(e, T_RATIONAL)) { if (r == Qundef) @@ -7840,7 +7840,7 @@ rb_ary_sum(int argc, VALUE *argv, VALUE ary) x = RFLOAT_VALUE(e); else if (FIXNUM_P(e)) x = FIX2LONG(e); - else if (RB_TYPE_P(e, T_BIGNUM)) + else if (RB_BIGNUM_TYPE_P(e)) x = rb_big2dbl(e); else if (RB_TYPE_P(e, T_RATIONAL)) x = rb_num2dbl(e); |