diff options
author | Rawi01 <Rawi01@users.noreply.github.com> | 2020-09-12 14:35:40 +0200 |
---|---|---|
committer | Rawi01 <Rawi01@users.noreply.github.com> | 2020-09-12 14:35:40 +0200 |
commit | fa0b5249cf5fee28d9be13ecdf0225f651f686aa (patch) | |
tree | 881cc34c60f69d7895be222201a059d268d91cf0 /src/core/lombok/eclipse/handlers | |
parent | 0064c534273d9fb877f7e570f7a430060c88a5fb (diff) | |
download | lombok-fa0b5249cf5fee28d9be13ecdf0225f651f686aa.tar.gz lombok-fa0b5249cf5fee28d9be13ecdf0225f651f686aa.tar.bz2 lombok-fa0b5249cf5fee28d9be13ecdf0225f651f686aa.zip |
Support With(By) on records and record components
This also replaces the javac/eclipse specific code for searching the
parent fields of an annotation by a search based on the lombok AST.
Diffstat (limited to 'src/core/lombok/eclipse/handlers')
-rw-r--r-- | src/core/lombok/eclipse/handlers/HandleWithBy.java | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/core/lombok/eclipse/handlers/HandleWithBy.java b/src/core/lombok/eclipse/handlers/HandleWithBy.java index 40e2d524..5f229aaf 100644 --- a/src/core/lombok/eclipse/handlers/HandleWithBy.java +++ b/src/core/lombok/eclipse/handlers/HandleWithBy.java @@ -29,9 +29,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; import java.util.Collections; -import java.util.LinkedHashSet; import java.util.List; -import java.util.Set; import org.eclipse.jdt.internal.compiler.ast.ASTNode; import org.eclipse.jdt.internal.compiler.ast.AllocationExpression; @@ -138,10 +136,7 @@ public class HandleWithBy extends EclipseAnnotationHandler<WithBy> { switch (node.getKind()) { case FIELD: - Set<EclipseNode> fields = new LinkedHashSet<EclipseNode>(); - fields.add(node); - fields.addAll(annotationNode.upFromAnnotationToFields()); - createWithByForFields(level, fields, annotationNode, true, onMethod); + createWithByForFields(level, annotationNode.upFromAnnotationToFields(), annotationNode, true, onMethod); break; case TYPE: if (!onMethod.isEmpty()) { |