diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2021-04-05 01:22:11 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2021-04-05 01:22:11 +0000 |
commit | 1a38986aedf63f676efded3e834c959059d21760 (patch) | |
tree | 5539fa810727b12004aed15c8f3cc7d7cb056345 /internal.h | |
parent | a5272e643121a2e5f51f3cfb2f0899520afafd27 (diff) |
merge revision(s) 254bed302752a401b5fcc3b6c65a9c93711d91d6,fad3023e94c45e7f03478732f7641b6f39ba9d12,3156fb0f2c3ebf8229f392c8502c08fe165ab181: [Backport #17218]
Renamed `nurat_sub` compliant with `rb_rational_plus`
Fix ArithmeticSequence#last and ArithmeticSequence#each for
non-integer sequences (#3870)
[Bug #17218]
[ruby-core:100312]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_6@67936 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'internal.h')
-rw-r--r-- | internal.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/internal.h b/internal.h index 37e5c73d18..13a0424344 100644 --- a/internal.h +++ b/internal.h @@ -1682,9 +1682,11 @@ VALUE rb_float_uminus(VALUE num); VALUE rb_int_plus(VALUE x, VALUE y); VALUE rb_float_plus(VALUE x, VALUE y); VALUE rb_int_minus(VALUE x, VALUE y); +VALUE rb_float_minus(VALUE x, VALUE y); VALUE rb_int_mul(VALUE x, VALUE y); VALUE rb_float_mul(VALUE x, VALUE y); VALUE rb_int_idiv(VALUE x, VALUE y); +VALUE rb_float_div(VALUE x, VALUE y); VALUE rb_int_modulo(VALUE x, VALUE y); VALUE rb_int_round(VALUE num, int ndigits, enum ruby_num_rounding_mode mode); VALUE rb_int2str(VALUE num, int base); @@ -1709,6 +1711,8 @@ VALUE rb_int_odd_p(VALUE num); int rb_int_positive_p(VALUE num); int rb_int_negative_p(VALUE num); VALUE rb_num_pow(VALUE x, VALUE y); +VALUE rb_float_floor(VALUE x, int ndigits); + static inline VALUE rb_num_compare_with_zero(VALUE num, ID mid) @@ -1975,13 +1979,16 @@ void rb_last_status_clear(void); VALUE rb_rational_canonicalize(VALUE x); VALUE rb_rational_uminus(VALUE self); VALUE rb_rational_plus(VALUE self, VALUE other); +VALUE rb_rational_minus(VALUE self, VALUE other); VALUE rb_rational_mul(VALUE self, VALUE other); +VALUE rb_rational_div(VALUE self, VALUE other); VALUE rb_lcm(VALUE x, VALUE y); VALUE rb_rational_reciprocal(VALUE x); VALUE rb_cstr_to_rat(const char *, int); VALUE rb_rational_abs(VALUE self); VALUE rb_rational_cmp(VALUE self, VALUE other); VALUE rb_rational_pow(VALUE self, VALUE other); +VALUE rb_rational_floor(VALUE self, int ndigits); VALUE rb_numeric_quo(VALUE x, VALUE y); /* re.c */ |