|
|
@ -45,13 +45,14 @@ public class ReturnBlock extends InstructionContainer { |
|
|
|
* @return stack the stack afterwards. |
|
|
|
* @return stack the stack afterwards. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public VariableStack mapStackToLocal(VariableStack stack) { |
|
|
|
public VariableStack mapStackToLocal(VariableStack stack) { |
|
|
|
VariableStack newStack; |
|
|
|
VariableStack newStack = stack; |
|
|
|
|
|
|
|
if (instr != null) { |
|
|
|
int params = instr.getOperandCount(); |
|
|
|
int params = instr.getOperandCount(); |
|
|
|
if (params > 0) { |
|
|
|
if (params > 0) { |
|
|
|
this.stack = stack.peek(params); |
|
|
|
this.stack = stack.peek(params); |
|
|
|
newStack = stack.pop(params); |
|
|
|
newStack = stack.pop(params); |
|
|
|
} else |
|
|
|
} |
|
|
|
newStack = stack; |
|
|
|
} |
|
|
|
return null; |
|
|
|
return null; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|