[PATCH 1 of 7] revlog: parentdelta flags for revlog index
in3xes at gmail.com
in3xes at gmail.com
Fri Aug 6 02:00:33 CDT 2010
# HG changeset patch
# User Pradeepkumar Gayam <in3xes at gmail.com>
# Date 1281076770 -19800
# Node ID ea75c464fe41b33161561c131946a47fb94612dc
# Parent b8b4a2417fbd51067524f0a9bb4dd698f60a31b3
revlog: parentdelta flags for revlog index
diff -r b8b4a2417fbd -r ea75c464fe41 mercurial/revlog.py
--- a/mercurial/revlog.py Wed Aug 04 13:21:11 2010 -0500
+++ b/mercurial/revlog.py Fri Aug 06 12:09:30 2010 +0530
@@ -34,8 +34,9 @@
REVLOGNG_FLAGS = REVLOGNGINLINEDATA | REVLOGSHALLOW
# revlog index flags
+REVIDX_PARENTDELTA = 1
REVIDX_PUNCHED_FLAG = 2
-REVIDX_KNOWN_FLAGS = REVIDX_PUNCHED_FLAG
+REVIDX_KNOWN_FLAGS = REVIDX_PUNCHED_FLAG | REVIDX_PARENTDELTA
# amount of data read unconditionally, should be >= 4
# when not inline: threshold for using lazy index
@@ -441,12 +442,14 @@
self.nodemap = {nullid: nullrev}
self.index = []
self._shallowroot = shallowroot
+ self._parentdelta = 0
v = REVLOG_DEFAULT_VERSION
if hasattr(opener, 'options') and 'defversion' in opener.options:
v = opener.options['defversion']
if v & REVLOGNG:
v |= REVLOGNGINLINEDATA
+ self._parentdelta = v & REVLOGNG and 'parentdelta' in opener.options
if shallowroot:
v |= REVLOGSHALLOW
More information about the Mercurial-devel
mailing list