summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authoraclement <aclement>2005-10-05 08:12:20 +0000
committeraclement <aclement>2005-10-05 08:12:20 +0000
commit2b0e6755030eb378e612a00fcb80d7bdca2c55ee (patch)
tree0b67896cebc343880741d2fe862c773aadfa9991 /tests
parentb305f9ee512015657cad0ea722b8180d884b1f72 (diff)
downloadaspectj-2b0e6755030eb378e612a00fcb80d7bdca2c55ee.tar.gz
aspectj-2b0e6755030eb378e612a00fcb80d7bdca2c55ee.zip
test and fix for pr111481: varargs ITD ctors. Patch from Helen Hawkins.
Diffstat (limited to 'tests')
-rw-r--r--tests/bugs150/pr111481.aj14
-rw-r--r--tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java3
-rw-r--r--tests/src/org/aspectj/systemtest/ajc150/ajc150.xml10
3 files changed, 27 insertions, 0 deletions
diff --git a/tests/bugs150/pr111481.aj b/tests/bugs150/pr111481.aj
new file mode 100644
index 000000000..e764b4e4f
--- /dev/null
+++ b/tests/bugs150/pr111481.aj
@@ -0,0 +1,14 @@
+public class pr111481 {
+
+ public static void main(String []argv) {
+ new pr111481(new Object[]{"a","b","c"});
+ new pr111481("a","b","c");
+ }
+
+}
+aspect A {
+ public pr111481.new(Object... names) {
+ System.out.println(names[0]);
+ }
+
+}
diff --git a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java
index daa404fab..54b89ff45 100644
--- a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java
+++ b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java
@@ -596,6 +596,9 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
assertNotNull("Couldn't find 'method-call(void pack.Test.someMethod())' element in the tree",pe);
}
+ public void testVarArgsIITDInConstructor() {
+ runTest("ITD varargs in constructor");
+ }
// helper methods.....
diff --git a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml
index 3c0335717..539df7b7d 100644
--- a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml
+++ b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml
@@ -4914,4 +4914,14 @@
<compile files="pr102357.aj"/>
<run class="pr102357"/>
</ajc-test>
+
+ <ajc-test dir="bugs150" title="ITD varargs in constructor">
+ <compile files="pr111481.aj" options="-1.5"/>
+ <run class="pr111481">
+ <stdout>
+ <line text="a"/>
+ <line text="a"/>
+ </stdout>
+ </run>
+ </ajc-test>
</suite> \ No newline at end of file