Patchwork D8197: cleanup: remove redundant clearing of mergestate in rebase and shelve

login
register
mail settings
Submitter phabricator
Date March 4, 2020, 10:09 p.m.
Message ID <108a34a670455f82b2eb11ce6f1cdffd@localhost.localdomain>
Download mbox | patch
Permalink /patch/45485/
State Not Applicable
Headers show

Comments

phabricator - March 4, 2020, 10:09 p.m.
Closed by commit rHGf0021fbedea9: cleanup: remove redundant clearing of mergestate in rebase and shelve (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/D8197?vs=20403&id=20490

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

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

AFFECTED FILES
  hgext/rebase.py
  mercurial/shelve.py

CHANGE DETAILS




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

Patch

diff --git a/mercurial/shelve.py b/mercurial/shelve.py
--- a/mercurial/shelve.py
+++ b/mercurial/shelve.py
@@ -827,10 +827,6 @@ 
                 )
 
         if newnode is None:
-            # If it ended up being a no-op commit, then the normal
-            # merge state clean-up path doesn't happen, so do it
-            # here. Fix issue5494
-            merge.mergestate.clean(repo)
             shelvectx = state.pendingctx
             msg = _(
                 b'note: unshelved changes already existed '
@@ -1031,10 +1027,6 @@ 
             )
 
         if newnode is None:
-            # If it ended up being a no-op commit, then the normal
-            # merge state clean-up path doesn't happen, so do it
-            # here. Fix issue5494
-            merge.mergestate.clean(repo)
             shelvectx = tmpwctx
             msg = _(
                 b'note: unshelved changes already existed '
diff --git a/hgext/rebase.py b/hgext/rebase.py
--- a/hgext/rebase.py
+++ b/hgext/rebase.py
@@ -548,11 +548,6 @@ 
                     date=date,
                 )
 
-            if newnode is None:
-                # If it ended up being a no-op commit, then the normal
-                # merge state clean-up path doesn't happen, so do it
-                # here. Fix issue5494
-                mergemod.mergestate.clean(repo)
             return newnode
 
     def _rebasenode(self, tr, rev, allowdivergence, progressfn):