[PATCH 5 of 8] copies: don't record divergence for files needing no merge (issue4028)
Gábor Stefanik
gabor.stefanik at nng.com
Tue Oct 4 10:06:03 EDT 2016
# HG changeset patch
# User Gábor Stefanik <gabor.stefanik at nng.com>
# Date 1475494199 -7200
# Mon Oct 03 13:29:59 2016 +0200
# Node ID bc8729a69d10d61498712d5dab773918f1edcde0
# Parent a2b50d0c5dc69a4ce15b6a54d030e478c0f4cc41
copies: don't record divergence for files needing no merge (issue4028)
diff --git a/mercurial/copies.py b/mercurial/copies.py
--- a/mercurial/copies.py
+++ b/mercurial/copies.py
@@ -524,13 +524,12 @@
if of not in m2:
continue # no match, keep looking
if m2[of] == ma.get(of):
- break # no merge needed, quit early
+ return # no merge needed, quit early
c2 = getfctx(of, m2[of])
cr = _related(oc, c2, ca.rev())
if cr and (of == f or of == c2.path()): # non-divergent
copy[f] = of
- of = None
- break
+ return
if of in ma:
diverge.setdefault(of, []).append(f)
More information about the Mercurial-devel
mailing list