diff options
author | aclement <aclement> | 2006-08-18 08:21:58 +0000 |
---|---|---|
committer | aclement <aclement> | 2006-08-18 08:21:58 +0000 |
commit | 59123b0efba484e81625d403ca36768e149bd451 (patch) | |
tree | 74a5450c0ea65e9fd573665806aa1ede0d867c16 /tests | |
parent | 3b49ad4a35edfebc8f92f7dd7daa05387c0ad7de (diff) | |
download | aspectj-59123b0efba484e81625d403ca36768e149bd451.tar.gz aspectj-59123b0efba484e81625d403ca36768e149bd451.zip |
test and fix for 154332: broken java.lang.<annotation> processing
Diffstat (limited to 'tests')
-rw-r--r-- | tests/bugs153/pr154332/Annot.java | 45 | ||||
-rw-r--r-- | tests/src/org/aspectj/systemtest/ajc153/Ajc153Tests.java | 1 | ||||
-rw-r--r-- | tests/src/org/aspectj/systemtest/ajc153/ajc153.xml | 9 |
3 files changed, 55 insertions, 0 deletions
diff --git a/tests/bugs153/pr154332/Annot.java b/tests/bugs153/pr154332/Annot.java new file mode 100644 index 000000000..183c82859 --- /dev/null +++ b/tests/bugs153/pr154332/Annot.java @@ -0,0 +1,45 @@ +import java.lang.annotation.*; + +@Deprecated @Marker + +public aspect Annot { + + + + pointcut test() : within(@Marker *);// *); + + + + declare warning: staticinitialization(@Deprecated *): "deprecated"; + + declare warning: staticinitialization(@Marker *): "marker"; + + + + public static void main(String argz[]) { + + new Baz().foo(); + + } + +} + + + +@Deprecated @Marker + +class Baz { + + public void foo() {} + +} + + + +@Retention(RetentionPolicy.RUNTIME) + + @interface Marker { + + + +}
\ No newline at end of file diff --git a/tests/src/org/aspectj/systemtest/ajc153/Ajc153Tests.java b/tests/src/org/aspectj/systemtest/ajc153/Ajc153Tests.java index afae345b9..e2d6256f2 100644 --- a/tests/src/org/aspectj/systemtest/ajc153/Ajc153Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc153/Ajc153Tests.java @@ -27,6 +27,7 @@ public class Ajc153Tests extends org.aspectj.testing.XMLBasedAjcTestCase { // public void testArgnamesAndJavac_pr148381() { runTest("argNames and javac");} // public void testCFlowXMLAspectLTW_pr149096() { runTest("cflow xml concrete aspect"); } // public void testAmbiguousBinding_pr121805() { runTest("ambiguous binding");} + public void testIncorrectDeprecatedAnnotationProcessing_pr154332() { runTest("incorrect deprecated annotation processing");} public void testPipeliningProblemWithAnnotationsDecp_pr153380_1() { runTest("pipelining decps");} public void testUnwantedPointcutWarning_pr148219() { runTest("unwanted warning for pointcut");} public void testDecpAndCflowadderMungerClash_pr152631() { runTest("decp and cflowadder munger clash");} diff --git a/tests/src/org/aspectj/systemtest/ajc153/ajc153.xml b/tests/src/org/aspectj/systemtest/ajc153/ajc153.xml index e7c382284..1951d4b3e 100644 --- a/tests/src/org/aspectj/systemtest/ajc153/ajc153.xml +++ b/tests/src/org/aspectj/systemtest/ajc153/ajc153.xml @@ -23,6 +23,15 @@ </compile> </ajc-test> + <ajc-test dir="bugs153/pr154332" title="incorrect deprecated annotation processing"> + <compile files="Annot.java" options="-1.5"> + <message kind="warning" line="5" text="marker"/> + <message kind="warning" line="31" text="marker"/> + <message kind="warning" line="5" text="deprecated"/> + <message kind="warning" line="31" text="deprecated"/> + </compile> + </ajc-test> + <ajc-test dir="bugs153/pr148381" title="argNames and javac"> <!--compile files="C.java" options="-1.5"/> <compile files="A.java" options="-1.5"/--> |