diff --git a/reconcile-python/src/lib.rs b/reconcile-python/src/lib.rs index 809e0b0..a50366a 100644 --- a/reconcile-python/src/lib.rs +++ b/reconcile-python/src/lib.rs @@ -21,7 +21,7 @@ fn extract_text_with_cursors(input: &Bound<'_, PyAny>) -> PyResult()?; + let dict = input.cast::()?; let text: String = dict .get_item("text")? @@ -30,10 +30,10 @@ fn extract_text_with_cursors(input: &Bound<'_, PyAny>) -> PyResult { - let list = obj.downcast::()?; + let list = obj.cast::()?; let mut cursors = Vec::with_capacity(list.len()); for item in list { - let cursor_dict = item.downcast::()?; + let cursor_dict = item.cast::()?; let id: usize = cursor_dict .get_item("id")? .ok_or_else(|| pyo3::exceptions::PyKeyError::new_err("id"))?