rebase: remove an unnecessary adjustdest in clearrebased
authorJun Wu <quark@fb.com>
Tue, 29 Aug 2017 17:49:13 -0700
changeset 34025 06b0cc2588de
parent 34024 32528419db64
child 34026 9422107a6b64
rebase: remove an unnecessary adjustdest in clearrebased `rev` being "skipped" could currently be caused by moving `rev` does not create a new commit. In this case, `state[rev]` is already changed to `p1`, and is a sane destination for bookmark or working parent movement. Therefore an additional destination adjustment is unnecessary. Differential Revision: https://phab.mercurial-scm.org/D565
hgext/rebase.py
--- a/hgext/rebase.py	Mon Aug 21 20:22:07 2017 -0700
+++ b/hgext/rebase.py	Tue Aug 29 17:49:13 2017 -0700
@@ -1497,7 +1497,7 @@
     # Move bookmark of skipped nodes to destination. This cannot be handled
     # by scmutil.cleanupnodes since it will treat rev as removed (no successor)
     # and move bookmark backwards.
-    bmchanges = [(name, tonode(max(adjustdest(repo, rev, destmap, state))))
+    bmchanges = [(name, tonode(state[rev]))
                  for rev in skipped
                  for name in repo.nodebookmarks(tonode(rev))]
     if bmchanges: