Patchwork D7988: merge: move initialization of copy dicts to one place

login
register
mail settings
Submitter phabricator
Date Jan. 29, 2020, 11:19 p.m.
Message ID <71a8bd681970d5b87fed09511f64c526@localhost.localdomain>
Download mbox | patch
Permalink /patch/44742/
State Not Applicable
Headers show

Comments

phabricator - Jan. 29, 2020, 11:19 p.m.
Closed by commit rHG4c90001a6084: merge: move initialization of copy dicts to one place (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.
This revision was not accepted when it landed; it landed in state "Needs Review".

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D7988?vs=19581&id=19684

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7988/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D7988

AFFECTED FILES
  mercurial/merge.py

CHANGE DETAILS




To: martinvonz, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/mercurial/merge.py b/mercurial/merge.py
--- a/mercurial/merge.py
+++ b/mercurial/merge.py
@@ -1256,14 +1256,13 @@ 
     if matcher is not None and matcher.always():
         matcher = None
 
-    copy, movewithdir, diverge, renamedelete, dirmove = {}, {}, {}, {}, {}
-
     # manifests fetched in order are going to be faster, so prime the caches
     [
         x.manifest()
         for x in sorted(wctx.parents() + [p2, pa], key=scmutil.intrev)
     ]
 
+    copy, movewithdir, diverge, renamedelete, dirmove = {}, {}, {}, {}, {}
     if followcopies:
         ret = copies.mergecopies(repo, wctx, p2, pa)
         copy, movewithdir, diverge, renamedelete, dirmove = ret