diff mercurial/mergestate.py @ 45531:590a840fa367

mergestate: define NO_OP_ACTION in module scope instead of inside mergeresult This makes sure it isn't intended to be overridden by subclasses. Thanks to Yuya for the nice suggestion. Differential Revision: https://phab.mercurial-scm.org/D9025
author Pulkit Goyal <7895pulkit@gmail.com>
date Wed, 16 Sep 2020 18:09:32 +0530
parents 6877b0ee5f9d
children 9f14bb4d59ea
line wrap: on
line diff
--- a/mercurial/mergestate.py	Wed Sep 09 16:49:19 2020 +0530
+++ b/mercurial/mergestate.py	Wed Sep 16 18:09:32 2020 +0530
@@ -123,6 +123,13 @@
 ACTION_EXEC = b'e'
 ACTION_CREATED_MERGE = b'cm'
 
+# actions which are no op
+NO_OP_ACTIONS = (
+    ACTION_KEEP,
+    ACTION_KEEP_ABSENT,
+    ACTION_KEEP_NEW,
+)
+
 
 class _mergestate_base(object):
     '''track 3-way merge state of individual files