pyo3
pyo3 copied to clipboard
Extend `impl FromPyObject<'a> for Cow<'a, [u8]>` to handle buffer protocol
In #2899, we temporarily introduced support for handling any Python object implementing the buffer protocol via impl FromPyObject<'a> for Cow<'a, [u8]> in 228cfd009c0fd35b7b3c199e67d56d3ff404ba8e.
We decided to remove this as it would only be available in CPython 3.11 or later or when the full API is enabled. When we drop support for CPython 3.10 or earlier, we should look into re-enabling this unconditionally.