This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients Mark.Shannon, ronaldoussoren, serhiy.storchaka, shihai1991, vstinner
Date 2020-11-09.22:22:45
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1604960565.22.0.414413175441.issue42294@roundup.psfhosted.org>
In-reply-to
Content
I concur with Mark.

If you want to work only with non-borrowed references, use PySequence_GetItem() and PySequence_SetItem(). It has a cost: it is slower and needs checking errors. If you need more performant solution and binary compatibility across versions, use PyTuple_GetItem() and PyTuple_SetItem() (borrowed references is the part of optimization). If you don't need binary compatibility, but need speed, use macros.

And no need to expand the C API. It is already large enough.
History
Date User Action Args
2020-11-09 22:22:45serhiy.storchakasetrecipients: + serhiy.storchaka, ronaldoussoren, vstinner, Mark.Shannon, shihai1991
2020-11-09 22:22:45serhiy.storchakasetmessageid: <1604960565.22.0.414413175441.issue42294@roundup.psfhosted.org>
2020-11-09 22:22:45serhiy.storchakalinkissue42294 messages
2020-11-09 22:22:45serhiy.storchakacreate