RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v10]

Jan Lahoda jlahoda at openjdk.org
Thu May 11 16:49:14 UTC 2023


> This is the first draft of a patch for JEP 440 and JEP 441. Changes included:
> 
>  - the pattern matching for switch and record patterns features are made final, together with updates to tests.
>  - parenthesized patterns are removed.
>  - qualified enum constants are supported for case labels.
> 
> This change herein also includes removal record patterns in for each loop, which may be split into a separate PR in the future.

Jan Lahoda has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 43 commits:

 - Merge branch 'master' into JDK-8300543
 - Updating MatchException javadoc.
 - Merge branch 'master' into JDK-8300543
 - Reverting use of record patterns in enhanced for loop.
 - Cleanup: reflecting review feedback.
 - Merge branch 'master' into JDK-8300543
 - Reflecting review changes.
 - Adding test.
 - Removing redundant continue, as noted on the review.
 - Replacing use of mutable callsite with a mutable state.
 - ... and 33 more: https://git.openjdk.org/jdk/compare/2bf7ac58...69ba2a57

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

Changes: https://git.openjdk.org/jdk/pull/13074/files
 Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13074&range=09
  Stats: 4256 lines in 158 files changed: 2027 ins; 1716 del; 513 mod
  Patch: https://git.openjdk.org/jdk/pull/13074.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/13074/head:pull/13074

PR: https://git.openjdk.org/jdk/pull/13074


More information about the core-libs-dev mailing list