[issue35438] Cleanup extension functions using _PyObject_LookupSpecial

2018-12-10 Thread Josh Rosenberg
Josh Rosenberg added the comment: Agreed with everything in Serhiy's comments. This patch disregards why _PyObject_LookupSpecial and the various _Py_IDENTIFIER related stuff was created in the first place (to handle a non-trivial task efficiently/correctly) in favor of trying to avoid

[issue35438] Cleanup extension functions using _PyObject_LookupSpecial

2018-12-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: There is nothing wrong with using private C API in the implementation of standard CPython extensions. This API was designed for this. In contrary, there are problems with your code: * It is less efficient. String objects are created and destroyed twice

[issue35438] Cleanup extension functions using _PyObject_LookupSpecial

2018-12-10 Thread Eddie Elizondo
Eddie Elizondo added the comment: I also fixed the title to properly reflect what this is trying to achieve. -- ___ Python tracker ___

[issue35438] Cleanup extension functions using _PyObject_LookupSpecial

2018-12-10 Thread Eddie Elizondo
Change by Eddie Elizondo : -- title: Extension modules using non-API functions -> Cleanup extension functions using _PyObject_LookupSpecial ___ Python tracker ___