
One solution would be to:
introduce Py_GetSizeInline(), Py_GetTypeInline() static inline functions (of course, feel free to prefer other names :-))
deprecate Py_SIZE() and Py_TYPE() with a message guiding towards Py_GetSizeInline() and Py_GetTypeInline() respectively. To be clear, this is a compile-time deprecation message using pragmas or other compiler-specific means (see e.g. https://stackoverflow.com/questions/2681259/how-to-deprecate-a-c-pre-process...).
in a couple versions, retire the current definitions of Py_SIZE and Py_TYPE and replace them with:
#define Py_SIZE Py_GetSizeInline #define Py_TYPE Py_GetTypeInline
Regards
Antoine.
Le 13/09/2021 à 16:52, Antonio Cuni a écrit :
On Mon, Sep 13, 2021 at 11:37 AM Petr Viktorin <encukou@gmail.com> wrote:
Sure, let's evolve and improve CPython. But can we make it in steps that are individually helpful?
I think that's the core of the divergences of opinions. I think we have reached a point where the amount of improvements which can be done by "small steps which are individually useful" is little. I might be wrong of course.
capi-sig mailing list -- capi-sig@python.org To unsubscribe send an email to capi-sig-leave@python.org https://mail.python.org/mailman3/lists/capi-sig.python.org/ Member address: antoine@python.org