Mercurial > hg
comparison mercurial/revlog.py @ 43573:d3df05bab081
revlog: drop special hack in the `nodemap` property
This code does not seems necessary anymore.
Differential Revision: https://phab.mercurial-scm.org/D7361
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Sat, 09 Nov 2019 13:23:55 +0100 |
parents | b56de57c45ce |
children | 02802fa87b74 |
comparison
equal
deleted
inserted
replaced
43572:c314177eb9bb | 43573:d3df05bab081 |
---|---|
650 """iterate over all rev in this revlog (from start to stop)""" | 650 """iterate over all rev in this revlog (from start to stop)""" |
651 return storageutil.iterrevs(len(self), start=start, stop=stop) | 651 return storageutil.iterrevs(len(self), start=start, stop=stop) |
652 | 652 |
653 @util.propertycache | 653 @util.propertycache |
654 def nodemap(self): | 654 def nodemap(self): |
655 if self.index: | |
656 # populate mapping down to the initial node | |
657 node0 = self.index[0][7] # get around changelog filtering | |
658 self.rev(node0) | |
659 return self.index.nodemap | 655 return self.index.nodemap |
660 | 656 |
661 @property | 657 @property |
662 def _nodecache(self): | 658 def _nodecache(self): |
663 msg = "revlog._nodecache is deprecated, use revlog.index.nodemap" | 659 msg = "revlog._nodecache is deprecated, use revlog.index.nodemap" |