use getHint()

git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@368 379699f6-c40d-0410-875b-85095c16579e
stable
jochen 26 years ago
parent d4f444d3a4
commit 514aa2598a
  1. 8
      jode/jode/decompiler/LocalInfo.java
  2. 2
      jode/jode/expr/GetFieldOperator.java

@ -144,9 +144,9 @@ public class LocalInfo {
}
if (name == null) {
if (jode.Decompiler.prettyLocals && type != null) {
name = type.getDefaultName();
name = type.getHint().getDefaultName();
} else {
name = type.getDefaultName()
name = type.getHint().getDefaultName()
+ (slot >= 0 ? "_" + slot : "") + "_" + serialnr++ + "_";
isUnique = true;
}
@ -158,8 +158,8 @@ public class LocalInfo {
* Get the slot of this local.
*/
public int getSlot() {
/* The slot does not change when shadowing */
return slot;
/* The slot may change when shadowing for anonymous locals */
return getLocalInfo().slot;
}
/**

@ -57,7 +57,7 @@ public class GetFieldOperator extends Operator {
public void setOperandType(Type types[]) {
if (!staticFlag)
needCast = types[0].getTop().equals(Type.tUnknown);
needCast = types[0].getHint().equals(Type.tNull);
}
public String toString(String[] operands) {

Loading…
Cancel
Save