diff options
Diffstat (limited to 'mrblib/numeric.rb')
| -rw-r--r-- | mrblib/numeric.rb | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/mrblib/numeric.rb b/mrblib/numeric.rb index 1d701b1fc..daa35c5d6 100644 --- a/mrblib/numeric.rb +++ b/mrblib/numeric.rb @@ -5,6 +5,14 @@ class Integer ## + # Returns the receiver simply. + # + # ISO 15.2.8.3.14 + def ceil + self + end + + ## # Calls the given block once for each Integer # from +self+ downto +num+. # @@ -19,6 +27,14 @@ class Integer end ## + # Returns the receiver simply. + # + # ISO 15.2.8.3.17 + def floor + self + end + + ## # Calls the given block +self+ times. # # ISO 15.2.8.3.22 @@ -32,6 +48,22 @@ class Integer end ## + # Returns the receiver simply. + # + # ISO 15.2.8.3.24 + def round + self + end + + ## + # Returns the receiver simply. + # + # ISO 15.2.8.3.26 + def truncate + self + end + + ## # Calls the given block once for each Integer # from +self+ upto +num+. # |
