# HG changeset patch # User Yuya Nishihara # Date 2020-06-02 12:39:07 # Node ID ad6971e6740c143062ba2275dc7b07742ea33364 # Parent fb2936c5f6dcbdbf25a7ce0c99eda100a41cce94 simplemerge: fix function name that tests if ctx is not null revision diff --git a/mercurial/simplemerge.py b/mercurial/simplemerge.py --- a/mercurial/simplemerge.py +++ b/mercurial/simplemerge.py @@ -456,7 +456,7 @@ def _bytes_to_set(b): return set(b[x : x + 1] for x in range(len(b))) -def is_null(ctx): +def is_not_null(ctx): if not util.safehasattr(ctx, "node"): return False return ctx.node() != nodemod.nullid @@ -520,7 +520,7 @@ def simplemerge(ui, localctx, basectx, o flags = localctx.flags() localflags = _bytes_to_set(flags) otherflags = _bytes_to_set(otherctx.flags()) - if is_null(basectx) and localflags != otherflags: + if is_not_null(basectx) and localflags != otherflags: baseflags = _bytes_to_set(basectx.flags()) flags = localflags & otherflags for f in localflags.symmetric_difference(otherflags):