diff options
author | Alexander Kriegisch <Alexander@Kriegisch.name> | 2022-03-21 10:45:00 +0700 |
---|---|---|
committer | Alexander Kriegisch <Alexander@Kriegisch.name> | 2022-03-21 10:51:35 +0700 |
commit | 6dc09db0ca1589f8c53c4dca054e3a852eaaecba (patch) | |
tree | 9c480f1ab92b26d141a249513d89942b1a1e6b73 /tests/bugs198 | |
parent | d3a06a6942b6f69ce9b5b4403d3c1cf1803cf01e (diff) | |
download | aspectj-6dc09db0ca1589f8c53c4dca054e3a852eaaecba.tar.gz aspectj-6dc09db0ca1589f8c53c4dca054e3a852eaaecba.zip |
Prepare code, tests and docs for Java 18
- JDT Core dependency in pom.xml
- Constants.java
- LangUtil.java
- AjcTask.java
- messages_aspectj.properties
- XMLBasedAjcTestCaseForJava17Only.java
- XMLBasedAjcTestCaseForJava18*.java
- tests/bugs199
- tests/features199
- JavaVersionCompatibility.md
- README-199.html
- GitHub CI build
Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
Diffstat (limited to 'tests/bugs198')
-rw-r--r-- | tests/bugs198/github_115/A.java | 32 | ||||
-rw-r--r-- | tests/bugs198/github_115/B.java | 33 | ||||
-rw-r--r-- | tests/bugs198/github_120/C.java | 64 | ||||
-rw-r--r-- | tests/bugs198/github_120/D.java | 33 | ||||
-rw-r--r-- | tests/bugs198/github_122/E.java | 30 | ||||
-rw-r--r-- | tests/bugs198/github_125/Application.java | 11 |
6 files changed, 0 insertions, 203 deletions
diff --git a/tests/bugs198/github_115/A.java b/tests/bugs198/github_115/A.java deleted file mode 100644 index 07df21f10..000000000 --- a/tests/bugs198/github_115/A.java +++ /dev/null @@ -1,32 +0,0 @@ -import org.aspectj.lang.annotation.Aspect; -import org.aspectj.lang.annotation.Before; -import org.aspectj.lang.annotation.Pointcut; - -public class A { - - public static void main(String []argv) { - System.out.println("A.main"); - } - -} - -@Aspect -class Azpect { - - @Pointcut("if(false)") - public void isFalse() { } - - @Pointcut("if(true)") - public void isTrue() { } - - @Before("isTrue() && execution(* A.main(..))") - public void beforeTrue() { - System.out.println("Azpect.beforeTrue"); - } - - @Before("isFalse() && execution(* A.main(..))") - public void beforeFalse() { - System.out.println("Azpect.beforeFalse"); - } -} - diff --git a/tests/bugs198/github_115/B.java b/tests/bugs198/github_115/B.java deleted file mode 100644 index eba199b67..000000000 --- a/tests/bugs198/github_115/B.java +++ /dev/null @@ -1,33 +0,0 @@ -import org.aspectj.lang.annotation.Aspect; -import org.aspectj.lang.annotation.Before; -import org.aspectj.lang.annotation.Pointcut; - -public class B { - - public static void main(String []argv) { - System.out.println("B.main"); - } - -} - -@Aspect -abstract class AbstractAzpect { - - @Pointcut - public abstract void isTrue(); - - @Before("isTrue() && execution(* B.main(..))") - public void beforeFalse() { - System.out.println("Azpect.beforeFalse"); - } -} - -@Aspect -class Azpect extends AbstractAzpect { - - @Override - @Pointcut("if(true)") - public void isTrue() { } - -} - diff --git a/tests/bugs198/github_120/C.java b/tests/bugs198/github_120/C.java deleted file mode 100644 index 4af57af24..000000000 --- a/tests/bugs198/github_120/C.java +++ /dev/null @@ -1,64 +0,0 @@ -import org.aspectj.lang.annotation.Aspect; -import org.aspectj.lang.annotation.Before; -import org.aspectj.lang.annotation.Pointcut; - -/** - * This test is exploring situations where an if() pointcut is used with a parameter - * and yet a reference pointcut referring to it is not binding the parameter. - */ -public class C { - - int i; - - C(int i) { - this.i = i; - } - - public static void main(String []argv) { - new C(1).run(); - } - - public void run() { - System.out.println("C.run() executing"); - } - - public String toString() { - return "C("+i+")"; - } - -} - -@Aspect -abstract class Azpect1 { - - @Pointcut("if(false)") - public void isCondition() {} - - @Before("isCondition() && execution(* C.run(..))") - public void beforeAdvice() { - System.out.println("Azpect1.beforeAdvice executing"); - } - -} - -@Aspect -class Azpect2 extends Azpect1 { - @Pointcut("check(*)") - public void isCondition() { } - - @Pointcut("this(c) && if()") - public static boolean check(C c) { - System.out.println("check if() pointcut running on "+c.toString()); - return true; - } -} -// -//abstract aspect A { -// pointcut isCondition(): if(false); -// before(): isCondition() && execution(* C.run(..)) { System.out.println("A.before"); } -//} -// -//aspect B extends A { -// pointcut isCondition(): check(*); -// pointcut check(Object o): this(o) && if(o.toString().equals("abc")); -//}
\ No newline at end of file diff --git a/tests/bugs198/github_120/D.java b/tests/bugs198/github_120/D.java deleted file mode 100644 index 2ecdaa574..000000000 --- a/tests/bugs198/github_120/D.java +++ /dev/null @@ -1,33 +0,0 @@ -import org.aspectj.lang.annotation.Aspect; -import org.aspectj.lang.annotation.Before; -import org.aspectj.lang.annotation.Pointcut; - -/** - * This test is exploring situations where an if() pointcut is used with a parameter - * and yet a reference pointcut referring to it is not binding the parameter. - */ -public class D { - - - public static void main(String []argv) { - new D().run(); - } - - public void run() { - System.out.println("D.run() executing"); - } - - public boolean isTrue() { - return true; - } - -} - -@Aspect class Azpect { - - @Pointcut("this(d) && if()") public static boolean method(D d) { return d.isTrue(); } - - @Before("method(*) && execution(* D.run(..))") public void beforeAdvice() { - System.out.println("advice running"); - } -}
\ No newline at end of file diff --git a/tests/bugs198/github_122/E.java b/tests/bugs198/github_122/E.java deleted file mode 100644 index 29c818285..000000000 --- a/tests/bugs198/github_122/E.java +++ /dev/null @@ -1,30 +0,0 @@ -import org.aspectj.lang.annotation.Aspect; -import org.aspectj.lang.annotation.Before; -import org.aspectj.lang.annotation.Pointcut; - -/** - * Test !if() pointcuts - */ -public class E { - - public static void main(String []argv) { - new E().run(); - } - - public void run() { - System.out.println("E.run() executing"); - } - -} - -@Aspect class Azpect { - - @Pointcut("!bar()") - public static void foo() {} - - @Pointcut("if()") public static boolean bar() { return false; } - - @Before("foo() && execution(* E.run(..))") public void beforeAdvice() { - System.out.println("advice running"); - } -}
\ No newline at end of file diff --git a/tests/bugs198/github_125/Application.java b/tests/bugs198/github_125/Application.java deleted file mode 100644 index 7e893fc1a..000000000 --- a/tests/bugs198/github_125/Application.java +++ /dev/null @@ -1,11 +0,0 @@ -public class Application { - public static void main(String[] argv) { - System.out.println("Hello world!"); - } - - static aspect MyAspect { - before(): execution(* Application.main(..)) { - System.out.println("Before advice"); - } - } -} |