bugfix: The previous fix to stop removal of lombok annotations unless delombok is running actually only worked for the import, and still deleted the annotation. No longer.

This commit is contained in:
Reinier Zwitserloot committed 2010-07-20 12:06:20 +02:00
1 parent db6a456557
commit a9ed18ac85
1 file changed
+3 -1
@@ -63,10 +63,12 @@ public class JavacHandlerUtil {
}
/**
* Removes the annotation from javac's AST, then removes it from lombok's AST,
* Removes the annotation from javac's AST (it remains in lombok's AST),
* then removes any import statement that imports this exact annotation (not star imports).
* Only does this if the DeleteLombokAnnotations class is in the context.
*/
public static void markAnnotationAsProcessed(JavacNode annotation, Class<? extends Annotation> annotationType) {
if (!annotation.shouldDeleteLombokAnnotations()) return;
JavacNode parentNode = annotation.directUp();
switch (parentNode.getKind()) {
case FIELD: