[lworld] RFR: 8327636: [lworld] Make primitive wrappers be value class if preview feature is enabled
Mandy Chung
mchung at openjdk.org
Thu Mar 7 22:49:30 UTC 2024
As specified in JEP 401, when preview features are enabled, the following standard library classes are considered to be value classes:
java.lang.Byte
java.lang.Short
java.lang.Integer
java.lang.Long
java.lang.Float
java.lang.Double
java.lang.Boolean
java.lang.Character
java.util.Optional
java.lang.Number
java.lang.Record
These value classes are loaded only if --enable-preview is set. All valhalla tests should have preview enabled to ensure testing with the proper set of library classes.
Testing: Run `jdk_valhalla` and `hotspot_valhalla_runtime` with `-Xint` with and without `--enable-preview`. The result is pretty good. [JDK-8327637](https://bugs.openjdk.org/browse/JDK-8327637) and [JDK-8327639](https://bugs.openjdk.org/browse/JDK-8327639) need further investigation.
-------------
Commit messages:
- 8327636: [lworld] Make primitive wrappers be value class if preview feature is enabled
Changes: https://git.openjdk.org/valhalla/pull/1040/files
Webrev: https://webrevs.openjdk.org/?repo=valhalla&pr=1040&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8327636
Stats: 23 lines in 3 files changed: 17 ins; 4 del; 2 mod
Patch: https://git.openjdk.org/valhalla/pull/1040.diff
Fetch: git fetch https://git.openjdk.org/valhalla.git pull/1040/head:pull/1040
PR: https://git.openjdk.org/valhalla/pull/1040
More information about the valhalla-dev
mailing list