[lworld] RFR: 8346307: [lworld] Clarify identity vs value in Class, Objects, and document limitations of value objects [v9]

Roger Riggs rriggs at openjdk.org
Thu Jun 26 16:52:43 UTC 2025


On Wed, 25 Jun 2025 22:34:51 GMT, Chen Liang <liach at openjdk.org> wrote:

> We should document explicitly that all classes, including primitives and void, are considered identity when preview features are not enabled.

Primitives and void are not classes and never have identity. 
The primitive *wrappers*  and Void  *are* classes have identity if that's what you're meaning.
Interface classes never have identity (do not have ACC_SUPER/ACC_IDENTITY).  
Interface classes with --enable-preview are reported as value classes.

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

PR Comment: https://git.openjdk.org/valhalla/pull/1327#issuecomment-3009118676


More information about the valhalla-dev mailing list