From 0f4ec816d730f029d82469c980a8bef8297d0e9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Maillet?= Date: Sat, 3 Aug 2024 20:23:36 -0400 Subject: [PATCH] Updated to use PyO3's bound API --- src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 0d3a2b9..7f3c246 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -14,7 +14,7 @@ use std::collections::{HashSet, VecDeque}; #[pyfunction] fn polygon_to_geohashes( _py: Python, - py_polygon: &PyAny, + py_polygon: Bound<'_, PyAny>, precision: usize, inner: bool, ) -> PyResult> { @@ -98,7 +98,7 @@ fn polygon_to_geohashes( } #[pymodule] -fn geohash_polygon(_py: Python, m: &PyModule) -> PyResult<()> { +fn geohash_polygon(m: &Bound<'_, PyModule>) -> PyResult<()> { m.add_function(wrap_pyfunction!(polygon_to_geohashes, m)?)?; Ok(()) }