Make --element parser capture final space before EOF
authorNick Downing <nick@ndcode.org>
Sat, 12 Jan 2019 13:09:58 +0000 (00:09 +1100)
committerNick Downing <nick@ndcode.org>
Sat, 12 Jan 2019 13:09:58 +0000 (00:09 +1100)
skel/skel_py_element.py

index e18bce4..e614553 100644 (file)
@@ -117,7 +117,8 @@ def yyparse(factory, *args, **kwargs):
     ]
     assert state != -1
 
-  # return the space then the AST in the user's choice of element type
+  # return space then AST then space in the user's choice of element type
+  yy_element_stack.append(lex_yy.yy_element_space)
   return element.concatenate(yy_element_stack, factory, *args, **kwargs)
 
 # GENERATE SECTION3