# HG changeset patch # User Raphaël Gomès # Date 2023-08-02 14:49:17 # Node ID 274abd1562a265d2f58341d3e622cac764613800 # Parent b67cd0d0e97627a6993c9969dfd0563fbb68c9fc rust-index: use the rust index in `shortest` diff --git a/rust/hg-cpython/src/revlog.rs b/rust/hg-cpython/src/revlog.rs --- a/rust/hg-cpython/src/revlog.rs +++ b/rust/hg-cpython/src/revlog.rs @@ -105,7 +105,7 @@ py_class!(pub class MixedIndex |py| { def shortest(&self, node: PyBytes) -> PyResult { let opt = self.get_nodetree(py)?.borrow(); let nt = opt.as_ref().unwrap(); - let idx = &*self.cindex(py).borrow(); + let idx = &*self.index(py).borrow(); match nt.unique_prefix_len_node(idx, &node_from_py_bytes(py, &node)?) { Ok(Some(l)) => Ok(l),