From: aclement Date: Tue, 27 Feb 2007 13:31:29 +0000 (+0000) Subject: 174449: generic aspects and generic pointcuts - dont ignore parameterized signatures... X-Git-Tag: V1_5_4rc1~82 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=e253331f1e8d3f4aaba29f73fada1cdd1f72a314;p=aspectj.git 174449: generic aspects and generic pointcuts - dont ignore parameterized signatures for the advice method --- diff --git a/tests/bugs160/pr174449/Foo.java b/tests/bugs160/pr174449/Foo.java new file mode 100644 index 000000000..68a400d7d --- /dev/null +++ b/tests/bugs160/pr174449/Foo.java @@ -0,0 +1,33 @@ +abstract aspect Replicate { + + protected pointcut broadcast(T servant); + + void around(T servant): broadcast(servant) { + System.err.println("around advice executing: servant class is "+servant.getClass()); + proceed(servant); + } + +} + +aspect ReplicateConcreteB extends Replicate { + protected pointcut broadcast(Boo servant) : call(* *.setScene(..)) && target(servant); +} + +aspect ReplicateConcreteG extends Replicate { + protected pointcut broadcast(Goo servant) : call(* *.setScene(..)) && target(servant); +} + +public class Foo { + public static void main(String []argv) { + new Boo().setScene(); + new Goo().setScene(); + } +} + +class Boo { + public void setScene() {} +} + +class Goo { + public void setScene() {} +} diff --git a/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java b/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java index e371e5e5e..0456efa11 100644 --- a/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc160/Ajc160Tests.java @@ -21,6 +21,8 @@ import junit.framework.Test; */ public class Ajc160Tests extends org.aspectj.testing.XMLBasedAjcTestCase { + public void testGenericAspectGenericPointcut_pr174449() { runTest("problem with generic aspect and generic pointcut");} + public void testGenericAspectGenericPointcut_noinline_pr174449() { runTest("problem with generic aspect and generic pointcut - noinline");} public void testGenericMethodsAndOrdering_ok_pr171953_2() { runTest("problem with generic methods and ordering - ok");} public void testGenericMethodsAndOrdering_bad_pr171953_2() { runTest("problem with generic methods and ordering - bad");} public void testItdAndJoinpointSignatureCollection_ok_pr171953() { runTest("problem with itd and join point signature collection - ok");} diff --git a/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml b/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml index 671f3ad6d..128e18a03 100644 --- a/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml +++ b/tests/src/org/aspectj/systemtest/ajc160/ajc160.xml @@ -5,6 +5,26 @@ + + + + + + + + + + + + + + + + + + + +