On Wed, 2 Dec 2026 22:52:12 GMT, Dan Smith <[email protected]> wrote:

>> The primary enhancement here is a more fleshed-out discussion about value 
>> objects, and particularly their interaction with `==`, in the 
>> `java.lang.Object` javadoc.
>> 
>> Then I've done some cleanup of links, directing discussion about "value 
>> objects" to `Object##value-objects`, "indistinguishable" to 
>> `Object##comparing-objects`. In some situations, it's more appropriate to 
>> link "has identity" to `Objects##hasIdentity` and "value class" to 
>> `Class#isValue`, but I've reduced reliance on those.
>> 
>> Browsable docs build here: 
>> https://cr.openjdk.org/~dlsmith/8389875/8389875-20261130/api/index.html
>> 
>> (Timeline note: this is a doc-only fix, I'm not worried about getting it 
>> integrated before the Dec 3 rampdown deadline.)
>> 
>> ---------
>> - [X] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Dan Smith has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Saying more about "identity" and creation events

This is good, but I think it is mildly incomplete; I’ve added a layer of 
suggested changes (as well as three minor bugfixes).

I have made the changes on top of this PR in my own repo.

https://github.com/rose00/jdk/tree/pr34140-review
https://github.com/rose00/jdk/commits/pr34140-review

Three layers, three commits:  1. objective bugs to fix, 2. changes which are 
not objectively needed but which I believe would be for the best, 3. a layer of 
inline comments on those changes, for decoration but NOT integration.

The changes are intended to link together the related javadoc nodes more 
robustly and discoverably.  I tried to stay with the principle of this PR, 
which appears to be "uses of terms link to their definitions".

IMO we need to give fair warning about two things, not pass over them in 
silence:  The changed cost model for the `==` operator and the conflict between 
IEEE 754 `==` and other versions of `==` (including value object comparison).

Suggested adoption path:


$ git fetch https://github.com/rose00/jdk.git pr34140-review
$ git cherry-pick 6ae42c6 f66ac10

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

Changes requested by jrose (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/34140#pullrequestreview-6182704586

Reply via email to