Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/revlog.py @ 43628:f5991fd7cca7
revlog: remove the, now unused, `revlog._nodepos` attribute
Spotted by Yuya Nishihara.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Sun, 10 Nov 2019 18:15:54 +0100 |
parents | 02802fa87b74 |
children | c207c46a86b9 |
comparison
equal
deleted
inserted
replaced
43627:9e1932eb41f9 | 43628:f5991fd7cca7 |
---|---|
419 self._deltabothparents = True | 419 self._deltabothparents = True |
420 self.index = None | 420 self.index = None |
421 # Mapping of partial identifiers to full nodes. | 421 # Mapping of partial identifiers to full nodes. |
422 self._pcache = {} | 422 self._pcache = {} |
423 # Mapping of revision integer to full node. | 423 # Mapping of revision integer to full node. |
424 self._nodepos = None | |
425 self._compengine = b'zlib' | 424 self._compengine = b'zlib' |
426 self._compengineopts = {} | 425 self._compengineopts = {} |
427 self._maxdeltachainspan = -1 | 426 self._maxdeltachainspan = -1 |
428 self._withsparseread = False | 427 self._withsparseread = False |
429 self._sparserevlog = False | 428 self._sparserevlog = False |
2221 p2r, | 2220 p2r, |
2222 node, | 2221 node, |
2223 ) | 2222 ) |
2224 self.index.append(e) | 2223 self.index.append(e) |
2225 | 2224 |
2226 # Reset the pure node cache start lookup offset to account for new | |
2227 # revision. | |
2228 if self._nodepos is not None: | |
2229 self._nodepos = curr | |
2230 | |
2231 entry = self._io.packentry(e, self.node, self.version, curr) | 2225 entry = self._io.packentry(e, self.node, self.version, curr) |
2232 self._writeentry( | 2226 self._writeentry( |
2233 transaction, ifh, dfh, entry, deltainfo.data, link, offset | 2227 transaction, ifh, dfh, entry, deltainfo.data, link, offset |
2234 ) | 2228 ) |
2235 | 2229 |
2460 self._revisioncache = None | 2454 self._revisioncache = None |
2461 self._chaininfocache = {} | 2455 self._chaininfocache = {} |
2462 self._chunkclear() | 2456 self._chunkclear() |
2463 | 2457 |
2464 del self.index[rev:-1] | 2458 del self.index[rev:-1] |
2465 self._nodepos = None | |
2466 | 2459 |
2467 def checksize(self): | 2460 def checksize(self): |
2468 """Check size of index and data files | 2461 """Check size of index and data files |
2469 | 2462 |
2470 return a (dd, di) tuple. | 2463 return a (dd, di) tuple. |