From 792d1dfd50e8b9ca5df70ea84c0b35de9cfba0f3 Mon Sep 17 00:00:00 2001 From: aclement Date: Tue, 27 Jun 2006 11:34:41 +0000 Subject: test/fix for 148786: new array joinpoint problem. tiny one line change, safe for committing post RC. --- tests/bugs152/pr148786/A.java | 11 +++++++++++ tests/src/org/aspectj/systemtest/ajc152/Ajc152Tests.java | 1 + tests/src/org/aspectj/systemtest/ajc152/ajc152.xml | 9 +++++++++ 3 files changed, 21 insertions(+) create mode 100644 tests/bugs152/pr148786/A.java (limited to 'tests') diff --git a/tests/bugs152/pr148786/A.java b/tests/bugs152/pr148786/A.java new file mode 100644 index 000000000..8250730b2 --- /dev/null +++ b/tests/bugs152/pr148786/A.java @@ -0,0 +1,11 @@ +public class A { + public static void main(String []argv) { + byte[][] bytes = new byte[][]{{0},{1}}; + } +} + +aspect X { + after() returning(Object o) : call(*[][].new(..)) { + System.err.println("new array: "+o.getClass()); + } +} diff --git a/tests/src/org/aspectj/systemtest/ajc152/Ajc152Tests.java b/tests/src/org/aspectj/systemtest/ajc152/Ajc152Tests.java index 17996d89e..e53fc4f4a 100644 --- a/tests/src/org/aspectj/systemtest/ajc152/Ajc152Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc152/Ajc152Tests.java @@ -35,6 +35,7 @@ public class Ajc152Tests extends org.aspectj.testing.XMLBasedAjcTestCase { // public void testItdCallingGenericMethod_pr145391_2() { runTest("itd calling generic method - 2");} // public void testAdviceNotWovenAspectPath_pr147841() { runTest("advice not woven on aspectpath");} // public void testClassCastForInvalidAnnotationValue_pr148537() { runTest("classcast annotation value");} + public void testFreakyNewArrayJoinpoint_pr148786() { runTest("freaky new array joinpoint"); } public void testPrivilegeGeneric_pr148545() { runTest("nosuchmethoderror for privileged aspect");} public void testPrivilegeGeneric_pr148545_2() { runTest("nosuchmethoderror for privileged aspect - 2");} public void testUnknownAnnotationNPE() { runTest("NPE for unknown annotation");} diff --git a/tests/src/org/aspectj/systemtest/ajc152/ajc152.xml b/tests/src/org/aspectj/systemtest/ajc152/ajc152.xml index 481e3243c..cbff0e3d1 100644 --- a/tests/src/org/aspectj/systemtest/ajc152/ajc152.xml +++ b/tests/src/org/aspectj/systemtest/ajc152/ajc152.xml @@ -783,4 +783,13 @@ + + + + + + + + + \ No newline at end of file -- cgit v1.2.3