Mercurial > hg
comparison hgext/hbisect.py @ 5718:442c613fd4aa
bisect: remove stop argument to ancestors function
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Thu, 27 Dec 2007 23:55:39 -0600 |
parents | 18fdfafdb3e9 |
children | 7edf0501f643 |
comparison
equal
deleted
inserted
replaced
5717:18fdfafdb3e9 | 5718:442c613fd4aa |
---|---|
66 self.is_reset = True | 66 self.is_reset = True |
67 return 0 | 67 return 0 |
68 | 68 |
69 def __ancestors_and_nb_ancestors(self, head, stop=None): | 69 def __ancestors_and_nb_ancestors(self, head, stop=None): |
70 """ | 70 """ |
71 if stop is None then ancestors of goodrevs are used as | |
72 lower limit. | |
73 | |
74 returns (anc, n_child) where anc is the set of the ancestors of head | 71 returns (anc, n_child) where anc is the set of the ancestors of head |
75 and n_child is a dictionary with the following mapping: | 72 and n_child is a dictionary with the following mapping: |
76 node -> number of ancestors (self included) | 73 node -> number of ancestors (self included) |
74 | |
75 ancestors of goodrevs are used as lower limit. | |
77 """ | 76 """ |
78 cl = self.repo.changelog | 77 cl = self.repo.changelog |
79 if not stop: | 78 if not stop: |
80 stop = sets.Set([]) | 79 stop = sets.Set([]) |
81 for i in xrange(len(self.goodrevs)-1, -1, -1): | 80 for i in xrange(len(self.goodrevs)-1, -1, -1): |