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 jdemeyer
Recipients jdemeyer, vstinner
Date 2019-07-21.17:46:14
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1563731175.2.0.136240000148.issue37645@roundup.psfhosted.org>
In-reply-to
Content
PyEval_GetFuncName is bad API because

1. It hardcodes a limited number of function classes (which doesn't even include all function classes in the core interpreter) instead of supporting duck-typing.
2. In case of a "function" object, it relies on a borrowed reference to the function.
3. It is returning a C string instead of a Python string, so we cannot return a new reference even if we wanted to.

Since PyEval_GetFuncName and PyEval_GetFuncDesc are always used together, we might as well replace them by a single function with a proper API.
History
Date User Action Args
2019-07-21 17:46:15jdemeyersetrecipients: + jdemeyer, vstinner
2019-07-21 17:46:15jdemeyersetmessageid: <1563731175.2.0.136240000148.issue37645@roundup.psfhosted.org>
2019-07-21 17:46:15jdemeyerlinkissue37645 messages
2019-07-21 17:46:14jdemeyercreate