diff mercurial/localrepo.py @ 39957:e1e3d1b498d3

context: reduce dependence of changectx constructor I want to change the constructor's signature and letting all creation of changectx instances go through the repo simplifies that. Differential Revision: https://phab.mercurial-scm.org/D4826
author Martin von Zweigbergk <martinvonz@google.com>
date Wed, 26 Sep 2018 22:44:51 -0700
parents 823a580448d7
children 3d35304bd09b
line wrap: on
line diff
--- a/mercurial/localrepo.py	Mon Oct 01 23:11:07 2018 -0700
+++ b/mercurial/localrepo.py	Wed Sep 26 22:44:51 2018 -0700
@@ -1210,7 +1210,7 @@
             return changeid
         if isinstance(changeid, slice):
             # wdirrev isn't contiguous so the slice shouldn't include it
-            return [context.changectx(self, i)
+            return [self[i]
                     for i in pycompat.xrange(*changeid.indices(len(self)))
                     if i not in self.changelog.filteredrevs]
         try: