On Fri, 23 Jan 2026 03:00:04 GMT, Chris Plummer <[email protected]> wrote:
> What happens if not running in preview mode? Value classes are not supported > in that case, but as implemented this API will say they are supported, > leading to isValueClass() looking at modifiers in a way that is not > compatible when value classes are not supported. It should work correctly. The IDENTITY modifier bit is not used for other purposes in JDK 27 (Alex, please, fix me if it is wrong). So, the check for version >= 27 is needed. If preview is not enabled in target VM, so it does not support value classes then the IDENTITY modifier bit will be always set which results in `isValueClass()` to always return `false`. ------------- PR Review Comment: https://git.openjdk.org/valhalla/pull/1834#discussion_r2722702002
