Project

General

Profile

Actions

Bug #206

closed

BigDecimal precision in divmod

Added by Anonymous over 16 years ago. Updated over 13 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
[ruby-core:17472]

Description

=begin
In some cases the precision of BigDecimal#divmod is not high enough, for
example:

BigDecimal('1').divmod(BigDecimal('3E-9'))[0] #=> 0.3E9,

but really should be 0.333333333E9

More examples on these can be found in Rubyspec:
spec/ruby/1.8/library/bigdecimal/divmod_spec.rb:101

This is behavior is present in 1.8.6 and 1.8.7
=end

Actions

Also available in: Atom PDF

Like0
Like0