lang: Properly fix return parsing

Return should be two words: Return and the value. Nothing else.
This commit is contained in:
Jookia 2023-08-29 21:07:34 +10:00
parent f7a1be48c5
commit acc6eed699

View file

@ -129,7 +129,7 @@ def parse_set(line):
return ASTSet(line[1], call)
def parse_return(line):
if len(line) < 2 or len(line) > 3 or line[0] != "Return":
if len(line) != 2 or line[0] != "Return":
print("not a return? line: %s" % (' '.join(line)))
return None
value = parse_value(line[1])