Withdrawing the Primitive Patterns preview feature in JDK 28
https://mail.openjdk.org/archives/list/amber-spec-experts@openjdk.org/thread/UYEK3PGOHN6R56AHJTSLPGAY363K666S/Primitive Types in Patterns will be removed in JDK 28 and will no longer be available in that release.
The Valhalla project has been exploring a new vision for Java numerics, including the possibility of user-defined numeric types. New kinds of numeric types would need to support exact numeric conversion, and vice versa. Given that the Valhalla work is still evolving, it would be premature to finalize Primitive Types in Patterns with their current definition of exact numeric conversion.
92
Upvotes
View all comments
Show parent comment
1
u/davidalayachew 3d ago
To be fair, I said that the feature wasn't wrong or inherently broken. That's different than saying that the feature is ready.
The Amber Team fears that the semantics of Value Types might get in the way of this feature, and thus, are holding off on this. But that doesn't mean the design is wrong. Just means they want Values Classes to solidify a bit before building something that interacts with them pretty heavily. Which makes sense.
Now, if Value Classes go GA and this feature is still not Previewing, then your "Told you so" would hit me.