diff --git a/src/conversions/array.rs b/src/conversions/array.rs index 92fded84f14..77a7fde65e6 100644 --- a/src/conversions/array.rs +++ b/src/conversions/array.rs @@ -29,7 +29,7 @@ mod min_const_generics { } } - #[cfg(feature = "nightly")] + #[cfg(all(feature = "nightly", not(Py_LIMITED_API)))] impl<'source, T, const N: usize> FromPyObject<'source> for [T; N] where for<'a> T: Default + FromPyObject<'a> + crate::buffer::Element, diff --git a/src/types/sequence.rs b/src/types/sequence.rs index 1a1e1500b15..987743e633b 100644 --- a/src/types/sequence.rs +++ b/src/types/sequence.rs @@ -279,7 +279,7 @@ where } } -#[cfg(feature = "nightly")] +#[cfg(all(feature = "nightly", not(Py_LIMITED_API)))] impl<'source, T> FromPyObject<'source> for Vec where for<'a> T: FromPyObject<'a> + crate::buffer::Element,