Commit f23230fb authored by Guido van Rossum's avatar Guido van Rossum

Emit beginScope and endScope around loops. This was a deviation from

TALCompiler, and caused a subtle problem when integrating into
PresentationTemplates.
parent 49983bae
......@@ -204,6 +204,7 @@ class TALParser(XMLParser):
self.gen.pushProgram()
elif repeat:
todo["repeat"] = repeat
self.gen.emit("beginScope")
self.gen.pushProgram()
if attrsubst:
repldict = parseAttributeReplacements(attrsubst)
......@@ -275,6 +276,7 @@ class TALParser(XMLParser):
repeat = todo.get("repeat")
if repeat:
self.gen.emitRepeat(repeat)
self.gen.emit("endScope")
replace = todo.get("replace")
if replace:
self.gen.emitSubstitution(replace)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment