[issue35438] Extension modules using non-API functions

2018-12-10 Thread Eddie Elizondo
Eddie Elizondo added the comment: @vstinner: Sorry for not being clear - The intention of this change is two-fold: 1) Simplify the implementation of these functions. 2) Reduce the surface area of the C-API. Given that the same functionality can be achieved with public functions of the C-API.

[issue35438] Extension modules using non-API functions

2018-12-10 Thread STINNER Victor
STINNER Victor added the comment: > Three extension modules: _testcapimodule.c, posixmodule.c, and mathmodule.c > are using `_PyObject_LookupSpecial` which is not API. I don't understand the issue that you are trying to solve. Yes, Python builtin extensions use private functions of the C

[issue35438] Extension modules using non-API functions

2018-12-10 Thread Eddie Elizondo
Change by Eddie Elizondo : -- keywords: +patch pull_requests: +10316 stage: -> patch review ___ Python tracker ___ ___

[issue35438] Extension modules using non-API functions

2018-12-07 Thread Josh Rosenberg
Josh Rosenberg added the comment: Batteries-included extension modules aren't limited to the public and/or limited API; they use tons of undocumented internal APIs (everything to do with Py_IDENTIFIERs being an obvious and frequently used non-public API). _PyObject_LookupSpecial is

[issue35438] Extension modules using non-API functions

2018-12-07 Thread Eddie Elizondo
Eddie Elizondo added the comment: Correction, this is not as trivial as just using `PyObject_GetAttrString`. Will investigate the correct behavior. -- ___ Python tracker ___

[issue35438] Extension modules using non-API functions

2018-12-07 Thread Eddie Elizondo
New submission from Eddie Elizondo : Three extension modules: _testcapimodule.c, posixmodule.c, and mathmodule.c are using `_PyObject_LookupSpecial` which is not API. These should instead use `PyObject_GetAttrString`, `PyType_GetSlot`. -- components: Library (Lib) messages: 331364