aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authoraclement <aclement>2008-08-21 18:13:04 +0000
committeraclement <aclement>2008-08-21 18:13:04 +0000
commitf8fac37d1e4ec74eb13389c0968f4868d0116ad0 (patch)
treefe1959ae1b513c3fae6955b985298ad48962804e /tests
parent8413359b37dce1f999017935007e6ce56f0fe641 (diff)
downloadaspectj-f8fac37d1e4ec74eb13389c0968f4868d0116ad0.tar.gz
aspectj-f8fac37d1e4ec74eb13389c0968f4868d0116ad0.zip
194429: test and fix: include context in error
Diffstat (limited to 'tests')
-rw-r--r--tests/bugs162/pr194429/A.java18
-rw-r--r--tests/src/org/aspectj/systemtest/ajc162/Ajc162Tests.java1
-rw-r--r--tests/src/org/aspectj/systemtest/ajc162/ajc162.xml6
3 files changed, 25 insertions, 0 deletions
diff --git a/tests/bugs162/pr194429/A.java b/tests/bugs162/pr194429/A.java
new file mode 100644
index 000000000..c6a0841f8
--- /dev/null
+++ b/tests/bugs162/pr194429/A.java
@@ -0,0 +1,18 @@
+import java.util.*;
+
+public class A {
+ public void foo(Set s) {
+ }
+ public void goo(Map s) {
+ }
+}
+
+aspect X {
+
+ pointcut p(Set s): execution(* *(..)) && args(s);
+
+ before(Map m): p(m) {
+ }
+
+}
+
diff --git a/tests/src/org/aspectj/systemtest/ajc162/Ajc162Tests.java b/tests/src/org/aspectj/systemtest/ajc162/Ajc162Tests.java
index 08dba1573..7b06234bc 100644
--- a/tests/src/org/aspectj/systemtest/ajc162/Ajc162Tests.java
+++ b/tests/src/org/aspectj/systemtest/ajc162/Ajc162Tests.java
@@ -19,6 +19,7 @@ import org.aspectj.testing.XMLBasedAjcTestCase;
public class Ajc162Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
// AspectJ1.6.2
+ public void testMissingContext_pr194429() { runTest("missing context"); }
public void testWarningsForLimitations_pr210114() { runTest("warnings for limitations"); }
public void testPTW_pr244830() { runTest("ptw initFailureCause"); }
public void testGenericItdsOverrides_pr222648() { runTest("generic itds - overrides"); }
diff --git a/tests/src/org/aspectj/systemtest/ajc162/ajc162.xml b/tests/src/org/aspectj/systemtest/ajc162/ajc162.xml
index ccbe977f0..1b3cfed02 100644
--- a/tests/src/org/aspectj/systemtest/ajc162/ajc162.xml
+++ b/tests/src/org/aspectj/systemtest/ajc162/ajc162.xml
@@ -3,6 +3,12 @@
<!-- AspectJ v1.6.2 Tests -->
<suite>
+ <ajc-test dir="bugs162/pr194429" title="missing context">
+ <compile files="A.java" options="-1.5">
+ <message kind="error" line="14" text="incompatible type, expected java.util.Set found BindingTypePattern("/>
+ </compile>
+ </ajc-test>
+
<ajc-test dir="bugs162/pr210114" title="warnings for limitations">
<compile files="TestAspect.java" options="-1.5">
<message kind="warning" text="Only before advice is supported on handler join points (compiler limitation)"/>