Relax operand equality condition in try/finally detection

This isn't ideal and probably isn't safe in the general case, but it
does fix the only case where we couldn't deinline a finally block. (In
turn, this caused further problems because the SSA code is not aware of
the monitor variables inserted by Fernflower if it can't deinline a
finally block.)
master
Graham 5 years ago
parent 4aa496dff8
commit 7e2421df89
  1. 8
      src/org/jetbrains/java/decompiler/modules/decompiler/FinallyProcessor.java

@ -843,11 +843,11 @@ public class FinallyProcessor {
if (firstOp != secondOp) {
// a-load/store instructions
if (first.opcode == CodeConstants.opc_aload || first.opcode == CodeConstants.opc_astore) {
for (int[] arr : lstStoreVars) {
if (arr[0] == firstOp && arr[1] == secondOp) {
//for (int[] arr : lstStoreVars) {
// if (arr[0] == firstOp && arr[1] == secondOp) {
return true;
}
}
// }
//}
}
return false;

Loading…
Cancel
Save