Mercurial > hg
changeset 42134:f0203c3406e7
branchcache: lazily validate nodes in iteritems()
This saves ~0.30 sec on creating a new branch on our internal repo.
Differential Revision: https://phab.mercurial-scm.org/D6236
author | Pulkit Goyal <pulkit@yandex-team.ru> |
---|---|
date | Mon, 15 Apr 2019 19:21:41 +0300 |
parents | 75e8e16ca107 |
children | b970fece153d |
files | mercurial/branchmap.py |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/branchmap.py Tue Apr 16 15:01:33 2019 +0300 +++ b/mercurial/branchmap.py Mon Apr 15 19:21:41 2019 +0300 @@ -219,8 +219,9 @@ return key in self._entries def iteritems(self): - self._verifyall() - return self._entries.iteritems() + for k, v in self._entries.iteritems(): + self._verifybranch(k) + yield k, v def hasbranch(self, label): """ checks whether a branch of this name exists or not """