changeset 39272:160bd45cc6af

phase: explicitly exclude secret phase and above The comment explicitly mention the secret phase so we should as well use that in the code.
author Boris Feld <boris.feld@octobus.net>
date Tue, 05 Jun 2018 20:47:52 +0200
parents fd7376fa60e7
children 1ea6772fb415
files mercurial/phases.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/phases.py	Tue Jun 05 18:16:07 2018 +0200
+++ b/mercurial/phases.py	Tue Jun 05 20:47:52 2018 +0200
@@ -586,7 +586,7 @@
     headsbyphase = [[] for i in allphases]
     # No need to keep track of secret phase; any heads in the subset that
     # are not mentioned are implicitly secret.
-    for phase in allphases[:-1]:
+    for phase in allphases[:secret]:
         revset = "heads(%%ln & %s())" % phasenames[phase]
         headsbyphase[phase] = [cl.node(r) for r in repo.revs(revset, subset)]
     return headsbyphase