Recursively comparing

Archie Cobbs archie.cobbs at gmail.com
Tue Feb 27 17:08:59 UTC 2024


On Tue, Feb 27, 2024 at 10:48 AM John Bossons <jbossons at gmail.com> wrote:

> Where the set of field values stored for a value object field contains a
> field that is in turn a value object, this recursive definition would imply
> a recursive application of == to the set of field values stored for that
> object, would it not? Which sounds awfully close to a deep equals test for
> value object fields (but not identity fields).
>

That's a good point... so a simple (for Java developers) way to explain the
behavior might be: "Deep equals" for value objects and "== equals" for
non-value objects.

-Archie

-- 
Archie L. Cobbs
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/valhalla-dev/attachments/20240227/d0c8f343/attachment.htm>


More information about the valhalla-dev mailing list