changeset 42112:29c22496dd97

branchmap: prevent using __getitem__() in branchheads() branchheads() can directly use self._entries instead. Differential Revision: https://phab.mercurial-scm.org/D6205
author Pulkit Goyal <pulkit@yandex-team.ru>
date Sun, 31 Mar 2019 16:20:17 +0300
parents f0fa0fc4900a
children f0def07fa82f
files mercurial/branchmap.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/branchmap.py	Wed Mar 27 21:33:04 2019 +0300
+++ b/mercurial/branchmap.py	Sun Mar 31 16:20:17 2019 +0300
@@ -290,7 +290,7 @@
         return (n for n in nodes if n not in self._closednodes)
 
     def branchheads(self, branch, closed=False):
-        heads = self[branch]
+        heads = self._entries[branch]
         if not closed:
             heads = list(self.iteropen(heads))
         return heads