Skip to content

8389539: Clarify equivalence class sizing with value objects - #32158

Open
jddarcy wants to merge 1 commit into
openjdk:masterfrom
jddarcy:JDK-8389539
Open

8389539: Clarify equivalence class sizing with value objects#32158
jddarcy wants to merge 1 commit into
openjdk:masterfrom
jddarcy:JDK-8389539

Conversation

@jddarcy

@jddarcy jddarcy commented Jul 31, 2026

Copy link
Copy Markdown
Member

Another update to Object.equals to better support value classes.



Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issue

  • JDK-8389539: Clarify equivalence class sizing with value objects (Enhancement - P4)

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/32158/head:pull/32158
$ git checkout pull/32158

Update a local copy of the PR:
$ git checkout pull/32158
$ git pull https://git.openjdk.org/jdk.git pull/32158/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 32158

View PR using the GUI difftool:
$ git pr show -t 32158

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/32158.diff

Using Webrev

Link to Webrev Comment

@bridgekeeper

bridgekeeper Bot commented Jul 31, 2026

Copy link
Copy Markdown

👋 Welcome back darcy! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk

openjdk Bot commented Jul 31, 2026

Copy link
Copy Markdown

❗ This change is not yet ready to be integrated.
See the Progress checklist in the description for automated requirements.

@openjdk openjdk Bot changed the title JDK-8389539: Clarify equivalence class sizing with value objects 8389539: Clarify equivalence class sizing with value objects Jul 31, 2026
@openjdk openjdk Bot added the core-libs core-libs-dev@openjdk.org label Jul 31, 2026
@openjdk

openjdk Bot commented Jul 31, 2026

Copy link
Copy Markdown

@jddarcy The following label will be automatically applied to this pull request:

  • core-libs

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk Bot added the rfr Pull request is ready for review label Jul 31, 2026
@mlbridge

mlbridge Bot commented Jul 31, 2026

Copy link
Copy Markdown

Webrevs

* classes. For value classes, there is not necessarily a similar
* constraint as multiple indistinguishable value objects could be
* constructed, depending on the semantics of the particular value
* class.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would use the term "a single distinguishable element" instead of going into "multiple value objects" - "multiple" is an impression from the times when each constructor invocation creates a new distinguishable instance. Value objects are not necessarily constructed, either - in hotspot, you may load from a field twice and get two indistinguisable value objects, but another implementation may deduplicate them, and all these deduplication etc. are not visible to programs based on our specs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core-libs core-libs-dev@openjdk.org rfr Pull request is ready for review

Development

Successfully merging this pull request may close these issues.

2 participants