Revert change to FieldExprent#getExprentUse

Revert part of a change introduced upstream. 81faff674c (diff-e057d0d70e5b15f5e12ec86ac46c85eeR57)
This upstream change causes local variables to not be inlined in many cases, and makes decomp very messy for the reason of 'thread safety'.
master
covers1624 5 years ago committed by Graham
parent 1f2ee3c81f
commit 9e525f7aeb
  1. 8
      src/org/jetbrains/java/decompiler/modules/decompiler/exps/FieldExprent.java

@ -54,7 +54,13 @@ public class FieldExprent extends Exprent {
@Override
public int getExprentUse() {
return 0; // multiple references to a field considered dangerous in a multithreaded environment, thus no Exprent.MULTIPLE_USES set here
//Revert the following line it produces messy code as follows:
//- this.field_225230_a[l + i1 * this.field_225231_b] &= 16777215;
//+ int[] aint = this.field_225230_a;
//+ int j1 = l + i1 * this.field_225231_b;
//+ aint[j1] &= 16777215;
//return 0; // multiple references to a field considered dangerous in a multithreaded environment, thus no Exprent.MULTIPLE_USES set here
return instance == null ? Exprent.MULTIPLE_USES : instance.getExprentUse() & Exprent.MULTIPLE_USES;
}
@Override

Loading…
Cancel
Save