equal
deleted
inserted
replaced
625 # this private cache holds all heads (not just the branch tips) |
625 # this private cache holds all heads (not just the branch tips) |
626 self._branchcache = partial |
626 self._branchcache = partial |
627 |
627 |
628 def branchmap(self): |
628 def branchmap(self): |
629 '''returns a dictionary {branch: [branchheads]}''' |
629 '''returns a dictionary {branch: [branchheads]}''' |
630 self.updatebranchcache() |
630 if self.changelog.filteredrevs: |
631 return self._branchcache |
631 # some changeset are excluded we can't use the cache |
|
632 branchmap = {} |
|
633 self._updatebranchcache(branchmap, (self[r] for r in self)) |
|
634 return branchmap |
|
635 else: |
|
636 self.updatebranchcache() |
|
637 return self._branchcache |
|
638 |
632 |
639 |
633 def _branchtip(self, heads): |
640 def _branchtip(self, heads): |
634 '''return the tipmost branch head in heads''' |
641 '''return the tipmost branch head in heads''' |
635 tip = heads[-1] |
642 tip = heads[-1] |
636 for h in reversed(heads): |
643 for h in reversed(heads): |