diff options
Diffstat (limited to 'src/share/classes/java/math/MathContext.java')
-rw-r--r-- | src/share/classes/java/math/MathContext.java | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/src/share/classes/java/math/MathContext.java b/src/share/classes/java/math/MathContext.java index d4119ff8db..3294668b0c 100644 --- a/src/share/classes/java/math/MathContext.java +++ b/src/share/classes/java/math/MathContext.java @@ -126,19 +126,6 @@ public final class MathContext implements Serializable { */ final RoundingMode roundingMode; - /** - * Lookaside for the rounding points (the numbers which determine - * whether the coefficient of a number will require rounding). - * These will be present if {@code precision > 0} and - * {@code precision <= MAX_LOOKASIDE}. In this case they will share the - * {@code BigInteger int[]} array. Note that the transients - * cannot be {@code final} because they are reconstructed on - * deserialization. - */ - transient BigInteger roundingMax = null; - transient BigInteger roundingMin = null; - private static final int MAX_LOOKASIDE = 1000; - /* ----- Constructors ----- */ /** @@ -173,11 +160,6 @@ public final class MathContext implements Serializable { throw new NullPointerException("null RoundingMode"); precision = setPrecision; - if (precision > 0 && precision <= MAX_LOOKASIDE) { - roundingMax = BigInteger.TEN.pow(precision); - roundingMin = roundingMax.negate(); - } - roundingMode = setRoundingMode; return; } @@ -221,10 +203,6 @@ public final class MathContext implements Serializable { throw new IllegalArgumentException("Digits < 0"); // the other parameters cannot be invalid if we got here precision = setPrecision; - if (precision > 0 && precision <= MAX_LOOKASIDE) { - roundingMax = BigInteger.TEN.pow(precision); - roundingMin = roundingMax.negate(); - } } /** @@ -343,11 +321,6 @@ public final class MathContext implements Serializable { String message = "MathContext: null roundingMode in stream"; throw new java.io.StreamCorruptedException(message); } - // Set the lookaside, if applicable - if (precision <= MAX_LOOKASIDE) { - roundingMax = BigInteger.TEN.pow(precision); - roundingMin = roundingMax.negate(); - } } } |