[java] Remove support for named record patterns

This commit is contained in:
Andreas Dangel
2023-02-03 19:54:19 +01:00
parent 4ec06b71fe
commit 3ac021da02

View File

@ -3,6 +3,7 @@
* SwitchLabel simplified * SwitchLabel simplified
* Support "JEP 432: Record Patterns (Second Preview)" for Java 20 Preview * Support "JEP 432: Record Patterns (Second Preview)" for Java 20 Preview
* ForStatement allows record patterns * ForStatement allows record patterns
* Removed named record patterns (optional VariableDeclaratorId following the pattern)
* Remove support for Java 18 preview language features * Remove support for Java 18 preview language features
* GuardedPattern is removed * GuardedPattern is removed
* Andreas Dangel 02/2023 * Andreas Dangel 02/2023
@ -1838,7 +1839,7 @@ void TypePattern():
void RecordPattern(): void RecordPattern():
{ checkForRecordPatterns(); } { checkForRecordPatterns(); }
{ {
(Annotation())* ReferenceType() RecordStructurePattern() [ VariableDeclaratorId() ] (Annotation())* ReferenceType() RecordStructurePattern()
} }
void RecordStructurePattern() #ComponentPatternList: void RecordStructurePattern() #ComponentPatternList: