Replace RBOOL macro

This commit is contained in:
S-H-GAMELINKS 2021-08-31 20:30:35 +09:00 committed by Nobuyoshi Nakada
parent 8f752c95d2
commit bdd6d8746f
Notes: git 2021-09-05 23:01:54 +09:00
15 changed files with 43 additions and 43 deletions

View file

@ -5471,10 +5471,10 @@ big_op(VALUE x, VALUE y, enum big_op_t op)
n = FIX2INT(rel);
switch (op) {
case big_op_gt: return n > 0 ? Qtrue : Qfalse;
case big_op_ge: return n >= 0 ? Qtrue : Qfalse;
case big_op_lt: return n < 0 ? Qtrue : Qfalse;
case big_op_le: return n <= 0 ? Qtrue : Qfalse;
case big_op_gt: return RBOOL(n > 0);
case big_op_ge: return RBOOL(n >= 0);
case big_op_lt: return RBOOL(n < 0);
case big_op_le: return RBOOL(n <= 0);
}
return Qundef;
}
@ -5518,7 +5518,7 @@ VALUE
rb_big_eq(VALUE x, VALUE y)
{
if (FIXNUM_P(y)) {
return bignorm(x) == y ? Qtrue : Qfalse;
return RBOOL(bignorm(x) == y);
}
else if (RB_BIGNUM_TYPE_P(y)) {
}