[PATCH 2 of 2] obsolete: clarify that 'successorssets' returns the latests successors

Pierre-Yves David pierre-yves.david at ens-lyon.org
Tue Sep 15 15:27:06 CDT 2015


# HG changeset patch
# User Pierre-Yves David <pierre-yves.david at fb.com>
# Date 1442347923 25200
#      Tue Sep 15 13:12:03 2015 -0700
# Node ID 56d0b34f12829f259dcb9f53e6c85e1c7285286c
# Parent  bbf3eb4fa7c41270fcc7823240862045da1454a7
obsolete: clarify that 'successorssets' returns the latests successors

We do not return the first successors we found, we returns the latest (non
obsolete  (mostly)) one following the obsolete link transitively. We update the
documentation to make this clean.

diff --git a/mercurial/obsolete.py b/mercurial/obsolete.py
--- a/mercurial/obsolete.py
+++ b/mercurial/obsolete.py
@@ -839,11 +839,11 @@ def foreground(repo, nodes):
             foreground = set(repo.set('%ln::', known))
     return set(c.node() for c in foreground)
 
 
 def successorssets(repo, initialnode, cache=None):
-    """Return all set of successors of initial nodes
+    """Return all set of latest successors of initial nodes
 
     The successors set of a changeset A are the group of revisions that succeed
     A. It succeeds A as a consistent whole, each revision being only a partial
     replacement. The successors set contains non-obsolete changesets only.
 


More information about the Mercurial-devel mailing list