[Python-Dev] Experiment an opt-in new C API for Python? (leave current API unchanged)

Victor Stinner vstinner at redhat.com
Wed Nov 14 05:48:15 EST 2018


Le mer. 14 nov. 2018 à 11:24, Antoine Pitrou <solipsis at pitrou.net> a écrit :
> For example in PyArrow we use PySequence_Fast_GET_ITEM() (*)

Maybe PyArrow is a kind of C extension which should have one
implementation for the new C API (PyPy) and one implementation for the
current C API (CPython)?

Cython can be used to generate two different C code from the same
source code using a different compilation mode.

> and even
> PyType_HasFeature() (**) (to quickly check for multiple base types with
> a single fetch and comparison).

I'm not sure that PyType_HasFeature() is an issue?

Victor


More information about the Python-Dev mailing list