mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
int64_value(): use FIXABLE()
This commit is contained in:
+1
-1
@@ -291,7 +291,7 @@ value_int64(mrb_state *mrb, mrb_value x)
|
||||
static mrb_value
|
||||
int64_value(mrb_state *mrb, int64_t v)
|
||||
{
|
||||
if (MRB_INT_MIN <= v && v <= MRB_INT_MAX) {
|
||||
if (FIXABLE(v)) {
|
||||
return mrb_fixnum_value((mrb_int)v);
|
||||
}
|
||||
return mrb_float_value(mrb, (mrb_float)v);
|
||||
|
||||
Reference in New Issue
Block a user