aboutsummaryrefslogtreecommitdiff
path: root/src/core/lombok
diff options
context:
space:
mode:
authorRoel Spilker <r.spilker@gmail.com>2012-03-05 20:18:10 +0100
committerRoel Spilker <r.spilker@gmail.com>2012-03-05 20:18:10 +0100
commit4c8cc228e8f72972fa91a6c96d6e5bdf5ab6905c (patch)
tree9756c0ca5699e261d6851180fd6160436593ea67 /src/core/lombok
parent7988f17c28fb8f6a6f99a612f85ee804bed38dfe (diff)
parent73dab3e96613521b8769b29e6a3c7e4ee5f26911 (diff)
downloadlombok-4c8cc228e8f72972fa91a6c96d6e5bdf5ab6905c.tar.gz
lombok-4c8cc228e8f72972fa91a6c96d6e5bdf5ab6905c.tar.bz2
lombok-4c8cc228e8f72972fa91a6c96d6e5bdf5ab6905c.zip
Issue 348: @Delegate should also generate @Deprecated when the interface methods javadoc contains@deprecated
Diffstat (limited to 'src/core/lombok')
-rw-r--r--src/core/lombok/javac/handlers/HandleDelegate.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/core/lombok/javac/handlers/HandleDelegate.java b/src/core/lombok/javac/handlers/HandleDelegate.java
index 41e587f8..18817d49 100644
--- a/src/core/lombok/javac/handlers/HandleDelegate.java
+++ b/src/core/lombok/javac/handlers/HandleDelegate.java
@@ -22,6 +22,7 @@
package lombok.javac.handlers;
import static lombok.javac.handlers.JavacHandlerUtil.*;
+import static com.sun.tools.javac.code.Flags.*;
import java.util.ArrayList;
import java.util.Arrays;
@@ -335,7 +336,7 @@ public class HandleDelegate extends JavacAnnotationHandler<Delegate> {
ExecutableType methodType = (ExecutableType) types.asMemberOf(ct, member);
String sig = printSig(methodType, member.name, types);
if (!banList.add(sig)) continue; //If add returns false, it was already in there
- boolean isDeprecated = exElem.getAnnotation(Deprecated.class) != null;
+ boolean isDeprecated = (member.flags() & DEPRECATED) != 0;
signatures.add(new MethodSig(member.name, methodType, isDeprecated, exElem));
}