aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authoraclement <aclement>2008-03-24 19:48:27 +0000
committeraclement <aclement>2008-03-24 19:48:27 +0000
commit659bd1bd5a03eb975f5bdd2a2c6687d16bf4abca (patch)
tree935bf3ea8d1ef92f9add4c92394b1c9aa4b2a0fb /tests
parent79b028d0d40b322500c7a1d6c2951789f69efcd4 (diff)
downloadaspectj-659bd1bd5a03eb975f5bdd2a2c6687d16bf4abca.tar.gz
aspectj-659bd1bd5a03eb975f5bdd2a2c6687d16bf4abca.zip
214994: generic itds alias NPE: tests and fix
Diffstat (limited to 'tests')
-rw-r--r--tests/bugs160/pr214994/Broke.java22
-rw-r--r--tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java3
-rw-r--r--tests/src/org/aspectj/systemtest/ajc160/ajc160.xml5
3 files changed, 30 insertions, 0 deletions
diff --git a/tests/bugs160/pr214994/Broke.java b/tests/bugs160/pr214994/Broke.java
new file mode 100644
index 000000000..fa1052227
--- /dev/null
+++ b/tests/bugs160/pr214994/Broke.java
@@ -0,0 +1,22 @@
+import java.util.*;
+
+interface Item {}
+interface Container {}
+interface CompositeItem<T> {}
+interface CompositeContainer<T extends CompositeItem> {}
+
+public abstract aspect Broke<Item, Container> {
+
+ private C CompositeItem<C>.container;
+
+ public List<I> CompositeContainer<I>.itemList = new ArrayList<I>();
+
+ public CompositeContainer<I> CompositeContainer<I>.addItem(I i) {
+ itemList.add(i);
+
+ i.container = this;
+
+ return this;
+ }
+
+} \ No newline at end of file
diff --git a/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java b/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java
index 93f01640b..61e6b9e27 100644
--- a/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java
+++ b/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java
@@ -22,6 +22,9 @@ import org.aspectj.testing.XMLBasedAjcTestCase;
public class Ajc160Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
// AspectJ1.6.0rc1
+ public void testGenericITDs_pr214994() {
+ runTest("generic itd");
+ }
public void testGenericDecpLtw_pr223605() {
runTest("generic decp ltw");
}
diff --git a/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml b/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml
index b7167cc78..bda4a19c8 100644
--- a/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml
+++ b/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml
@@ -3,6 +3,11 @@
<!-- AspectJ v1.6.0 Tests -->
<suite>
+
+ <ajc-test dir="bugs160/pr214994" title="generic itd">
+ <compile files="Broke.java" options="-1.5"/>
+ </ajc-test>
+
<ajc-test dir="bugs160/pr223605" title="generic decp ltw">
<compile files="GenericConfigurableBugTest.java" options="-1.5"><!-- -showWeaveInfo"-->
</compile>