1422 ctxgen = (self[node] for node in newheadnodes |
1422 ctxgen = (self[node] for node in newheadnodes |
1423 if self.changelog.hasnode(node)) |
1423 if self.changelog.hasnode(node)) |
1424 cache = self._branchcaches[None] |
1424 cache = self._branchcaches[None] |
1425 cache.update(self, ctxgen) |
1425 cache.update(self, ctxgen) |
1426 cache.write(self) |
1426 cache.write(self) |
|
1427 |
|
1428 # When one tries to: |
|
1429 # 1) destroy nodes thus calling this method (e.g. strip) |
|
1430 # 2) use phasecache somewhere (e.g. commit) |
|
1431 # |
|
1432 # then 2) will fail because the phasecache contains nodes that were |
|
1433 # removed. We can either remove phasecache from the filecache, |
|
1434 # causing it to reload next time it is accessed, or simply filter |
|
1435 # the removed nodes now and write the updated cache. |
|
1436 if '_phasecache' in self._filecache: |
|
1437 self._phasecache.filterunknown(self) |
|
1438 self._phasecache.write() |
1427 |
1439 |
1428 # Ensure the persistent tag cache is updated. Doing it now |
1440 # Ensure the persistent tag cache is updated. Doing it now |
1429 # means that the tag cache only has to worry about destroyed |
1441 # means that the tag cache only has to worry about destroyed |
1430 # heads immediately after a strip/rollback. That in turn |
1442 # heads immediately after a strip/rollback. That in turn |
1431 # guarantees that "cachetip == currenttip" (comparing both rev |
1443 # guarantees that "cachetip == currenttip" (comparing both rev |