rust/hg-cpython/src/dirstate/dirstate_map.rs
changeset 47332 4ee9f419c52e
parent 47280 1766130fe9ba
child 47335 ed1583a845d2
--- a/rust/hg-cpython/src/dirstate/dirstate_map.rs	Wed May 19 13:15:00 2021 +0200
+++ b/rust/hg-cpython/src/dirstate/dirstate_map.rs	Wed May 19 13:15:00 2021 +0200
@@ -92,7 +92,7 @@
         let key = key.extract::<PyBytes>(py)?;
         match self.inner(py).borrow().get(HgPath::new(key.data(py))) {
             Some(entry) => {
-                Ok(Some(make_dirstate_tuple(py, entry)?))
+                Ok(Some(make_dirstate_tuple(py, &entry)?))
             },
             None => Ok(default)
         }
@@ -348,7 +348,7 @@
         let key = HgPath::new(key.data(py));
         match self.inner(py).borrow().get(key) {
             Some(entry) => {
-                Ok(make_dirstate_tuple(py, entry)?)
+                Ok(make_dirstate_tuple(py, &entry)?)
             },
             None => Err(PyErr::new::<exc::KeyError, _>(
                 py,
@@ -525,13 +525,13 @@
     }
     fn translate_key(
         py: Python,
-        res: (&HgPath, &DirstateEntry),
+        res: (&HgPath, DirstateEntry),
     ) -> PyResult<Option<PyBytes>> {
         Ok(Some(PyBytes::new(py, res.0.as_bytes())))
     }
     fn translate_key_value(
         py: Python,
-        res: (&HgPath, &DirstateEntry),
+        res: (&HgPath, DirstateEntry),
     ) -> PyResult<Option<(PyBytes, PyObject)>> {
         let (f, entry) = res;
         Ok(Some((