From 5242ef35b0b8dcc158069807a1226a318f0b86d5 Mon Sep 17 00:00:00 2001 From: aclement Date: Thu, 18 Aug 2005 07:52:18 +0000 Subject: [PATCH] test for pr93356 and generic binary weaving itds --- tests/java5/varargs/pr93356.aj | 36 ++++++++++++ .../org/aspectj/systemtest/ajc150/ajc150.xml | 57 +++++++++++++++++++ 2 files changed, 93 insertions(+) create mode 100644 tests/java5/varargs/pr93356.aj diff --git a/tests/java5/varargs/pr93356.aj b/tests/java5/varargs/pr93356.aj new file mode 100644 index 000000000..00a2fdb38 --- /dev/null +++ b/tests/java5/varargs/pr93356.aj @@ -0,0 +1,36 @@ +// "Varargs with .. in pointcut" + +class A{ + public A(int i, int... nums) {} + public void b(int i, int... nums) {} +} +aspect B{ + ///////// methods + declare warning: execution(* *.*(..)) : "a"; + declare warning: execution(* *.*(int,..)) : "b"; + declare warning: execution(* *.*(..,int...)) : "c"; + declare warning: execution(* *.*(int,..,int...)) : "d"; + declare warning: execution(* *.*(int,int ...,..)) : "e"; + + declare warning: execution(* *.*(..,int,..,int ...,..)) : "k"; + declare warning: execution(* *.*(..,..,*...,..,..)) : "l"; + + + declare warning: execution(* *.*(int,int [],..)) : "shouldn't match A"; + declare warning: execution(* *.*(int,int [])) : "shouldn't match B"; + + //////////////////// constructors + declare warning: execution(*.new(..)) : "f"; // matches constructors for A and B + declare warning: execution(*.new(int,..)) : "g"; + declare warning: execution(*.new(..,int...)) : "h"; + declare warning: execution(*.new(int,..,int...)) : "i"; + declare warning: execution(*.new(int,int ...,..)) : "j"; + + declare warning: execution(*.new(int,int [],..)) : "shouldn't match C"; + declare warning: execution(*.new(int,int [])) : "shouldn't match D"; +} + + + + + diff --git a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml index 9d112b4a2..7876299cf 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml +++ b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml @@ -225,6 +225,26 @@ + + + + + + + + + + + + + + + + + + + + @@ -2870,6 +2890,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- 2.39.5