diff mercurial/simplemerge.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 bdc2bf68f19e
children 98e3a693061a
line wrap: on
line diff
--- a/mercurial/simplemerge.py	Sun Dec 13 18:29:22 2020 -0800
+++ b/mercurial/simplemerge.py	Tue Dec 01 21:54:46 2020 +0100
@@ -19,10 +19,10 @@
 from __future__ import absolute_import
 
 from .i18n import _
+from .node import nullid
 from . import (
     error,
     mdiff,
-    node as nodemod,
     pycompat,
     util,
 )
@@ -452,7 +452,7 @@
 def is_not_null(ctx):
     if not util.safehasattr(ctx, "node"):
         return False
-    return ctx.node() != nodemod.nullid
+    return ctx.node() != nullid
 
 
 def _mergediff(m3, name_a, name_b, name_base):