[PATCH 7 of 8] obsmarkers: add a `parentnodes` method to retrieve parents information

Pierre-Yves David pierre-yves.david at ens-lyon.org
Tue Aug 19 17:46:45 CDT 2014


# HG changeset patch
# User Pierre-Yves David <pierre-yves.david at fb.com>
# Date 1408407267 25200
#      Mon Aug 18 17:14:27 2014 -0700
# Node ID 0d7b583134d03f42addf4c11a0132a36e8ad2420
# Parent  9c305df675f85efb5e9e0035a787c24052bd07d5
obsmarkers: add a `parentnodes` method to retrieve parents information

diff --git a/mercurial/obsolete.py b/mercurial/obsolete.py
--- a/mercurial/obsolete.py
+++ b/mercurial/obsolete.py
@@ -239,10 +239,14 @@ class marker(object):
 
     def succnodes(self):
         """List of successor changesets node identifiers"""
         return self._data[1]
 
+    def parentnodes(self):
+        """Parents of the precursors (None if not recorded)"""
+        return self._data[5]
+
     def metadata(self):
         """Decoded metadata dictionary"""
         if self._decodedmeta is None:
             self._decodedmeta = decodemeta(self._data[3])
         return self._decodedmeta


More information about the Mercurial-devel mailing list