diff --git a/src/types/list.rs b/src/types/list.rs index 2d65dd4280f..155f5e57be8 100644 --- a/src/types/list.rs +++ b/src/types/list.rs @@ -647,7 +647,7 @@ impl<'py> BoundListIterator<'py> { } } - #[cfg(not(Py_LIMITED_API))] + #[allow(dead_code)] fn with_critical_section( &mut self, f: impl FnOnce(&mut Index, &mut Length, &Bound<'py, PyList>) -> R,