[Updated] D12625: amend: stop specifying matcher, get all copies in wctx

spectral (Kyle Lippincott) phabricator at mercurial-scm.org
Thu May 12 05:08:38 UTC 2022


Closed by commit rHGdf68d64b0d50: amend: stop specifying matcher, get all copies in wctx (authored by spectral).
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/D12625?vs=33401&id=33403

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

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

AFFECTED FILES
  mercurial/cmdutil.py
  tests/test-amend.t

CHANGE DETAILS

diff --git a/tests/test-amend.t b/tests/test-amend.t
--- a/tests/test-amend.t
+++ b/tests/test-amend.t
@@ -625,4 +625,4 @@
   $ hg status --change . --copies
   A new_file_amend_me
   A r0_copied
-    r0 (missing-correct-output !)
+    r0
diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py
--- a/mercurial/cmdutil.py
+++ b/mercurial/cmdutil.py
@@ -2915,9 +2915,9 @@
         # filectxs from the old commit.
         if changes or changeset_copies:
             # Recompute copies (avoid recording a -> b -> a)
-            copied = copies.pathcopies(base, wctx, matcher)
-            if old.p2:
-                copied.update(copies.pathcopies(old.p2(), wctx, matcher))
+            copied = copies.pathcopies(base, wctx)
+            if old.p2():
+                copied.update(copies.pathcopies(old.p2(), wctx))
 
             # Prune files which were reverted by the updates: if old
             # introduced file X and the file was renamed in the working



To: spectral, #hg-reviewers
Cc: martinvonz, mercurial-patches
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-patches/attachments/20220512/3eef8d0c/attachment-0002.html>


More information about the Mercurial-patches mailing list