~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/revision.py

  • Committer: Martin Pool
  • Date: 2005-09-19 08:02:41 UTC
  • Revision ID: mbp@sourcefrog.net-20050919080241-d9460223db8f7d90
- rename to Revision.parent_ids to avoid confusion with old usage
  where Revision.parents held objects rather than strings\t

Show diffs side-by-side

added added

removed removed

Lines of Context:
27
27
 
28
28
    After bzr 0.0.5 revisions are allowed to have multiple parents.
29
29
 
30
 
    parents
31
 
        List of parent revisions, each is a RevisionReference.
 
30
    parent_ids
 
31
        List of parent revision_ids
32
32
    """
33
33
    inventory_id = None
34
34
    inventory_sha1 = None
40
40
    
41
41
    def __init__(self, **args):
42
42
        self.__dict__.update(args)
43
 
        self.parents = []
 
43
        self.parent_ids = []
44
44
        self.parent_sha1s = []
45
45
 
46
46
 
105
105
                    continue
106
106
            if only_present:
107
107
                yield ancestor, distance
108
 
            new_ancestors.extend(revision.parents)
 
108
            new_ancestors.extend(revision.parent_ids)
109
109
        ancestors = new_ancestors
110
110
        distance += 1
111
111
 
211
211
    while len(active) > 0:
212
212
        new_active = []
213
213
        for line in active:
214
 
            for parent in rev_source.get_revision(line[-1]).parents:
 
214
            for parent in rev_source.get_revision(line[-1]).parent_ids:
215
215
                line_copy = line[:]
216
216
                if parent == ancestor_id:
217
217
                    successful_lines.append(line_copy)