[PATCH 2 of 7] copies: rename m2 to mdst

Stanislau Hlebik stash at fb.com
Mon May 29 09:11:58 EDT 2017


# HG changeset patch
# User Stanislau Hlebik <stash at fb.com>
# Date 1496062335 25200
#      Mon May 29 05:52:15 2017 -0700
# Node ID 2cf8c7e99a33dce384b49d3fd0fc4c9512ee94b5
# Parent  75f0d8342109877a0dd620df3f566d0f080a9138
copies: rename m2 to mdst

Small refactoring to rename m2 to more clearer mdst.

diff --git a/mercurial/copies.py b/mercurial/copies.py
--- a/mercurial/copies.py
+++ b/mercurial/copies.py
@@ -598,14 +598,14 @@
     except StopIteration:
         return False
 
-def _checkcopies(ctx, f, msrc, m2, base, tca, remotebase, limit, data):
+def _checkcopies(ctx, f, msrc, mdst, base, tca, remotebase, limit, data):
     """
-    check possible copies of f from msrc to m2
+    check possible copies of f from msrc to mdst
 
     ctx = starting context for f in srcm
     f = the filename to check (as in msrc)
     msrc = the source manifest
-    m2 = the destination manifest
+    mdst = the destination manifest
     base = the changectx used as a merge base
     tca = topological common ancestor for graft-like scenarios
     remotebase = True if base is outside tca::ctx, False otherwise
@@ -653,11 +653,11 @@
             data['fullcopy'][of] = f # grafting backwards through renames
         else:
             data['fullcopy'][f] = of
-        if of not in m2:
+        if of not in mdst:
             continue # no match, keep looking
-        if m2[of] == mb.get(of):
+        if mdst[of] == mb.get(of):
             return # no merge needed, quit early
-        c2 = getfctx(of, m2[of])
+        c2 = getfctx(of, mdst[of])
         # c2 might be a plain new file on added on destination side that is
         # unrelated to the droids we are looking for.
         cr = _related(oc, c2, tca.rev())


More information about the Mercurial-devel mailing list