Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/TurtleArt/taexportpython.py
diff options
context:
space:
mode:
authorMarion <marion.zepf@gmail.com>2013-08-03 18:44:29 (GMT)
committer Marion <marion.zepf@gmail.com>2013-08-03 18:44:29 (GMT)
commit1445dc528d9c03d720918d11424e8ea9b02b5ecf (patch)
treef9509f210fb0e3b52dbe283e8acf685f3a6298a9 /TurtleArt/taexportpython.py
parent154625db431ebe252e8ddaeb9e45dbc07d1c4329 (diff)
add Primitives for the 'xcor' and 'ycor' blocks
Diffstat (limited to 'TurtleArt/taexportpython.py')
-rw-r--r--TurtleArt/taexportpython.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/TurtleArt/taexportpython.py b/TurtleArt/taexportpython.py
index ad94a90..a85a17a 100644
--- a/TurtleArt/taexportpython.py
+++ b/TurtleArt/taexportpython.py
@@ -126,11 +126,14 @@ def _walk_action_stack(top_block, lc):
""" Turn a stack of blocks into a list of ASTs """
block = top_block
- # value blocks are don't have a primitive
+ # value blocks don't have a primitive
if block.is_value_block():
raw_value = block.get_value()
value_ast = value_to_ast(raw_value)
- return [value_ast]
+ if value_ast is not None:
+ return [value_ast]
+ else:
+ return []
def _get_prim(block):
prim = lc.get_prim_callable(block.primitive)