Browse Source

tests for pr91114, (before - after) expression

tags/V1_5_0M3
acolyer 19 years ago
parent
commit
169a48870a

+ 10
- 0
tests/bugs150/pr91114.aj View File

@@ -0,0 +1,10 @@
public class pr91114 {
public void bar() {
long before = 0;
long after = 0;
long x = (before - after); // doesn't fail without the parentheses!
System.out.println("... " + (before - after) + " ...");
}
}

+ 4
- 0
tests/src/org/aspectj/systemtest/ajc150/Ajc150Tests.java View File

@@ -226,6 +226,10 @@ public class Ajc150Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
runTest("before and after are valid identifiers in classes");
}
public void testAjKeywordsAsIdentifiers2() {
runTest("before and after are valid identifiers in classes, part 2");
}
public void testNoBeforeReturningAdvice() {
runTest("before returning advice not allowed!");
}

+ 6
- 1
tests/src/org/aspectj/systemtest/ajc150/ajc150.xml View File

@@ -66,7 +66,12 @@
<compile files="pr74562.aj">
</compile>
</ajc-test>

<ajc-test dir="bugs150" pr="91114" title="before and after are valid identifiers in classes, part 2">
<compile files="pr91114.aj">
</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 &quot;returning&quot;, delete this token"/>

Loading…
Cancel
Save