[lworld] RFR: 8328543: [lworld] Library and test updates to use --enable-preview instead of ValhallaFeatures [v3]
Mandy Chung
mchung at openjdk.org
Wed Mar 27 16:38:38 UTC 2024
On Wed, 27 Mar 2024 01:51:55 GMT, Roger Riggs <rriggs at openjdk.org> wrote:
>> Update AccessFlag and tests to JEP 401 and use of --enable-preview instead of ValhallaFeatures.
>> Minor formatting change to java.lang.Character to allow it to be a value class with --enable-preview.
>> (The class file format version numbers will need to be updated when re-synching with the mainline).
>
> Roger Riggs has updated the pull request incrementally with one additional commit since the last revision:
>
> Corrected code and tests to use --enable-preview when refering to ACC_IDENTITY
Minor point: as you avoid dependency to `ACC_IDENTITY` in JVM CI, I wonder if you should do the same in JFR.
src/java.base/share/classes/java/lang/reflect/AccessFlag.java line 191:
> 189: * In Java SE 8 and above, the JVM treats the {@code ACC_SUPER}
> 190: * flag as set in every class file (JVMS {@jvms 4.1}).
> 191: * For class file versions up to but not including PreviewFeature VALUE_OBJECTS,
Suggestion:
* If preview feature is enabled,
* the {@code 0x0020} access flag bit is {@linkplain #IDENTITY IDENTITY access flag}.
src/jdk.internal.vm.ci/share/classes/jdk/vm/ci/hotspot/HotSpotModifiers.java line 56:
> 54:
> 55: public static int jvmClassModifiers() {
> 56: return PUBLIC | FINAL | INTERFACE | ABSTRACT | ANNOTATION | ENUM | SYNTHETIC | 0x0020; // ACC_IDENTITY temp constant to avoid preview dependency
Add `0x0020` only if preview is enabled.
-------------
Marked as reviewed by mchung (Committer).
PR Review: https://git.openjdk.org/valhalla/pull/1060#pullrequestreview-1958297604
PR Review Comment: https://git.openjdk.org/valhalla/pull/1060#discussion_r1541433993
PR Review Comment: https://git.openjdk.org/valhalla/pull/1060#discussion_r1541442515
More information about the valhalla-dev
mailing list