From 3c4a44d338cd120716df6952a273f1f48eb5076c Mon Sep 17 00:00:00 2001 From: aclement Date: Sat, 31 Jan 2009 22:06:22 +0000 Subject: [PATCH] 195090: ajc$ local vars that aren't used getting reported when using -warn:+unusedArgument --- tests/bugs164/pr195090.java | 19 +++++++++++++++++++ .../systemtest/ajc164/Ajc164Tests.java | 10 +++++++--- .../org/aspectj/systemtest/ajc164/ajc164.xml | 5 +++++ 3 files changed, 31 insertions(+), 3 deletions(-) create mode 100644 tests/bugs164/pr195090.java diff --git a/tests/bugs164/pr195090.java b/tests/bugs164/pr195090.java new file mode 100644 index 000000000..515a135be --- /dev/null +++ b/tests/bugs164/pr195090.java @@ -0,0 +1,19 @@ +/** + * Helper interface. + */ +interface Interface{ + boolean methodToBeImplemented(); +} + +/** + * Exposes the ajc$this_ is never read warning. + */ +public aspect pr195090 { + public boolean Interface.methodToBeImplemented() { + return returnTrue(); + } + + public static boolean returnTrue() { + return true; + } +} diff --git a/tests/src/org/aspectj/systemtest/ajc164/Ajc164Tests.java b/tests/src/org/aspectj/systemtest/ajc164/Ajc164Tests.java index 0752ebeaa..124a005b0 100644 --- a/tests/src/org/aspectj/systemtest/ajc164/Ajc164Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc164/Ajc164Tests.java @@ -24,13 +24,17 @@ import org.aspectj.testing.XMLBasedAjcTestCase; public class Ajc164Tests extends org.aspectj.testing.XMLBasedAjcTestCase { + public void testAjcThisNotRead() { + runTest("ajcthis not read"); + } + public void testRecursiveCflow() { runTest("recursive cflow"); } - //public void testAopConfig1() { - // runTest("aop config - 1"); - //} + // public void testAopConfig1() { + // runTest("aop config - 1"); + // } public void testAnnoDecprecedence_pr256779() { runTest("anno decprecedence"); diff --git a/tests/src/org/aspectj/systemtest/ajc164/ajc164.xml b/tests/src/org/aspectj/systemtest/ajc164/ajc164.xml index 1ddce0bb4..2519577d4 100644 --- a/tests/src/org/aspectj/systemtest/ajc164/ajc164.xml +++ b/tests/src/org/aspectj/systemtest/ajc164/ajc164.xml @@ -8,6 +8,11 @@ + + + + + -- 2.39.5