News

Key Takeaways Pattern matching for the switch control-flow statement is a new feature introduced in Java 17 and refined in subsequent versions. A pattern can be used in case labels as case p.
JEP 441, Pattern Matching for the switch, is completed in JDK 21, following four previews in JDKs 17-20 (JEPs 406, 420, 427, 433). It finalizes the feature, addressing feedback from previews, and ...