--- a/rust/hg-cpython/src/dirstate/dirstate_map.rs Fri Apr 30 14:22:14 2021 +0200
+++ b/rust/hg-cpython/src/dirstate/dirstate_map.rs Fri Apr 30 15:40:11 2021 +0200
@@ -13,8 +13,8 @@
use cpython::{
exc, ObjectProtocol, PyBool, PyBytes, PyClone, PyDict, PyErr, PyList,
- PyObject, PyResult, PySet, PyString, PyTuple, Python, PythonObject,
- ToPyObject, UnsafePyLeaked,
+ PyObject, PyResult, PySet, PyString, Python, PythonObject, ToPyObject,
+ UnsafePyLeaked,
};
use crate::{
@@ -271,27 +271,6 @@
.to_py_object(py))
}
- def parents(&self, st: PyObject) -> PyResult<PyTuple> {
- self.inner(py).borrow_mut()
- .parents(st.extract::<PyBytes>(py)?.data(py))
- .map(|parents| dirstate_parents_to_pytuple(py, parents))
- .or_else(|_| {
- Err(PyErr::new::<exc::OSError, _>(
- py,
- "Dirstate error".to_string(),
- ))
- })
- }
-
- def setparents(&self, p1: PyObject, p2: PyObject) -> PyResult<PyObject> {
- let p1 = extract_node_id(py, &p1)?;
- let p2 = extract_node_id(py, &p2)?;
-
- self.inner(py).borrow_mut()
- .set_parents(&DirstateParents { p1, p2 });
- Ok(py.None())
- }
-
def read(&self, st: PyObject) -> PyResult<Option<PyObject>> {
match self.inner(py).borrow_mut()
.read(st.extract::<PyBytes>(py)?.data(py))