D4183: parsers: adjust pure-python version to mimic a3dacabd476b
durin42 (Augie Fackler)
phabricator at mercurial-scm.org
Thu Aug 9 17:42:31 UTC 2018
durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
This was caught by the tests, to my surprise. I'll also follow up with
a test of the index[-1] behavior so we can be sure that remains
consistent, as I think that currently has no coverage.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D4183
AFFECTED FILES
mercurial/pure/parsers.py
CHANGE DETAILS
diff --git a/mercurial/pure/parsers.py b/mercurial/pure/parsers.py
--- a/mercurial/pure/parsers.py
+++ b/mercurial/pure/parsers.py
@@ -52,7 +52,7 @@
return i
def __getitem__(self, i):
- if i == -1 or i == len(self):
+ if i == -1:
return (0, 0, 0, -1, -1, -1, -1, nullid)
i = self._fix_index(i)
if i >= self._lgt:
To: durin42, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list