destutil: drop now-unused "check" parameter from destupdate()
authorMartin von Zweigbergk <martinvonz@google.com>
Mon, 13 Feb 2017 11:32:09 -0800
changeset 30962 11c253997b0e
parent 30961 330fbd515512
child 30963 7beb3ec34443
destutil: drop now-unused "check" parameter from destupdate()
mercurial/destutil.py
mercurial/hg.py
mercurial/revset.py
--- a/mercurial/destutil.py	Thu Feb 09 09:52:32 2017 -0800
+++ b/mercurial/destutil.py	Mon Feb 13 11:32:09 2017 -0800
@@ -14,7 +14,7 @@
     obsolete,
 )
 
-def _destupdateobs(repo, clean, check):
+def _destupdateobs(repo, clean):
     """decide of an update destination from obsolescence markers"""
     node = None
     wc = repo[None]
@@ -50,7 +50,7 @@
                 movemark = repo['.'].node()
     return node, movemark, None
 
-def _destupdatebook(repo, clean, check):
+def _destupdatebook(repo, clean):
     """decide on an update destination from active bookmark"""
     # we also move the active bookmark, if any
     activemark = None
@@ -59,7 +59,7 @@
         activemark = node
     return node, movemark, activemark
 
-def _destupdatebranch(repo, clean, check):
+def _destupdatebranch(repo, clean):
     """decide on an update destination from current branch
 
     This ignores closed branch heads.
@@ -85,7 +85,7 @@
         node = repo['.'].node()
     return node, movemark, None
 
-def _destupdatebranchfallback(repo, clean, check):
+def _destupdatebranchfallback(repo, clean):
     """decide on an update destination from closed heads in current branch"""
     wc = repo[None]
     currentbranch = wc.branch()
@@ -115,7 +115,7 @@
                      'branchfallback': _destupdatebranchfallback,
                      }
 
-def destupdate(repo, clean=False, check=False):
+def destupdate(repo, clean=False):
     """destination for bare update operation
 
     return (rev, movemark, activemark)
@@ -128,7 +128,7 @@
     node = movemark = activemark = None
 
     for step in destupdatesteps:
-        node, movemark, activemark = destupdatestepmap[step](repo, clean, check)
+        node, movemark, activemark = destupdatestepmap[step](repo, clean)
         if node is not None:
             break
     rev = repo[node].rev()
--- a/mercurial/hg.py	Thu Feb 09 09:52:32 2017 -0800
+++ b/mercurial/hg.py	Mon Feb 13 11:32:09 2017 -0800
@@ -732,7 +732,7 @@
         movemarkfrom = None
         warndest = False
         if checkout is None:
-            updata = destutil.destupdate(repo, clean=clean, check=check)
+            updata = destutil.destupdate(repo, clean=clean)
             checkout, movemarkfrom, brev = updata
             warndest = True
 
--- a/mercurial/revset.py	Thu Feb 09 09:52:32 2017 -0800
+++ b/mercurial/revset.py	Mon Feb 13 11:32:09 2017 -0800
@@ -507,7 +507,7 @@
 @predicate('_destupdate')
 def _destupdate(repo, subset, x):
     # experimental revset for update destination
-    args = getargsdict(x, 'limit', 'clean check')
+    args = getargsdict(x, 'limit', 'clean')
     return subset & baseset([destutil.destupdate(repo, **args)[0]])
 
 @predicate('_destmerge')