diff options
author | Reinier Zwitserloot <reinier@zwitserloot.com> | 2014-05-08 06:25:38 +0200 |
---|---|---|
committer | Reinier Zwitserloot <reinier@zwitserloot.com> | 2014-05-20 23:43:08 +0200 |
commit | 4996428ea12be7e381d76614e34a15ad1cc6d275 (patch) | |
tree | ca5067b7b8f63eff6adeed83f8ff9339128d8ca7 /src/core/lombok/eclipse | |
parent | 05ca21b75e5c20e1e731d9141857f346bb3eca9f (diff) | |
download | lombok-4996428ea12be7e381d76614e34a15ad1cc6d275.tar.gz lombok-4996428ea12be7e381d76614e34a15ad1cc6d275.tar.bz2 lombok-4996428ea12be7e381d76614e34a15ad1cc6d275.zip |
@Delegate has moved to lombok.experimental.
Some work on the aliasing system to make that go smoothly.
Diffstat (limited to 'src/core/lombok/eclipse')
-rw-r--r-- | src/core/lombok/eclipse/EclipseImportList.java | 14 | ||||
-rw-r--r-- | src/core/lombok/eclipse/handlers/HandleGetter.java | 2 |
2 files changed, 12 insertions, 4 deletions
diff --git a/src/core/lombok/eclipse/EclipseImportList.java b/src/core/lombok/eclipse/EclipseImportList.java index 69246b3c..47167ec6 100644 --- a/src/core/lombok/eclipse/EclipseImportList.java +++ b/src/core/lombok/eclipse/EclipseImportList.java @@ -62,15 +62,23 @@ public class EclipseImportList implements ImportList { } @Override public boolean hasStarImport(String packageName) { - for (Map.Entry<String, String> e : LombokInternalAliasing.IMPLIED_EXTRA_STAR_IMPORTS.entrySet()) { - if (e.getValue().equals(packageName) && hasStarImport(e.getKey())) return true; - } if (isEqual(packageName, pkg)) return true; if ("java.lang".equals(packageName)) return true; + + if (pkg != null && pkg.tokens != null && pkg.tokens.length == 0) { + for (Map.Entry<String, Collection<String>> e : LombokInternalAliasing.IMPLIED_EXTRA_STAR_IMPORTS.entrySet()) { + if (isEqual(e.getKey(), pkg) && e.getValue().contains(packageName)) return true; + } + } + if (imports != null) for (ImportReference imp : imports) { if ((imp.bits & ASTNode.OnDemand) == 0) continue; if (imp.isStatic()) continue; if (isEqual(packageName, imp)) return true; + for (Map.Entry<String, Collection<String>> e : LombokInternalAliasing.IMPLIED_EXTRA_STAR_IMPORTS.entrySet()) { + if (isEqual(e.getKey(), imp) && e.getValue().contains(packageName)) return true; + } + } return false; } diff --git a/src/core/lombok/eclipse/handlers/HandleGetter.java b/src/core/lombok/eclipse/handlers/HandleGetter.java index 8cffaa2c..d3d974c9 100644 --- a/src/core/lombok/eclipse/handlers/HandleGetter.java +++ b/src/core/lombok/eclipse/handlers/HandleGetter.java @@ -34,7 +34,7 @@ import java.util.Map; import lombok.AccessLevel; import lombok.ConfigurationKeys; -import lombok.Delegate; +import lombok.experimental.Delegate; import lombok.Getter; import lombok.core.AST.Kind; import lombok.core.AnnotationValues; |