]> source.dussan.org Git - aspectj.git/commitdiff
332388: test and fix
authoraclement <aclement>
Mon, 13 Dec 2010 19:13:56 +0000 (19:13 +0000)
committeraclement <aclement>
Mon, 13 Dec 2010 19:13:56 +0000 (19:13 +0000)
tests/bugs1611/pr332388/A.java [new file with mode: 0644]
tests/bugs1611/pr332388/B.java [new file with mode: 0644]
tests/bugs1611/pr332388/M.java [new file with mode: 0644]
tests/bugs1611/pr332388/MyAspect.java [new file with mode: 0644]
tests/src/org/aspectj/systemtest/ajc1611/Ajc1611Tests.java
tests/src/org/aspectj/systemtest/ajc1611/ajc1611.xml

diff --git a/tests/bugs1611/pr332388/A.java b/tests/bugs1611/pr332388/A.java
new file mode 100644 (file)
index 0000000..fa035fa
--- /dev/null
@@ -0,0 +1,4 @@
+public class A<T extends M> {
+  public void a(T t) {
+  }
+}
diff --git a/tests/bugs1611/pr332388/B.java b/tests/bugs1611/pr332388/B.java
new file mode 100644 (file)
index 0000000..0784baf
--- /dev/null
@@ -0,0 +1,5 @@
+public class B<T extends M> extends A<T> {
+  public void b() {
+    a(null);
+  }
+}
diff --git a/tests/bugs1611/pr332388/M.java b/tests/bugs1611/pr332388/M.java
new file mode 100644 (file)
index 0000000..9b4658f
--- /dev/null
@@ -0,0 +1 @@
+public class M {}
diff --git a/tests/bugs1611/pr332388/MyAspect.java b/tests/bugs1611/pr332388/MyAspect.java
new file mode 100644 (file)
index 0000000..7692283
--- /dev/null
@@ -0,0 +1,10 @@
+import java.lang.annotation.*;
+import org.aspectj.lang.annotation.*;
+
+@Aspect
+public class MyAspect {
+  @Before("call(* *.*(..))")
+  public void myAdvice() {
+    System.out.println();
+  }
+}
index b6166af2d151bb7ab9a0165f033bcf2d4a9454ac..75a4f51cff4e7539761da2688e13ee8f970be8b6 100644 (file)
@@ -21,6 +21,10 @@ import org.aspectj.testing.XMLBasedAjcTestCase;
  */
 public class Ajc1611Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
 
+       public void testMissingType_332388() {
+               runTest("pr332388");
+       }
+
        public void testDeclareField_328840() {
                runTest("pr328840");
        }
index 40acb25c6e0335903235b46d8decf0600d211e07..58be6e641249d46d918d341cd8144c2ac4264f10 100644 (file)
     </stdout></run>
   </ajc-test>
   
+  <ajc-test dir="bugs1611/pr332388" title="pr332388">
+     <compile files="M.java" outjar="M.jar" options="-1.5"/>
+     <compile files="A.java B.java" classpath="M.jar" outjar="AB.jar" options="-1.5"/>
+     <compile files="MyAspect.java" outjar="aspects.jar" options="-1.5"/>
+     <compile files="" aspectpath="aspects.jar" inpath="AB.jar" options="-1.5">
+     <message kind="error" text="Unable to find type for generic bound.  Missing type is M"/>
+     </compile>
+  </ajc-test>
+  
 </suite>
\ No newline at end of file