RFR: 8349860: Make Class.isArray(), Class.isInterface() and Class.isPrimitive() non-native

Chen Liang liach at openjdk.org
Wed Feb 19 02:56:58 UTC 2025


On Wed, 19 Feb 2025 02:35:25 GMT, Dean Long <dlong at openjdk.org> wrote:

>> The method is isPrimitive so I think I had to give the field isPrimitiveType as a name, so this is wrong.
>
> I don't know if we have a style guide that covers this, but I believe the method and field could both be named `isPrimitive`.

I would personally name such a boolean field `primitive`, but I don't have a strong preference on the field naming as long as its references in tests and other locations are correct. In addition, I believe this field may soon be widened to carry more hotspot-specific flags (such as hidden, etc.) so the name is bound to change.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23572#discussion_r1960876569


More information about the core-libs-dev mailing list