<i18n dev> RFR: 8311188: Simplify and modernize equals and hashCode in java.text [v5]

Pavel Rappo prappo at openjdk.org
Mon Jul 17 23:33:37 UTC 2023


> Please review this PR to use modern APIs and language features to simplify `equals` and `hashCode` in the java.text area.
> 
> * Some changes to `equals` and `hashCode` are refactoring rather than modernization. Such changes can be as trivial as rearranging, adding, or commenting checks.
> 
> * java.text area contains more classes whose `equals` and `hashCode` could be simplified; for example: sun.text.CompactByteArray or java.text.DigitList. However, I found no evidence of `equals` and `hashCode` in those classes being used in source or tests. Since writing new tests in this case seems unreasonable, I **excluded** those classes from this PR.

Pavel Rappo has updated the pull request incrementally with one additional commit since the last revision:

  Feedback

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/14752/files
  - new: https://git.openjdk.org/jdk/pull/14752/files/f1ce3a10..64177d8e

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

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

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


More information about the i18n-dev mailing list