changeset 43540:c8f1e8412db4

index: use `index.has_node` in `obsutil.exclusivemarkers` Differential Revision: https://phab.mercurial-scm.org/D7333
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Fri, 08 Nov 2019 14:19:53 +0100
parents 44f54b8f9f10
children 1944aaaecabf
files mercurial/obsutil.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/obsutil.py	Fri Nov 08 14:17:03 2019 +0100
+++ b/mercurial/obsutil.py	Fri Nov 08 14:19:53 2019 +0100
@@ -249,7 +249,7 @@
     unfi = repo.unfiltered()
 
     # shortcut to various useful item
-    nm = unfi.changelog.nodemap
+    has_node = unfi.changelog.index.has_node
     precursorsmarkers = unfi.obsstore.predecessors
     successormarkers = unfi.obsstore.successors
     childrenmarkers = unfi.obsstore.children
@@ -297,7 +297,7 @@
                 continue
 
             # is this a locally known node ?
-            known = prec in nm
+            known = has_node(prec)
             # if locally-known and not in the <nodes> set the traversal
             # stop here.
             if known and prec not in nodes: