changeset 33449:5747967e257c

phase: put retractboundary out of the loop in advanceboundary It seems that we were calling retractboundary for each phases to process. Putting the retractboundary out of the loop reduce the number of calls, helping tracking the phases changes.
author Boris Feld <boris.feld@octobus.net>
date Mon, 10 Jul 2017 22:22:42 +0200
parents 04be8aec44a8
children d017f1d37378
files mercurial/phases.py
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/phases.py	Tue Jul 11 10:46:10 2017 -0700
+++ b/mercurial/phases.py	Mon Jul 10 22:22:42 2017 +0200
@@ -301,9 +301,9 @@
                 self._updateroots(phase, roots, tr)
                 # some roots may need to be declared for lower phases
                 delroots.extend(olds - roots)
-            # declare deleted root in the target phase
-            if targetphase != 0:
-                self.retractboundary(repo, tr, targetphase, delroots)
+        # declare deleted root in the target phase
+        if targetphase != 0:
+            self.retractboundary(repo, tr, targetphase, delroots)
         repo.invalidatevolatilesets()
 
     def retractboundary(self, repo, tr, targetphase, nodes):