delta-find: feed revinfo to _DeltaSearch
The revinfo has more information and will allow for even more function to be
turned into method.
--- a/mercurial/revlogutils/deltas.py Thu Nov 23 03:23:11 2023 +0100
+++ b/mercurial/revlogutils/deltas.py Fri Dec 22 01:33:33 2023 +0100
@@ -685,7 +685,7 @@
def __init__(
self,
revlog,
- textlen,
+ revinfo,
p1,
p2,
cachedelta,
@@ -702,7 +702,8 @@
or not revlog.delta_config.general_delta
)
self.revlog = revlog
- self.textlen = textlen
+ self.revinfo = revinfo
+ self.textlen = revinfo.textlen
self.p1 = p1
self.p2 = p2
self.cachedelta = cachedelta
@@ -1432,7 +1433,7 @@
search = _DeltaSearch(
self.revlog,
- revinfo.textlen,
+ revinfo,
p1r,
p2r,
cachedelta,