From 22444b78e2b12680929acf1576b15a0717f267e2 Mon Sep 17 00:00:00 2001 From: JohnPaulTaylorII Date: Wed, 23 Feb 2022 13:29:58 -0500 Subject: Fixes #3120 --- src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/core/lombok/eclipse/handlers/EclipseHandlerUtil.java') 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 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; -- cgit