mercurial/revlog.py
changeset 51066 7c2dc75cdc0f
parent 51065 f71f07a679b4
child 51069 81f3877372c3
--- a/mercurial/revlog.py	Tue Oct 10 11:27:39 2023 +0200
+++ b/mercurial/revlog.py	Tue Oct 10 11:29:19 2023 +0200
@@ -1156,7 +1156,7 @@
         return self.index[rev][1]
 
     def sidedata_length(self, rev):
-        if not self.hassidedata:
+        if not self.feature_config.has_side_data:
             return 0
         return self.index[rev][9]
 
@@ -2565,7 +2565,7 @@
 
         if sidedata is None:
             sidedata = {}
-        elif sidedata and not self.hassidedata:
+        elif sidedata and not self.feature_config.has_side_data:
             raise error.ProgrammingError(
                 _(b"trying to add sidedata to a revlog who don't support them")
             )
@@ -2824,7 +2824,7 @@
             compression_mode, deltainfo = r
 
         sidedata_compression_mode = COMP_MODE_INLINE
-        if sidedata and self.hassidedata:
+        if sidedata and self.feature_config.has_side_data:
             sidedata_compression_mode = COMP_MODE_PLAIN
             serialized_sidedata = sidedatautil.serialize_sidedata(sidedata)
             sidedata_offset = self._docket.sidedata_end
@@ -3640,7 +3640,7 @@
         return d
 
     def rewrite_sidedata(self, transaction, helpers, startrev, endrev):
-        if not self.hassidedata:
+        if not self.feature_config.has_side_data:
             return
         # revlog formats with sidedata support does not support inline
         assert not self._inline
@@ -3669,7 +3669,7 @@
                 )
 
                 sidedata_compression_mode = COMP_MODE_INLINE
-                if serialized_sidedata and self.hassidedata:
+                if serialized_sidedata and self.feature_config.has_side_data:
                     sidedata_compression_mode = COMP_MODE_PLAIN
                     h, comp_sidedata = self.compress(serialized_sidedata)
                     if (