diff options
-rw-r--r-- | tests/bugs150/pr78261.aj | 5 | ||||
-rw-r--r-- | tests/bugs150/pr78314.aj | 6 | ||||
-rw-r--r-- | tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java | 4 | ||||
-rw-r--r-- | tests/src/org/aspectj/systemtest/ajc150/ajc150.xml | 8 |
4 files changed, 22 insertions, 1 deletions
diff --git a/tests/bugs150/pr78261.aj b/tests/bugs150/pr78261.aj new file mode 100644 index 000000000..64df073d4 --- /dev/null +++ b/tests/bugs150/pr78261.aj @@ -0,0 +1,5 @@ +public aspect pr78261 { + + pointcut absurd() : get(void *); // CE L3, fields can't be void + +}
\ No newline at end of file diff --git a/tests/bugs150/pr78314.aj b/tests/bugs150/pr78314.aj new file mode 100644 index 000000000..0f5799988 --- /dev/null +++ b/tests/bugs150/pr78314.aj @@ -0,0 +1,6 @@ +public class pr78314 { + pr78314 a1 = new pr78314(); + pr78314 a2 = new pr78314(); + + a1.foo(); +}
\ No newline at end of file diff --git a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java index bc3663e40..213213497 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java +++ b/tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java @@ -234,6 +234,10 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase { runTest("before returning advice not allowed!"); } + public void testDetectVoidFieldType() { + runTest("void field type in pointcut expression"); + } + // helper methods..... public SyntheticRepository createRepos(File cpentry) { diff --git a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml index 390615def..a8a2967c6 100644 --- a/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml +++ b/tests/src/org/aspectj/systemtest/ajc150/ajc150.xml @@ -71,7 +71,13 @@ <compile files="pr91114.aj"> </compile> </ajc-test> - + + <ajc-test dir="bugs150" pr="78621" title="void field type in pointcut expression"> + <compile files="pr78261.aj"> + <message line="3" kind="error" text="fields cannot have a void type"/> + </compile> + </ajc-test> + <ajc-test dir="bugs150" pr="78707" title="before returning advice not allowed!"> <compile files="pr78707.aj"> <message line="3" kind="error" text="Syntax error on token "returning", delete this token"/> |