aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@zwitserloot.com>2013-06-25 13:03:42 +0200
committerReinier Zwitserloot <reinier@zwitserloot.com>2013-06-25 13:03:42 +0200
commit420e0dcb53654f41d0f79b004d6c750414e6ba7a (patch)
tree0c9ed11c074fd9549c53d2f3f2609d2150f39f94 /src
parentfb32de51afaef2e2a3135b7230f47add005bae69 (diff)
downloadlombok-420e0dcb53654f41d0f79b004d6c750414e6ba7a.tar.gz
lombok-420e0dcb53654f41d0f79b004d6c750414e6ba7a.tar.bz2
lombok-420e0dcb53654f41d0f79b004d6c750414e6ba7a.zip
deprecating the old Value annotation also added deprecation warnings to where we still support it as an alias. fixed.
Diffstat (limited to 'src')
-rw-r--r--src/core/lombok/javac/handlers/HandleValue.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core/lombok/javac/handlers/HandleValue.java b/src/core/lombok/javac/handlers/HandleValue.java
index c0127f3c..15fb4781 100644
--- a/src/core/lombok/javac/handlers/HandleValue.java
+++ b/src/core/lombok/javac/handlers/HandleValue.java
@@ -22,6 +22,9 @@
package lombok.javac.handlers;
import static lombok.javac.handlers.JavacHandlerUtil.*;
+
+import java.lang.annotation.Annotation;
+
import lombok.AccessLevel;
import lombok.core.AnnotationValues;
import lombok.core.HandlerPriority;
@@ -45,7 +48,9 @@ import com.sun.tools.javac.tree.JCTree.JCModifiers;
@HandlerPriority(-512) //-2^9; to ensure @EqualsAndHashCode and such pick up on this handler making the class final and messing with the fields' access levels, run earlier.
public class HandleValue extends JavacAnnotationHandler<Value> {
@Override public void handle(AnnotationValues<Value> annotation, JCAnnotation ast, JavacNode annotationNode) {
- deleteAnnotationIfNeccessary(annotationNode, Value.class, lombok.experimental.Value.class);
+ @SuppressWarnings("deprecation")
+ Class<? extends Annotation> oldExperimentalValue = lombok.experimental.Value.class;
+ deleteAnnotationIfNeccessary(annotationNode, Value.class, oldExperimentalValue);
JavacNode typeNode = annotationNode.up();
boolean notAClass = !isClass(typeNode);