private void replaceEffectivelyStaticRef(MessageSend call) {
NameReference receiver = (NameReference) call.receiver;
+
+ // Don't continue if the call binding is null, as we are going to report an error about this line of code!
+ if (call.binding==null) return;
+
//System.err.println("replace static ref: " + receiver + " is " + System.identityHashCode(receiver));
receiver.binding = thisJoinPointStaticPartDecLocal; //thisJoinPointStaticPartDec;
receiver.codegenBinding = thisJoinPointStaticPartDecLocal;
files="Test_AroundVarBug.java,AroundVarBug.java"/>
<run class="Test_AroundVarBug"/>
</ajc-test>
-
- <ajc-test
- dir="bugs"
- pr="75129"
- title="NPE on thisJoinPoint mistake">
- <compile files="TjpMistake.java">
- <message kind="error" line="22"/>
- </compile>
- </ajc-test>
</suite>
public void test057_decSoftWithSuper() {
runTest("declare soft can cause programs with invalid exception behaviour to be generated");
}
-}
+ public void test058_npeOnTJPerror() {
+ runTest("NPE on thisJoinPoint mistake");
+ }
+
+}
\ No newline at end of file
<compile files="PR72157.java">
<message kind="error" line="13" text="Unhandled"/>
</compile>
- </ajc-test>
\ No newline at end of file
+ </ajc-test>
+
+ <ajc-test
+ dir="bugs"
+ pr="75129"
+ title="NPE on thisJoinPoint mistake">
+ <compile files="TjpMistake.java">
+ <message kind="error" line="22"/>
+ </compile>
+ </ajc-test>
\ No newline at end of file