]> source.dussan.org Git - aspectj.git/commitdiff
Tests for 87282, 88606
authoraclement <aclement>
Fri, 6 May 2005 15:42:28 +0000 (15:42 +0000)
committeraclement <aclement>
Fri, 6 May 2005 15:42:28 +0000 (15:42 +0000)
tests/java5/generics/bugs/PR87282.aj [new file with mode: 0644]
tests/java5/generics/bugs/PR88606.aj [new file with mode: 0644]
tests/src/org/aspectj/systemtest/ajc150/GenericsTests.java
tests/src/org/aspectj/systemtest/ajc150/ajc150.xml

diff --git a/tests/java5/generics/bugs/PR87282.aj b/tests/java5/generics/bugs/PR87282.aj
new file mode 100644 (file)
index 0000000..ff5e746
--- /dev/null
@@ -0,0 +1,15 @@
+import java.util.*;
+
+aspect introductionToA {
+  private ArrayList<B> PR87282.m_Array = new ArrayList<B>();  
+
+  public void PR87282.addB(B tmp){
+    m_Array.add(tmp);
+  }
+
+}
+
+public class PR87282 {}
+
+class B {}
diff --git a/tests/java5/generics/bugs/PR88606.aj b/tests/java5/generics/bugs/PR88606.aj
new file mode 100644 (file)
index 0000000..d72418d
--- /dev/null
@@ -0,0 +1,11 @@
+
+public class PR88606 {}
+
+aspect Foo {
+
+    private java.util.List<Foo> PR88606.list;
+    
+    private void bar() {
+        java.util.List<Foo> li = new PR88606().list;
+    }
+}
index fe265050a8daf01e17094bb7848f375e71a74753..25efa7cbf4cc32c0f36cc67d783f5e62c395da8a 100644 (file)
@@ -31,4 +31,13 @@ public class GenericsTests extends XMLBasedAjcTestCase {
        public void testPR91053() {
                runTest("Generics problem with Set");
        }
+       
+       public void testPR87282() {
+               runTest("Compilation error on generic member introduction");
+       }
+       
+       public void testPR88606() {
+               runTest("Parameterized types on introduced fields not correctly recognized");
+       }
+       
 }
index e9ef342c371fe1e13f518bf56232a8c4a890461c..15afabbfed6e7173439973f20e5bf3821c0bea5b 100644 (file)
       <compile files="PR91053.aj" options="-1.5"/>
       <run class="PR91053"/>
    </ajc-test>
+   
+   <ajc-test dir="java5/generics/bugs" title="Compilation error on generic member introduction" vm="1.5">
+      <compile files="PR87282.aj" options="-1.5"/>
+   </ajc-test>
+   
+   <ajc-test dir="java5/generics/bugs" title="Parameterized types on introduced fields not correctly recognized" vm="1.5">
+      <compile files="PR88606.aj" options="-1.5"/>
+   </ajc-test>
  
 </suite>
\ No newline at end of file