[lworld] RFR: 8372697: [lworld] compiler/c2/irTests/scalarReplacement/ScalarReplacementWithGCBarrierTests.java fails with --enable-preview

Paul Hübner phubner at openjdk.org
Tue Dec 2 09:18:31 UTC 2025


On Tue, 2 Dec 2025 09:08:49 GMT, Marc Chevalier <mchevalier at openjdk.org> wrote:

>> FWIW there's also `jdk.internal.misc.PreviewFeatures` that can be used to check if preview features are enabled at runtime.
>
> PreviewFeatures.isEnabled() is internal and not accessible without adding some `@module` in each IR test. That seems like an excessive burden.
> 
> Doing it more fine-grained was on purpose. @TobiHartmann an opinion? I tihnk it can make a mess with other project repos, but I don't remember the exact scenario.

Right, adding it to every test doesn't feel like the way to go! I'm not too fussed about it, it was just a suggestion, feel free to disregard ;)

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

PR Review Comment: https://git.openjdk.org/valhalla/pull/1767#discussion_r2580308726


More information about the valhalla-dev mailing list