[lworld] RFR: 8328543: [lworld] Library and test updates to use --enable-preview instead of ValhallaFeatures [v6]

Chen Liang liach at openjdk.org
Thu Mar 28 17:23:43 UTC 2024


On Thu, 28 Mar 2024 14:11:58 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:
> 
>   Remove extr enable preview and test code

src/java.base/share/classes/java/lang/reflect/AccessFlag.java line 364:

> 362:                public Set<Location> apply(ClassFileFormatVersion cffv) {
> 363:                    return (cffv.compareTo(ClassFileFormatVersion.RELEASE_2)  >= 0 &&
> 364:                            cffv.compareTo(ClassFileFormatVersion.RELEASE_16) <= 0) ?

I believe we still want to keep the strict field modifier for value class fields.

test/jdk/java/lang/reflect/AccessFlag/VersionedLocationsTest.java line 274:

> 272:                 Set.of(Location.METHOD) :
> 273:                         (cffv.compareTo(ClassFileFormatVersion.RELEASE_22) >= 0)
> 274:                                 ? Set.of(Location.FIELD) : Set.of();

Same remark

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

PR Review Comment: https://git.openjdk.org/valhalla/pull/1060#discussion_r1543350802
PR Review Comment: https://git.openjdk.org/valhalla/pull/1060#discussion_r1543353968



More information about the valhalla-dev mailing list