[Python-checkins] r67771 - sandbox/trunk/2to3/lib2to3/pytree.py
benjamin.peterson
python-checkins at python.org
Sun Dec 14 22:22:09 CET 2008
Author: benjamin.peterson
Date: Sun Dec 14 22:22:09 2008
New Revision: 67771
Log:
altering .children needs to call changed()
Modified:
sandbox/trunk/2to3/lib2to3/pytree.py
Modified: sandbox/trunk/2to3/lib2to3/pytree.py
==============================================================================
--- sandbox/trunk/2to3/lib2to3/pytree.py (original)
+++ sandbox/trunk/2to3/lib2to3/pytree.py Sun Dec 14 22:22:09 2008
@@ -279,18 +279,21 @@
child.parent = self
self.children[i].parent = None
self.children[i] = child
+ self.changed()
def insert_child(self, i, child):
"""Equivalent to 'node.children.insert(i, child)'. This method also
sets the child's parent attribute appropriately."""
child.parent = self
self.children.insert(i, child)
+ self.changed()
def append_child(self, child):
"""Equivalent to 'node.children.append(child)'. This method also
sets the child's parent attribute appropriately."""
child.parent = self
self.children.append(child)
+ self.changed()
class Leaf(Base):
More information about the Python-checkins
mailing list