diff options
Diffstat (limited to 'numeric.c')
-rw-r--r-- | numeric.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -1018,8 +1018,8 @@ rb_float_uminus(VALUE flt) * Returns a new Float which is the sum of +float+ and +other+. */ -static VALUE -flo_plus(VALUE x, VALUE y) +VALUE +rb_float_plus(VALUE x, VALUE y) { if (RB_TYPE_P(y, T_FIXNUM)) { return DBL2NUM(RFLOAT_VALUE(x) + (double)FIX2LONG(y)); @@ -1066,8 +1066,8 @@ flo_minus(VALUE x, VALUE y) * Returns a new Float which is the product of +float+ and +other+. */ -static VALUE -flo_mul(VALUE x, VALUE y) +VALUE +rb_float_mul(VALUE x, VALUE y) { if (RB_TYPE_P(y, T_FIXNUM)) { return DBL2NUM(RFLOAT_VALUE(x) * (double)FIX2LONG(y)); @@ -5674,9 +5674,9 @@ Init_Numeric(void) rb_define_alias(rb_cFloat, "inspect", "to_s"); rb_define_method(rb_cFloat, "coerce", flo_coerce, 1); rb_define_method(rb_cFloat, "-@", rb_float_uminus, 0); - rb_define_method(rb_cFloat, "+", flo_plus, 1); + rb_define_method(rb_cFloat, "+", rb_float_plus, 1); rb_define_method(rb_cFloat, "-", flo_minus, 1); - rb_define_method(rb_cFloat, "*", flo_mul, 1); + rb_define_method(rb_cFloat, "*", rb_float_mul, 1); rb_define_method(rb_cFloat, "/", flo_div, 1); rb_define_method(rb_cFloat, "quo", flo_quo, 1); rb_define_method(rb_cFloat, "fdiv", flo_quo, 1); |