~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/bundle/serializer/__init__.py

  • Committer: Aaron Bentley
  • Date: 2007-06-17 17:07:04 UTC
  • mto: (2490.2.32 graphwalker)
  • mto: This revision was merged to the branch mainline in revision 2542.
  • Revision ID: aaron.bentley@utoronto.ca-20070617170704-z3xbz0t5nqddnyeo
Make topological sorting optional for get_ancestry

Show diffs side-by-side

added added

removed removed

Lines of Context:
120
120
    """
121
121
    if base_revision_id is NULL_REVISION:
122
122
        base_revision_id = None
123
 
    base_ancestry = set(repository.get_ancestry(base_revision_id))
124
 
    revision_ids = [r for r in repository.get_ancestry(revision_id) if r
125
 
                    not in base_ancestry]
 
123
    base_ancestry = set(repository.get_ancestry(base_revision_id,
 
124
                                                topo_sorted=False))
 
125
    revision_ids = [r for r in repository.get_ancestry(revision_id)
 
126
                    if r not in base_ancestry]
126
127
    revision_ids = list(reversed(revision_ids))
127
128
    write(repository, revision_ids, out, format,
128
129
          forced_bases = {revision_id:base_revision_id})