head-revs: remove the `headrevsfiltered` method on the index
authorPierre-Yves David <pierre-yves.david@octobus.net>
Thu, 26 Sep 2024 00:50:21 +0200
changeset 51998 8060257fd918
parent 51997 6204fc81a291
child 51999 22da1dc97281
head-revs: remove the `headrevsfiltered` method on the index This method is no longer called and can be removed.
mercurial/cext/parsers.pyi
mercurial/cext/revlog.c
rust/hg-cpython/src/revlog.rs
--- a/mercurial/cext/parsers.pyi	Wed Sep 25 17:11:32 2024 +0200
+++ b/mercurial/cext/parsers.pyi	Thu Sep 26 00:50:21 2024 +0200
@@ -76,7 +76,6 @@
     def computephasesmapsets(self, root: Dict[int, Set[int]]) -> Tuple[int, Dict[int, Set[bytes]]]: ...
     def reachableroots2(self, minroot: int, heads: List[int], roots: List[int], includepath: bool) -> List[int]: ...
     def headrevs(self, filteredrevs: Optional[List[int]]) -> List[int]: ...
-    def headrevsfiltered(self, filteredrevs: Optional[List[int]]) -> List[int]: ...
     def issnapshot(self, value: int) -> bool: ...
     def findsnapshots(self, cache: Dict[int, List[int]], start_rev: int) -> None: ...
     def deltachain(self, rev: int, stop: int, generaldelta: bool) -> Tuple[List[int], bool]: ...
--- a/mercurial/cext/revlog.c	Wed Sep 25 17:11:32 2024 +0200
+++ b/mercurial/cext/revlog.c	Thu Sep 26 00:50:21 2024 +0200
@@ -3352,9 +3352,7 @@
     {"replace_sidedata_info", (PyCFunction)index_replace_sidedata_info,
      METH_VARARGS, "replace an existing index entry with a new value"},
     {"headrevs", (PyCFunction)index_headrevs, METH_VARARGS,
-     "get head revisions"}, /* Can do filtering since 3.2 */
-    {"headrevsfiltered", (PyCFunction)index_headrevs, METH_VARARGS,
-     "get filtered head revisions"}, /* Can always do filtering */
+     "get head revisions"},
     {"issnapshot", (PyCFunction)index_issnapshot, METH_O,
      "True if the object is a snapshot"},
     {"findsnapshots", (PyCFunction)index_findsnapshots, METH_VARARGS,
--- a/rust/hg-cpython/src/revlog.rs	Wed Sep 25 17:11:32 2024 +0200
+++ b/rust/hg-cpython/src/revlog.rs	Thu Sep 26 00:50:21 2024 +0200
@@ -333,12 +333,6 @@
         Ok(rust_res)
     }
 
-    /// get filtered head revisions
-    def headrevsfiltered(&self, *args, **_kw) -> PyResult<PyObject> {
-        let rust_res = self.inner_headrevsfiltered(py, &args.get_item(py, 0))?;
-        Ok(rust_res)
-    }
-
     /// True if the object is a snapshot
     def issnapshot(&self, *args, **_kw) -> PyResult<bool> {
         let index = self.index(py).borrow();