classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cp-patches] java.text.DecimalFormat fixes


From: Tom Tromey
Subject: Re: [cp-patches] java.text.DecimalFormat fixes
Date: 13 Jun 2005 14:33:36 -0600
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

>>>>> "David" == David Gilbert <address@hidden> writes:

David> 2005-06-13  David Gilbert  <address@hidden>
David>  * java/text/DecimalFormat.java
David>  (DecimalFormat(String, DecimalFormatSymbols)): store clone of symbols;
David>  (equals): add missing checks;
David>  (getDecimalFormatSymbols): return clone of symbols;
David>  (setDecimalFormatSymbols): store clone of symbols.

This seems reasonable to me, but ...

David> -    if (! (obj instanceof DecimalFormat))
David> +    if (!(obj instanceof DecimalFormat))

I don't know about anybody else but I always put the space here.

David>      return (decimalSeparatorAlwaysShown == 
dup.decimalSeparatorAlwaysShown
David> -            && groupingSize == dup.groupingSize
David> -            && minExponentDigits == dup.minExponentDigits
David> -            && multiplier == dup.multiplier
David> -            && equals(negativePrefix, dup.negativePrefix)
David> -            && equals(negativeSuffix, dup.negativeSuffix)
David> -            && equals(positivePrefix, dup.positivePrefix)
David> -            && equals(positiveSuffix, dup.positiveSuffix)
David> -            && symbols.equals(dup.symbols)
David> -            && useExponentialNotation == dup.useExponentialNotation);
David> +      && groupingUsed == dup.groupingUsed
David> +      && groupingSize == dup.groupingSize
David> +      && multiplier == dup.multiplier
David> +      && useExponentialNotation == dup.useExponentialNotation)
David> +      && minExponentDigits == dup.minExponentDigits
David> +      && minimumIntegerDigits == dup.minimumIntegerDigits
David> +      && maximumIntegerDigits == dup.maximumIntegerDigits
David> +      && minimumFractionDigits == dup.minimumFractionDigits
David> +      && maximumFractionDigits == dup.maximumFractionDigits
David> +      && equals(negativePrefix, dup.negativePrefix)
David> +      && equals(negativeSuffix, dup.negativeSuffix)
David> +      && equals(positivePrefix, dup.positivePrefix)
David> +      && equals(positiveSuffix, dup.positiveSuffix)
David> +      && symbols.equals(dup.symbols);

The parens here seem weird.  The reason there are parens around the
entire expression originally is so that it formats correctly in emacs
(per GNU coding standards).  The close paren for
useExponentialNotation should be moved to the end of the expression.

Tom




reply via email to

[Prev in Thread] Current Thread [Next in Thread]