def __init__(self): Node.__init__(self) self.children = [] # mostly kvpairs self.namebearing = True
def reparent(self, item): # should not be necessary if isinstance(item, KVPair): Node.reparent(self, item.key) Node.reparent(self, item.value) else: Node.reparent(self, item)