diff options
author | Warren Levy <warrenl@redhat.com> | 2001-01-10 10:26:52 +0000 |
---|---|---|
committer | Warren Levy <warrenl@redhat.com> | 2001-01-10 10:26:52 +0000 |
commit | c5f51cfb7b047fdf10933a9df257519dafbe2b27 (patch) | |
tree | 6fa22980735ea448b799f17eecb4cc54e16a2dd1 | |
parent | feede3e92558718bbe9c9fa1518be892df63fcbd (diff) | |
download | classpath-c5f51cfb7b047fdf10933a9df257519dafbe2b27.tar.gz |
* java/math/BigDecimal.java (divide): Fixed comment.
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | java/math/BigDecimal.java | 2 |
2 files changed, 5 insertions, 1 deletions
@@ -1,5 +1,9 @@ 2001-01-10 Warren Levy <warrenl@redhat.com> + * java/math/BigDecimal.java (divide): Fixed comment. + +2001-01-10 Warren Levy <warrenl@redhat.com> + * java/math/BigDecimal.java (divide): Check newScale for validity. Ensure that BigInteger.pow() is called with a non-negative value. (setScale (int)): New public method. diff --git a/java/math/BigDecimal.java b/java/math/BigDecimal.java index 007f3a324..6fbd9271e 100644 --- a/java/math/BigDecimal.java +++ b/java/math/BigDecimal.java @@ -146,7 +146,7 @@ public class BigDecimal extends Number implements Comparable { if (power < 0) { // Effectively increase the scale of val to avoid an - // IllegalArgumentException for a negative power. + // ArithmeticException for a negative power. valIntVal = valIntVal.multiply (BigInteger.valueOf (10).pow (-power)); power = 0; } |