changeset 199:58284b6b0009

* Removed storage of substream in `MatchDirective`, because it's already being stored in the match templates (related to #39). * Updated changelog.
author cmlenz
date Fri, 25 Aug 2006 10:08:46 +0000
parents d7c0a7d65783
children 50eab0469148
files ChangeLog markup/template.py
diffstat 2 files changed, 6 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -6,9 +6,13 @@
    variables that are defined but set to `None`. This also means that local
    variables can override built-ins even if the local variable are set to
    `None` (ticket #36).
+ * The plugin implementation now makes more functions available for use inside
+   templates: XML(), HTML(), defined(), and value-of(). These are mostly for
+   migration from Kid.
  * The parsing of `py:with` directives has been improved: you can now assign
    to multiple names, and semicolons inside string literals are treated as
    expected.
+ * Generator expressions can now be used in template expressions (ticket #16).
 
 
 Version 0.2
--- a/markup/template.py
+++ b/markup/template.py
@@ -444,19 +444,17 @@
       </span>
     </div>
     """
-    __slots__ = ['path', 'stream']
+    __slots__ = ['path']
 
     ATTRIBUTE = 'path'
 
     def __init__(self, value, filename=None, lineno=-1, offset=-1):
         Directive.__init__(self, None, filename, lineno, offset)
         self.path = Path(value, filename, lineno)
-        self.stream = []
 
     def __call__(self, stream, ctxt, directives):
-        self.stream = list(stream)
         ctxt._match_templates.append((self.path.test(ignore_context=True),
-                                      self.path, self.stream, directives))
+                                      self.path, list(stream), directives))
         return []
 
     def __repr__(self):
Copyright (C) 2012-2017 Edgewall Software