Minor correction
This commit is contained in:
@@ -739,7 +739,7 @@ public class CodeGenImpl extends CodeGenBase
|
||||
sp_off -= 2;
|
||||
backend.emitADDI(SP, FP, -sp_off*wordSize, "restore sp");
|
||||
}
|
||||
if(operator.equals("!="))
|
||||
else if(operator.equals("!="))
|
||||
{
|
||||
incSp(2);
|
||||
backend.emitSW(node.left.dispatch(this), FP, (1 - sp_off) *wordSize, "Push argument 0 from last.");
|
||||
@@ -755,7 +755,7 @@ public class CodeGenImpl extends CodeGenBase
|
||||
backend.emitSW(node.left.dispatch(this), FP, (1 - sp_off) *wordSize, "Push argument 0 from last.");
|
||||
backend.emitSW(node.right.dispatch(this), FP, ( - sp_off) *wordSize, "Push argument 1 from last.");
|
||||
backend.emitADDI(SP, FP, -sp_off * wordSize, "Set SP to last argument.");
|
||||
backend.emitJAL(concatLabel, "Invoke method:concat");
|
||||
backend.emitJAL(strcatLabel, "Invoke method:strcat");
|
||||
sp_off -= 2;
|
||||
backend.emitADDI(SP, FP, -sp_off*wordSize, "restore sp");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user