changeset 86:a54ebae77330 trunk

Accidentially left some doctests disabled.
author cmlenz
date Mon, 17 Jul 2006 09:01:08 +0000
parents 4938c310d904
children 1b874f032bde
files markup/eval.py
diffstat 1 files changed, 4 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/markup/eval.py
+++ b/markup/eval.py
@@ -42,8 +42,7 @@
     
     >>> Expression('dict.some').evaluate(data)
     'thing'
-    """
-    """
+    
     This also works the other way around: item access can be used to access
     any object attribute (meaning there's no use for `getattr()` in templates):
     
@@ -75,12 +74,12 @@
         """
         self.source = source
 
-        tree = parse(self.source, 'eval')
+        ast = parse(self.source, 'eval')
         if isinstance(filename, unicode):
             # pycodegen doesn't like unicode in the filename
             filename = filename.encode('utf-8', 'replace')
-        tree.filename = filename or '<string>'
-        gen = TemplateExpressionCodeGenerator(tree)
+        ast.filename = filename or '<string>'
+        gen = TemplateExpressionCodeGenerator(ast)
         if lineno >= 0:
             gen.emit('SET_LINENO', lineno)
         self.code = gen.getCode()
Copyright (C) 2012-2017 Edgewall Software