mercurial/filelog.py
changeset 50637 32837c7e2e4b
parent 50346 87f0155d68aa
child 51022 33d2f0164d0d
--- a/mercurial/filelog.py	Mon May 29 04:26:39 2023 +0200
+++ b/mercurial/filelog.py	Sun May 28 05:23:46 2023 +0200
@@ -42,6 +42,15 @@
         opts = opener.options
         self._fix_issue6528 = opts.get(b'issue6528.fix-incoming', True)
 
+    def get_revlog(self):
+        """return an actual revlog instance if any
+
+        This exist because a lot of code leverage the fact the underlying
+        storage is a revlog for optimization, so giving simple way to access
+        the revlog instance helps such code.
+        """
+        return self._revlog
+
     def __len__(self):
         return len(self._revlog)