~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/deprecated_graph.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2007-07-25 02:47:25 UTC
  • mfrom: (2625.8.2 knits)
  • Revision ID: pqm@pqm.ubuntu.com-20070725024725-x592w4y7gdqxv81x
(robertc) Allow the adaption of Knits to external indices via KnitGraphIndex. (Robert Collins).

Show diffs side-by-side

added added

removed removed

Lines of Context:
125
125
 
126
126
    def add_node(self, node_id, parent_ids):
127
127
        """Add node_id to the graph with parent_ids as its parents."""
128
 
        if parent_ids == []:
 
128
        if len(parent_ids) == 0:
129
129
            self.roots.add(node_id)
130
130
        self._graph_ancestors[node_id] = list(parent_ids)
131
131
        self._ensure_descendant(node_id)