Skip to content

Commit

Permalink
버그 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
riroan committed Mar 13, 2022
1 parent 69abc00 commit b65a1f7
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -275,10 +275,8 @@ def funDeclare(self, code):
self.indent += 1
self.out.append(out)

def funCall(self, code, ret = False): # ret변수 : True -> 함수 호출이 한줄임, False -> 다른 구문 사이에 껴있음
out = ""
if not ret:
out = self.getNewLine()
def funCall(self, code): # ret변수 : True -> 함수 호출이 한줄임, False -> 다른 구문 사이에 껴있음
out = self.getNewLine()
elements = code[2:].split(",")

name, args = elements[0], elements[1:]
Expand All @@ -287,8 +285,7 @@ def funCall(self, code, ret = False): # ret변수 : True -> 함수 호출이 한
if i:
out+=","
out+=self.makeAssignStmt(arg)
if ret:
return out
out = out.replace("(,", "(")
self.out.append(out)

def returnStmt(self, code):
Expand Down

0 comments on commit b65a1f7

Please sign in to comment.