<i18n dev> RFR: 8341445: DecimalFormatSymbols setters should throw NPE [v4]

Justin Lu jlu at openjdk.org
Fri Oct 11 22:23:42 UTC 2024


> Please review this PR which improves the safety of equality checking for DecimalFormatSymbols. As certain setters did not throw NPE, this allowed for NPE in the equality method. This PR now updates the setters to throw NPE.
> 
> In addition to the NPEs, there is also a behavioral change that `setInternationalCurrencySymbol` no longer sets currency to null if the `currencyCode` is invalid. Instead, it simply does not update `currency`. This must be done, because we do not want to allow nullable instance variables post `initalizeCurrency`.

Justin Lu has updated the pull request incrementally with one additional commit since the last revision:

  reflect review

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/21315/files
  - new: https://git.openjdk.org/jdk/pull/21315/files/91b1c78f..d0686b35

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=21315&range=03
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=21315&range=02-03

  Stats: 9 lines in 1 file changed: 0 ins; 4 del; 5 mod
  Patch: https://git.openjdk.org/jdk/pull/21315.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/21315/head:pull/21315

PR: https://git.openjdk.org/jdk/pull/21315


More information about the i18n-dev mailing list