From dc023159e5a397449c1735df18d49fe4a75daa01 Mon Sep 17 00:00:00 2001 From: Nicholas Wesley Robinson <nwrobinson@uwaterloo.ca> Date: Mon, 13 Apr 2020 15:05:56 -0400 Subject: [PATCH] removing todo --- ExprPrimaryNodes.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ExprPrimaryNodes.py b/ExprPrimaryNodes.py index c430e29..3fa30e0 100644 --- a/ExprPrimaryNodes.py +++ b/ExprPrimaryNodes.py @@ -760,8 +760,10 @@ class ExprNode(ASTNode): self.code += self.left.code if self.op == '&&': + # if left result == false, break out self.code += p("cmp", "eax", "0") elif self.op == '||': + # if left result == true, break out self.code += p("cmp", "eax", "1") self.code += p("je", endLabel, "", " breaking out of " + self.op) @@ -786,7 +788,7 @@ class ExprNode(ASTNode): self.code += p(endLabel + ":", "") return - # String Add TODO + # String Add if (self.left.myType.name =='java.lang.String' or self.right.myType.name =='java.lang.String') and self.op == '+': # ( String.valueOf(right) ).concat( left ) if not hasattr(self.concatMethodInv, "code"): -- GitLab