equal
deleted
inserted
replaced
109 self[entry[6]][7], |
109 self[entry[6]][7], |
110 entry[7], |
110 entry[7], |
111 ) |
111 ) |
112 return INDEX_ENTRY_V0.pack(*e2) |
112 return INDEX_ENTRY_V0.pack(*e2) |
113 |
113 |
114 def headrevs(self, excluded_revs=None): |
114 def headrevs(self, excluded_revs=None, stop_rev=None): |
115 count = len(self) |
115 count = len(self) |
|
116 if stop_rev is not None: |
|
117 count = min(count, stop_rev) |
116 if not count: |
118 if not count: |
117 return [node.nullrev] |
119 return [node.nullrev] |
118 # we won't iter over filtered rev so nobody is a head at start |
120 # we won't iter over filtered rev so nobody is a head at start |
119 ishead = [0] * (count + 1) |
121 ishead = [0] * (count + 1) |
120 revs = range(count) |
122 revs = range(count) |