ConstructorOperator removed, InvokeOperator handles it all.

git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@1083 379699f6-c40d-0410-875b-85095c16579e
branch_1_1
jochen 26 years ago
parent e4337a16a7
commit 48fb8a75b3
  1. 1
      jode/jode/expr/Makefile.am
  2. 4
      jode/jode/flow/SpecialBlock.java
  3. 13
      jode/jode/flow/TryBlock.java

@ -22,7 +22,6 @@ MY_JAVA_FILES = \
CompareUnaryOperator.java \
ConstOperator.java \
ConstantArrayOperator.java \
ConstructorOperator.java \
ConvertOperator.java \
Expression.java \
GetFieldOperator.java \

@ -175,8 +175,7 @@ public class SpecialBlock extends StructuredBlock {
if (instr.getType().stackSize() == count) {
StructuredBlock newBlock;
if (instr instanceof InvokeOperator
|| instr instanceof ConstructorOperator) {
if (instr instanceof InvokeOperator) {
Expression newExpr
= new PopOperator(instr.getType()).addOperand(instr);
prev.setInstruction(newExpr);
@ -206,4 +205,3 @@ public class SpecialBlock extends StructuredBlock {
return false;
}
}

@ -22,7 +22,6 @@ import jode.decompiler.TabbedPrintWriter;
import jode.type.*;
import jode.expr.Expression;
import jode.expr.InvokeOperator;
import jode.expr.ConstructorOperator;
import jode.expr.LocalLoadOperator;
/**
@ -187,17 +186,17 @@ public class TryBlock extends StructuredBlock {
((ThrowBlock) catchBlock.catchBlock).getInstruction();
if (throwExpr.getFreeOperandCount() != 0
|| !(throwExpr instanceof ConstructorOperator))
|| !(throwExpr instanceof InvokeOperator))
return false;
ConstructorOperator throwOp = (ConstructorOperator) throwExpr;
if (!(throwOp.getClassType()
.equals(Type.tClass("java.lang.InternalError")))
InvokeOperator throwOp = (InvokeOperator) throwExpr;
if (!throwOp.isConstructor()
|| !(throwOp.getClassType()
.equals(Type.tClass("java.lang.InternalError")))
|| throwOp.getMethodType().getParameterTypes().length != 1)
return false;
Expression getMethodExpr = throwOp.getSubExpressions()[0];
Expression getMethodExpr = throwOp.getSubExpressions()[1];
if (!(getMethodExpr instanceof InvokeOperator))
return false;

Loading…
Cancel
Save