[Python-Dev] Inconsistency of PyModule_AddObject() (original) (raw)
Nick Coghlan ncoghlan at gmail.com
Wed Apr 27 09:10:55 EDT 2016
- Previous message (by thread): [Python-Dev] Inconsistency of PyModule_AddObject()
- Next message (by thread): [Python-Dev] Inconsistency of PyModule_AddObject()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 27 April 2016 at 23:08, Nick Coghlan <ncoghlan at gmail.com> wrote:
On 27 April 2016 at 17:14, Serhiy Storchaka <storchaka at gmail.com> wrote:
I think that we can resolve this issue by following steps:
1. Add a new function PyModuleAddObject2(), that steals a reference even on failure. I'd suggest a variant on this that more closely matches the PyListSetItem and PyTupleSetItem cases: PyModuleSetAttrString
And for the record: that suggestion was prompted by Hrvoje's email suggesting using a more descriptive name, I just went and looked up the name of the corresponding PyObject_* API.
Cheers, Nick.
-- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
- Previous message (by thread): [Python-Dev] Inconsistency of PyModule_AddObject()
- Next message (by thread): [Python-Dev] Inconsistency of PyModule_AddObject()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]