Project

General

Profile

Actions

Bug #4567

closed

BigDecimal::ROUND_HALF_DOWN

Bug #4567: BigDecimal::ROUND_HALF_DOWN

Added by semmons99 (Shane Emmons) over 14 years ago. Updated over 14 years ago.

Status:
Closed
Target version:
ruby -v:
ruby 1.9.2p180 (2011-02-18 revision 30909) [x86_64-darwin10.7.1]
Backport:
[ruby-core:<unknown>]

Description

=begin
SImilar to the issue here [[http://redmine.ruby-lang.org/issues/3803]], BigDecimal::ROUND_HALF_DOWN does not respect all the digits involved in the rounding of a number. For example:

(({BigDecimal("1.51").round(0, BigDecimal::ROUND_HALF_DOWN) == BigDecimal("2")})) returns false because it is ignoring the "1". The same fix that was done for ROUND_HALF_EVEN will need to be done here. I believe it has already been fixed in 1.9.3dev, so it should only need to be backported to 1.9.2 and 1.8.7.
=end

Updated by mrkn (Kenta Murata) over 14 years ago Actions #1

  • Status changed from Open to Assigned
  • Assignee set to mrkn (Kenta Murata)

=begin

=end

Updated by nahi (Hiroshi Nakamura) over 14 years ago Actions #2 [ruby-core:37435]

  • Target version changed from 1.9.2 to 1.9.3

Updated by semmons99 (Shane Emmons) over 14 years ago Actions #3 [ruby-core:37817]

Issue 3803 already handles this case. This issue can be closed with a reference to 3803.

Updated by mrkn (Kenta Murata) over 14 years ago Actions #4 [ruby-core:37839]

  • Status changed from Assigned to Closed
  • Target version changed from 1.9.3 to 1.9.2

thank you for the notice, Shane.

Actions

Also available in: PDF Atom