Mercurial > hg-stable
diff mercurial/tagmerge.py @ 46114:59fa3890d40a
node: import symbols explicitly
There is no point in lazy importing mercurial.node, it is used all over
the place anyway. So consistently import the used symbols directly.
Fix one file using symbols indirectly via mercurial.revlog.
Differential Revision: https://phab.mercurial-scm.org/D9480
author | Joerg Sonnenberger <joerg@bec.de> |
---|---|
date | Tue, 01 Dec 2020 21:54:46 +0100 |
parents | 89a2afe31e82 |
children | d55b71393907 |
line wrap: on
line diff
--- a/mercurial/tagmerge.py Sun Dec 13 18:29:22 2020 -0800 +++ b/mercurial/tagmerge.py Tue Dec 01 21:54:46 2020 +0100 @@ -75,16 +75,13 @@ from .i18n import _ from .node import ( - hex, - nullid, + nullhex, ) from . import ( tags as tagsmod, util, ) -hexnullid = hex(nullid) - def readtagsformerge(ui, repo, lines, fn=b'', keeplinenums=False): """read the .hgtags file into a structure that is suitable for merging @@ -246,8 +243,8 @@ pnlosttagset = basetagset - pntagset for t in pnlosttagset: pntags[t] = basetags[t] - if pntags[t][-1][0] != hexnullid: - pntags[t].append([hexnullid, None]) + if pntags[t][-1][0] != nullhex: + pntags[t].append([nullhex, None]) conflictedtags = [] # for reporting purposes mergedtags = util.sortdict(p1tags)