directaccess: use resolvehexnodeidprefix() instead of _partialmatch()
authorMartin von Zweigbergk <martinvonz@google.com>
Mon, 07 May 2018 12:18:09 -0700
changeset 37912 69de3c3de036
parent 37911 0a79fb64118e
child 37913 73a74f29eb87
directaccess: use resolvehexnodeidprefix() instead of _partialmatch() Same reasoning as previous commit: I want to make resolvehexnodeidprefix() move complex and don't want to duplicate that code in directaccess. Differential Revision: https://phab.mercurial-scm.org/D3463
mercurial/scmutil.py
--- a/mercurial/scmutil.py	Mon May 07 14:32:55 2018 -0700
+++ b/mercurial/scmutil.py	Mon May 07 12:18:09 2018 -0700
@@ -1541,7 +1541,6 @@
     unficl = unfi.changelog
     cl = repo.changelog
     tiprev = len(unficl)
-    pmatch = unficl._partialmatch
     allowrevnums = repo.ui.configbool('experimental', 'directaccess.revnums')
     for s in symbols:
         try:
@@ -1557,7 +1556,7 @@
             pass
 
         try:
-            s = pmatch(s)
+            s = resolvehexnodeidprefix(unfi, s)
         except (error.LookupError, error.WdirUnsupported):
             s = None