aboutsummaryrefslogtreecommitdiff
path: root/src/delombok/lombok
diff options
context:
space:
mode:
Diffstat (limited to 'src/delombok/lombok')
-rw-r--r--src/delombok/lombok/delombok/PrettyPrinter.java13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/delombok/lombok/delombok/PrettyPrinter.java b/src/delombok/lombok/delombok/PrettyPrinter.java
index 1532319f..55210fbb 100644
--- a/src/delombok/lombok/delombok/PrettyPrinter.java
+++ b/src/delombok/lombok/delombok/PrettyPrinter.java
@@ -488,6 +488,19 @@ public class PrettyPrinter extends JCTree.Visitor {
}
@Override public void visitImport(JCImport tree) {
+ if (tree.qualid instanceof JCFieldAccess) {
+ JCFieldAccess fa = ((JCFieldAccess) tree.qualid);
+ if (fa.name.length() == 1 && fa.name.contentEquals("*")) {
+ if (fa.selected instanceof JCFieldAccess) {
+ JCFieldAccess lombokExperimental = (JCFieldAccess) fa.selected;
+ if (lombokExperimental.name.contentEquals("experimental") && lombokExperimental.selected instanceof JCIdent && ((JCIdent) lombokExperimental.selected).name.contentEquals("lombok")) {
+ // do not ever print lombok.experimental.*.
+ return;
+ }
+ }
+ }
+ }
+
aPrint("import ");
if (tree.staticImport) print("static ");
print(tree.qualid);