aboutsummaryrefslogtreecommitdiff
path: root/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java
diff options
context:
space:
mode:
authorJohnPaulTaylorII <johnpaultaylorii@gmail.com>2022-02-23 13:29:58 -0500
committerJohnPaulTaylorII <johnpaultaylorii@gmail.com>2022-02-23 13:29:58 -0500
commit22444b78e2b12680929acf1576b15a0717f267e2 (patch)
tree8cacb53f67b5133f09d2790347fbdc67e2ae83cf /src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java
parent560ded50127b12bd8168f8ae2bada47253f15bc8 (diff)
downloadlombok-22444b78e2b12680929acf1576b15a0717f267e2.tar.gz
lombok-22444b78e2b12680929acf1576b15a0717f267e2.tar.bz2
lombok-22444b78e2b12680929acf1576b15a0717f267e2.zip
Fixes #3120
Diffstat (limited to 'src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java')
-rw-r--r--src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java b/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java
index 65e2c5c8..c313cf51 100644
--- a/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java
+++ b/src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java
@@ -2608,6 +2608,13 @@ public class EclipseHandlerUtil {
applyAnnotationToVarDecl(typeNode, arg, lib.getNullableAnnotation(), lib.isTypeUse());
}
+ public static void createRelevantNullableAnnotation(EclipseNode typeNode, Argument arg, List<NullAnnotationLibrary> applied) {
+ NullAnnotationLibrary lib = typeNode.getAst().readConfiguration(ConfigurationKeys.ADD_NULL_ANNOTATIONS);
+ if (lib == null || applied.contains(lib)) return;
+
+ applyAnnotationToVarDecl(typeNode, arg, lib.getNullableAnnotation(), lib.isTypeUse());
+ }
+
public static void createRelevantNonNullAnnotation(EclipseNode typeNode, Argument arg) {
NullAnnotationLibrary lib = typeNode.getAst().readConfiguration(ConfigurationKeys.ADD_NULL_ANNOTATIONS);
if (lib == null) return;