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

src/java.base/share/classes/java/lang/Object.java line 78:

> 76:  *          It is impossible for an {@code equals} method, or any other 
> Java
> 77:  *          code, to treat two indistinguishable objects as distinct, 
> even if
> 78:  *          they refer to value objects produced by different creation 
> events.

Are you sure you want to use the phrase "creation events" here? It's an 
overloaded term and kinda jumps out here (I could  imagine someone asking if 
this is about listener events or some other event).

I'm not sure about "they refer" too. Maybe it could be clearer to just say 
"even if the value objects ..".

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

PR Review Comment: https://git.openjdk.org/jdk/pull/34140#discussion_r4785314605

Reply via email to