aboutsummaryrefslogtreecommitdiff
path: root/nodes.py
diff options
context:
space:
mode:
Diffstat (limited to 'nodes.py')
-rw-r--r--nodes.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/nodes.py b/nodes.py
index 385e1c9..b87022e 100644
--- a/nodes.py
+++ b/nodes.py
@@ -68,16 +68,20 @@ class BoolStatement(Statement):
return self.value
class IfStatement(Statement):
- def __init__(self, clause, codeblock, lineno):
+ def __init__(self, clause, trueblock, falseblock, lineno):
Statement.__init__(self, lineno)
self.clause = clause
- self.codeblock = codeblock
+ self.trueblock = trueblock
+ self.falseblock = falseblock
def get_clause(self):
return self.clause
- def get_codeblock(self):
- return self.codeblock
+ def get_trueblock(self):
+ return self.trueblock
+
+ def get_falseblock(self):
+ return self.falseblock
class StringStatement(Statement):
def __init__(self, value, lineno):