On Sun, 19 Nov 2017 00:18:28 +0100 Victor Stinner <victor.stin...@gmail.com> wrote: > Le 18 nov. 2017 10:44, "Serhiy Storchaka" <storch...@gmail.com> a écrit : > > The simplest way to do this: > > #define PyTuple_GET_ITEM PyTuple_GetItem > > This will not add new names to ABI. Such defines can be added in a separate > header file included for compatibility. > > > It is exactly what I am proposing :-)
But those do not have the same semantics. PyTuple_GetItem() checks its arguments and raises an error if you pass it something else than a tuple, or if the index is out of bounds. PyTuple_GET_ITEM(), however, will crash if you do so. Regards Antoine. _______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com