aboutsummaryrefslogtreecommitdiff
path: root/src/delombok/lombok
diff options
context:
space:
mode:
authorRawi01 <Rawi01@users.noreply.github.com>2022-08-26 00:49:42 +0200
committerRawi01 <Rawi01@users.noreply.github.com>2022-08-26 00:51:49 +0200
commit646723f6d30404b2974af4fbefad5d8843460fea (patch)
tree603cbab84d859250638b4de0d537d66a8998940b /src/delombok/lombok
parentb57de5a558d310cdc80de0c304c45d268f6b989d (diff)
downloadlombok-646723f6d30404b2974af4fbefad5d8843460fea.tar.gz
lombok-646723f6d30404b2974af4fbefad5d8843460fea.tar.bz2
lombok-646723f6d30404b2974af4fbefad5d8843460fea.zip
[jdk19] Add support for JCConstantCaseLabel
Diffstat (limited to 'src/delombok/lombok')
-rw-r--r--src/delombok/lombok/delombok/PrettyPrinter.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/delombok/lombok/delombok/PrettyPrinter.java b/src/delombok/lombok/delombok/PrettyPrinter.java
index 605b9391..8e7bc7e5 100644
--- a/src/delombok/lombok/delombok/PrettyPrinter.java
+++ b/src/delombok/lombok/delombok/PrettyPrinter.java
@@ -1448,6 +1448,10 @@ public class PrettyPrinter extends JCTree.Visitor {
print(")");
}
+ void printConstantCaseLabel(JCTree tree) {
+ print((JCTree) readObject(tree, "expr", null));
+ }
+
@Override public void visitTry(JCTry tree) {
aPrint("try ");
List<?> resources = readObject(tree, "resources", List.nil());
@@ -1672,6 +1676,8 @@ public class PrettyPrinter extends JCTree.Visitor {
printGuardPattern(tree);
} else if (className.endsWith("$JCParenthesizedPattern")) { // Introduced in JDK17
printParenthesizedPattern(tree);
+ } else if (className.endsWith("$JCConstantCaseLabel")) { // Introduced in JDK19
+ printConstantCaseLabel(tree);
} else {
throw new AssertionError("Unhandled tree type: " + tree.getClass() + ": " + tree);
}