Some of the functions we have are really intended to be used *only* by the interpreter itself. For those it would be cool to have them in private headers (AFAIK we already do this, see dict-common.h for instance). Other than that, I think that using the underscore convention is fine. Yury On 2016-09-11 4:37 AM, Victor Stinner wrote: > Hi, > > Currently, Python has 3 C API: > > * python core API > * regular API: subset of the core API > * stable API (ABI?), the Py_LIMITED_API thing: subset of the regular API > > For practical purpose, all functions are declared in Include/*.h. > Basically, Python exposes "everything". There are private functions > which are exported using PyAPI_FUNC(), whereas they should only be > used inside Python "core". Technically, I'm not sure that we can get > ride of PyAPI_FUNC() because the stdlib also has extensions which use > a few private functions. > > For Python 3.7, I propose that we move all these private functions in > separated header files, maybe Include/private/ or Include/core/, and > not export them as part of the "regular API". > > The risk is that too many C extensions rely on all these tiny > "private" functions. Maybe for performance. I don't know. > > What do you think? > > See also the issue #26900, "Exclude the private API from the stable API": > http://bugs.python.org/issue26900 > > Victor > _______________________________________________ > Python-Dev mailing list > Python-Dev at python.org > https://mail.python.org/mailman/listinfo/python-dev > Unsubscribe: https://mail.python.org/mailman/options/python-dev/yselivanov.ml%40gmail.com
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4