Project

General

Profile

Actions

Bug #5228

closed

Integer#round fails on some big negative numbers

Added by marcandre (Marc-Andre Lafortune) over 12 years ago. Updated over 12 years ago.

Status:
Closed
Target version:
ruby -v:
trunk
Backport:
[ruby-core:39096]

Description

Integer#round fails for some big negative numbers:

(+25 * 1070).round(-71) # => 30...00
(-25 * 10
70).round(-71) # => -20...00, should be -30...00

Actions

Also available in: Atom PDF

Like0
Like0