BigDecimal object from an Integer.
* test/bigdecimal/test_bigdecimal.rb (test_new_with_integer):
add for testing the above change.
* ext/bigdecimal/bigdecimal.c (BigDecimal_global_new): replace its body
with a BigDecimal_new call.
* test/bigdecimal/test_bigdecimal.rb (test_global_new_with_integer):
add for testing the above change.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31863 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
return the result of a block.
* test/bigdecimal/test_bigdecimal.rb (test_save_limit):
add a test for the above change.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29363 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
return the result of a block.
* test/bigdecimal/test_bigdecimal.rb (test_save_rounding_mode):
add a test for the above change.
* test/bigdecimal/test_bigdecimal.rb (test_save_exception_mode):
add a test for the return value of BigDecimal.save_exception_mode.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29361 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
converting symbol to rounding mode number.
* ext/bigdecimal/bigdecimal.c (BigDecimal_mode, BigDecimal_round):
support to specify rounding mode by symbol.
* test/bigdecimal/test_bigdecimal.rb (test_mode, test_round):
add tests for avobe changes.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29295 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
and half-even. This change is based on the patch created by Matthew
Willson, the reporter of this bug. [Bug #3803] [ruby-core:32136]
* test/bigdecimal/test_bigdecimal.rb: add tests for above changes.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29293 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/bigdecimal/test_bigdecimal.rb (test_to_f): added test for the above changes.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29078 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/bigdecimal/lib/bigdecimal/math.rb (BigMath.exp): modify the behaviors for infinity arguments as same as Math.exp.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28533 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
collected. based on a patch masaya tarui at [ruby-dev:41213].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27665 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
was Infinity, not 0.
* test/bigdecimal/test_bigdecimal.rb: add a test for above.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26428 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
improved precision and performance. based on a patch from Makoto
Yamashita in [ruby-core:25600] and [ruby-core:25602].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25013 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
division should raise FloatDomainError if mode
VP_EXCEPTION_ZERODIVIDE is set. [ruby-dev:37204]
* ext/bigdecimal/bigdecimal.c (BigDecimal_mode): should handle
VP_EXCEPTION_ZERODIVIDE.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20366 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
test updated. a patch from TAKANO Mitsuhiro <takano32 at jus.or.jp> in
[ruby-dev:36736].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19820 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
updated. a patch from TAKANO Mitsuhiro <takano32 at jus.or.jp>
in [ruby-dev:36669].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19694 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
precision specification. a patch from TAKANO Mitsuhiro
<takano32 at jus.or.jp> in [ruby-dev:36634].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19642 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
size dependent test. pointed out by TAKANO Mitsuhiro <takano32 AT
jus.or.jp>.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e