equal
deleted
inserted
replaced
664 def branchmap(self): |
664 def branchmap(self): |
665 '''returns a dictionary {branch: [branchheads]}''' |
665 '''returns a dictionary {branch: [branchheads]}''' |
666 if self.changelog.filteredrevs: |
666 if self.changelog.filteredrevs: |
667 # some changeset are excluded we can't use the cache |
667 # some changeset are excluded we can't use the cache |
668 bmap = branchmap.branchcache() |
668 bmap = branchmap.branchcache() |
669 branchmap.update(self, bmap, (self[r] for r in self)) |
669 bmap.update(self, (self[r] for r in self)) |
670 return bmap |
670 return bmap |
671 else: |
671 else: |
672 branchmap.updatecache(self) |
672 branchmap.updatecache(self) |
673 return self._branchcache |
673 return self._branchcache |
674 |
674 |
1435 # will be caught the next time it is read. |
1435 # will be caught the next time it is read. |
1436 if newheadnodes: |
1436 if newheadnodes: |
1437 ctxgen = (self[node] for node in newheadnodes |
1437 ctxgen = (self[node] for node in newheadnodes |
1438 if self.changelog.hasnode(node)) |
1438 if self.changelog.hasnode(node)) |
1439 cache = self._branchcache |
1439 cache = self._branchcache |
1440 branchmap.update(self, cache, ctxgen) |
1440 cache.update(self, ctxgen) |
1441 cache.write(self) |
1441 cache.write(self) |
1442 |
1442 |
1443 # Ensure the persistent tag cache is updated. Doing it now |
1443 # Ensure the persistent tag cache is updated. Doing it now |
1444 # means that the tag cache only has to worry about destroyed |
1444 # means that the tag cache only has to worry about destroyed |
1445 # heads immediately after a strip/rollback. That in turn |
1445 # heads immediately after a strip/rollback. That in turn |