diff options
author | aclement <aclement> | 2005-08-23 14:02:30 +0000 |
---|---|---|
committer | aclement <aclement> | 2005-08-23 14:02:30 +0000 |
commit | 284c4eed6b80ac368ca60c2f9eb7aff1234bf2a8 (patch) | |
tree | 0953fe63aa97f0b16f8358ed0f3eee18bfb5db13 /tests/java5/generics | |
parent | 4aacf20ad0fd3f3782fe1ff936aa13f666431beb (diff) | |
download | aspectj-284c4eed6b80ac368ca60c2f9eb7aff1234bf2a8.tar.gz aspectj-284c4eed6b80ac368ca60c2f9eb7aff1234bf2a8.zip |
@override support for ITDs. Plus some binary weaving generic ITD tests.
Diffstat (limited to 'tests/java5/generics')
-rw-r--r-- | tests/java5/generics/itds/C.java | 2 | ||||
-rw-r--r-- | tests/java5/generics/itds/D.java | 2 | ||||
-rw-r--r-- | tests/java5/generics/itds/FieldITDOnGenericType.aj (renamed from tests/java5/generics/itds/FieldITDOnGeneric.aj) | 2 | ||||
-rw-r--r-- | tests/java5/generics/itds/binaryweaving/TestA_generictype.java | 3 | ||||
-rw-r--r-- | tests/java5/generics/itds/binaryweaving/TestB_aspect1.aj | 5 | ||||
-rw-r--r-- | tests/java5/generics/itds/binaryweaving/TestB_aspect2.aj | 5 | ||||
-rw-r--r-- | tests/java5/generics/itds/binaryweaving/TestB_class.java | 15 | ||||
-rw-r--r-- | tests/java5/generics/itds/binaryweaving/TestB_generictype.java | 3 |
8 files changed, 34 insertions, 3 deletions
diff --git a/tests/java5/generics/itds/C.java b/tests/java5/generics/itds/C.java index b1a630cfc..dc64b17d6 100644 --- a/tests/java5/generics/itds/C.java +++ b/tests/java5/generics/itds/C.java @@ -7,5 +7,7 @@ public abstract aspect C<T> { } } +public aspect C<String> { } + class Foo { } diff --git a/tests/java5/generics/itds/D.java b/tests/java5/generics/itds/D.java index 2ab496cc0..6843765b1 100644 --- a/tests/java5/generics/itds/D.java +++ b/tests/java5/generics/itds/D.java @@ -8,4 +8,6 @@ public abstract aspect D<T> { } +aspect E extends D<String> {} + class Goo<P> {} diff --git a/tests/java5/generics/itds/FieldITDOnGeneric.aj b/tests/java5/generics/itds/FieldITDOnGenericType.aj index 9fb784b62..2a670219e 100644 --- a/tests/java5/generics/itds/FieldITDOnGeneric.aj +++ b/tests/java5/generics/itds/FieldITDOnGenericType.aj @@ -12,7 +12,7 @@ public class FieldITDOnGenericType { public static void main(String[] argv) { MathUtils<Integer> mu = new MathUtils<Integer>(); mu.n=42; - System.err.prinltn(">"+mu.n); + System.err.println(">"+mu.n); } } diff --git a/tests/java5/generics/itds/binaryweaving/TestA_generictype.java b/tests/java5/generics/itds/binaryweaving/TestA_generictype.java index 005d936a0..f89e3363a 100644 --- a/tests/java5/generics/itds/binaryweaving/TestA_generictype.java +++ b/tests/java5/generics/itds/binaryweaving/TestA_generictype.java @@ -1,4 +1,3 @@ import java.util.*; -class TestA_generictype<N> {// extends Number> { -} +class TestA_generictype<N extends Number> { } diff --git a/tests/java5/generics/itds/binaryweaving/TestB_aspect1.aj b/tests/java5/generics/itds/binaryweaving/TestB_aspect1.aj new file mode 100644 index 000000000..145b67eb5 --- /dev/null +++ b/tests/java5/generics/itds/binaryweaving/TestB_aspect1.aj @@ -0,0 +1,5 @@ +import java.util.*; + +aspect TestB_aspect1 { + public <L extends Number> void TestB_generictype<X,Y>.mxy(List<L> ll1, List<X> lx,List<Y> ly,List<L> ll2) {} +} diff --git a/tests/java5/generics/itds/binaryweaving/TestB_aspect2.aj b/tests/java5/generics/itds/binaryweaving/TestB_aspect2.aj new file mode 100644 index 000000000..c8eac2a35 --- /dev/null +++ b/tests/java5/generics/itds/binaryweaving/TestB_aspect2.aj @@ -0,0 +1,5 @@ +import java.util.*; + +aspect TestB_aspect2 { + public <L extends Number> void TestB_generictype<X,Y>.myx(List<L> ll1, List<Y> ly,List<X> lx,List<L> ll2) {} +} diff --git a/tests/java5/generics/itds/binaryweaving/TestB_class.java b/tests/java5/generics/itds/binaryweaving/TestB_class.java new file mode 100644 index 000000000..098aabdbe --- /dev/null +++ b/tests/java5/generics/itds/binaryweaving/TestB_class.java @@ -0,0 +1,15 @@ +import java.util.*; + +public class TestB_class { + public static void main(String []argv) { + TestB_generictype<Float,String> sc1=new TestB_generictype<Float,String>(); + TestB_generictype<Integer,Float> sc2=new TestB_generictype<Integer,Float>(); + + List<Integer> li = new ArrayList<Integer>(); + List<String> ls = new ArrayList<String>(); + List<Float> lf = new ArrayList<Float>(); + + sc1.mxy(li,lf,ls,li); + sc2.myx(li,lf,li,li); + } +} diff --git a/tests/java5/generics/itds/binaryweaving/TestB_generictype.java b/tests/java5/generics/itds/binaryweaving/TestB_generictype.java new file mode 100644 index 000000000..f693ea61d --- /dev/null +++ b/tests/java5/generics/itds/binaryweaving/TestB_generictype.java @@ -0,0 +1,3 @@ +import java.util.*; + +class TestB_generictype<N extends Number,P> { } |