aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjhugunin <jhugunin>2003-10-23 16:47:24 +0000
committerjhugunin <jhugunin>2003-10-23 16:47:24 +0000
commitdf309ad58ae97560a94b01f798845d9517cd5c86 (patch)
treeed8d7c69a5b940ea69dafb51cdf079e58f5b9e8f
parent0929f8ccff1b0e98dbc3168b7acfc4159a969b2b (diff)
downloadaspectj-df309ad58ae97560a94b01f798845d9517cd5c86.tar.gz
aspectj-df309ad58ae97560a94b01f798845d9517cd5c86.zip
fix for Bugzilla Bug 45441
IncompatibleClassChangeError at runtime when compiling with -1.4 option
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ThisJoinPointVisitor.java8
-rw-r--r--tests/ajcTests.xml9
-rw-r--r--tests/ajcTestsFailing.xml11
3 files changed, 18 insertions, 10 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ThisJoinPointVisitor.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ThisJoinPointVisitor.java
index 2ec487518..8e5ef3837 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ThisJoinPointVisitor.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ThisJoinPointVisitor.java
@@ -161,6 +161,14 @@ public class ThisJoinPointVisitor extends AbstractSyntaxTreeVisitorAdapter {
//System.err.println("replace static ref: " + receiver + " is " + System.identityHashCode(receiver));
receiver.binding = thisJoinPointStaticPartDecLocal; //thisJoinPointStaticPartDec;
receiver.codegenBinding = thisJoinPointStaticPartDecLocal;
+
+ ReferenceBinding thisJoinPointStaticPartType =
+ (ReferenceBinding)thisJoinPointStaticPartDec.type;
+
+ receiver.receiverType = receiver.actualReceiverType =
+ receiver.resolvedType = thisJoinPointStaticPartType;
+
+ call.setActualReceiverType(thisJoinPointStaticPartType);
call.binding = call.codegenBinding = getEquivalentStaticBinding(call.binding);
}
diff --git a/tests/ajcTests.xml b/tests/ajcTests.xml
index cd3310c0c..6b7bdcf89 100644
--- a/tests/ajcTests.xml
+++ b/tests/ajcTests.xml
@@ -6775,4 +6775,13 @@
</compile>
</ajc-test>
+ <ajc-test dir="bugs/jpOptimization"
+ pr="45441"
+ title="JoinPoint Optimization when targetting 1.4">
+ <compile
+ files="de/test/MyMain.java,
+ de/test/MyAspect.java"
+ options="-1.4"/>
+ <run class="de.test.MyMain"/>
+ </ajc-test>
</suite>
diff --git a/tests/ajcTestsFailing.xml b/tests/ajcTestsFailing.xml
index c4bfc6944..933125dbe 100644
--- a/tests/ajcTestsFailing.xml
+++ b/tests/ajcTestsFailing.xml
@@ -136,14 +136,5 @@
files="Main.java"/>
<run class="Main"/>
</ajc-test>
-
- <ajc-test dir="bugs/jpOptimization"
- pr="45441"
- title="JoinPoint Optimization when targetting 1.4">
- <compile
- files="de/test/MyMain.java,
- de/test/MyAspect.java"
- options="-1.4"/>
- <run class="de.test.MyMain"/>
- </ajc-test>
+
</suite>