D7494: localrepo: fastpath access to "."

marmoute (Pierre-Yves David) phabricator at mercurial-scm.org
Sat Nov 23 08:04:49 EST 2019


marmoute updated this revision to Diff 18359.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D7494?vs=18301&id=18359

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7494/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D7494

AFFECTED FILES
  mercurial/localrepo.py

CHANGE DETAILS

diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py
--- a/mercurial/localrepo.py
+++ b/mercurial/localrepo.py
@@ -1540,6 +1540,9 @@
             pair = (rev, node)
             quick[rev] = pair
             quick[node] = pair
+        p1node = self.dirstate.p1()
+        if p1node != nullid:
+            quick[b'.'] = quick[p1node]
         return quick
 
     @unfilteredmethod



To: marmoute, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list