From 6ab78ee0e1d49a0e3f882ddf604061dc572cb427 Mon Sep 17 00:00:00 2001 From: aclement Date: Thu, 27 Oct 2005 13:49:34 +0000 Subject: test and fix for pr113447: from Helen. --- tests/bugs150/PR113447.java | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 tests/bugs150/PR113447.java (limited to 'tests/bugs150') diff --git a/tests/bugs150/PR113447.java b/tests/bugs150/PR113447.java new file mode 100644 index 000000000..8fd45ed06 --- /dev/null +++ b/tests/bugs150/PR113447.java @@ -0,0 +1,40 @@ +public class PR113447 { + + public static void main(String[] args) { + PR113447 me = new PR113447(); + me.method1(); + me.method3(); + } + + public void method1(){} + + public void method3(){} +} + +aspect Super { + + // second method doesn't exist + pointcut pc1(PR113447 s) : + (this(s) && execution(void method1())) + || (this(s) && execution(void method2())); + + before(PR113447 s) : pc1(s) { + } + + // second method does exist + pointcut pc2(PR113447 s) : + (this(s) && execution(void method1())) + || (this(s) && execution(void method3())); + + before(PR113447 s) : pc2(s) { + } + + // second method doesn't exist + pointcut pc3(PR113447 s) : + (args(s) && execution(void method1())) + || (args(s) && execution(void method2())); + + before(PR113447 s) : pc3(s) { + } + +} -- cgit v1.2.3