diff options
Diffstat (limited to 'tests/features164')
-rw-r--r-- | tests/features164/declareMixin/CaseJ.java | 17 | ||||
-rw-r--r-- | tests/features164/declareMixin/CaseK.java | 15 |
2 files changed, 32 insertions, 0 deletions
diff --git a/tests/features164/declareMixin/CaseJ.java b/tests/features164/declareMixin/CaseJ.java new file mode 100644 index 000000000..8b33faf6c --- /dev/null +++ b/tests/features164/declareMixin/CaseJ.java @@ -0,0 +1,17 @@ +// TESTING: invalid return type for factory method +import org.aspectj.lang.annotation.*; + +public class CaseJ { + public static void main(String[]argv) { } +} + +aspect X { + @DeclareMixin("A") + public static void createImplementation1() {} + + @DeclareMixin("A") + public static int createImplementation2(Object o) {return 2;} +} + +interface I {} + diff --git a/tests/features164/declareMixin/CaseK.java b/tests/features164/declareMixin/CaseK.java new file mode 100644 index 000000000..c41d7363b --- /dev/null +++ b/tests/features164/declareMixin/CaseK.java @@ -0,0 +1,15 @@ +// TESTING: too many arguments to the factory method +import org.aspectj.lang.annotation.*; + +public class CaseK { + public static void main(String[]argv) { } +} + +aspect X { + @DeclareMixin("A") + public static I createImplementation1(String s,long foo) {return null;} + +} + +interface I {} + |