25 Commits

Author SHA1 Message Date
KOBAYASHI Shuji 32c2aa10c7 Fix Numeric#step to infinity; ref. #4555 2019-07-07 22:10:32 +09:00
KOBAYASHI Shuji 8969edf03b Avoid runtime evaluation for MRB_WITHOUT_FLOAT 2019-01-16 19:32:29 +09:00
KOBAYASHI Shuji de5da4b7f6 Fix coercing for first step counter in Numeric#step
Before:

  a=[]; 7.step(4, -3.0) { |c| a << c }; p a  #=> [7, 4.0]

After / Ruby:

  a=[]; 7.step(4, -3.0) { |c| a << c }; p a  #=> [7.0, 4.0]
2019-01-15 21:41:54 +09:00
Yukihiro "Matz" Matsumoto cca19532c5 Remove Kernel#class_defined? which is not available in CRuby; #3829 2019-01-03 11:34:35 +09:00
YAMAMOTO Masaya acdc2d1f24 Add MRB_WITHOUT_FLOAT 2017-10-11 17:58:11 +09:00
Christopher Aue 3359b86ec7 Improved speed of enumeration methods 2017-07-30 13:19:31 +02:00
Yukihiro "Matz" Matsumoto b23fb45f9c Integral#step without arg should loop forever as CRuby does. 2017-01-20 17:58:29 +09:00
Yukihiro "Matz" Matsumoto efebbbbf26 Implement Float shift methods in C 2016-11-23 09:45:50 +09:00
Yukihiro "Matz" Matsumoto 74696ffd96 Float << and >> should be more compatible to Fixnum 2015-09-02 22:29:01 +09:00
go.kikuta cb870de2b5 numeric.rb: refactor code (Avoid using {...} for multi-line blocks, Surrounding space missing in default value assignment) 2015-08-21 14:54:00 +09:00
Yukihiro "Matz" Matsumoto b05d736b49 update mrblib/*.rb files to conform (some of) Rubocop checks 2015-05-29 17:01:52 +09:00
TOMITA Masahiro bbab89e730 Fix: Numeric#step infinite loop. 2014-11-26 01:34:07 +09:00
Yukihiro "Matz" Matsumoto 653ddd6d3e downto, upto, step to return Enumerator 2014-04-03 20:19:54 +09:00
Yukihiro "Matz" Matsumoto 113ab60784 mruby-enumerator: move definitions in core_mod.rb to mrblib core 2014-03-14 02:41:22 +09:00
Tomoyuki Sahara 9686890ab3 Fix Float#divmod. 2014-03-04 10:51:36 +09:00
Yukihiro "Matz" Matsumoto 9eadd05f32 modify upto/downto for compatibility 2013-10-23 10:34:00 +09:00
Yukihiro "Matz" Matsumoto 2607970ed9 move some methods to make floats and integers compatible [mruby special] 2013-10-22 16:18:11 +09:00
Yukihiro "Matz" Matsumoto 620f8b2721 implement some Numeric methods in Ruby 2013-10-22 15:59:41 +09:00
Yukihiro "Matz" Matsumoto 3ae0616710 implement Integer#succ in Ruby 2013-10-21 07:42:50 +09:00
Masaki Muranaka cbe7a87c68 Move Integer.{floor,ceil,round,truncate} to mrblib/. For maintainability. 2013-03-31 23:04:45 +09:00
Yukihiro Matsumoto ef17231bd7 Integer#step added 2012-09-15 15:04:51 +09:00
Yukihiro Matsumoto 4de0a2afbf Numeric#{upto,downto}: limit may not be an integer 2012-09-15 14:48:31 +09:00
Daniel Bovensiepen b032acd6b6 Modify documentation of Numeric 2012-05-06 18:16:02 +08:00
Daniel Bovensiepen 42197ae0a6 Add some more documentation for Integer 2012-05-01 23:43:49 +08:00
mimaki e0d6430f63 add mruby sources 2012-04-20 09:39:03 +09:00