[issue29878] Add global instances of int 0 and 1
STINNER Victor
report at bugs.python.org
Wed Mar 22 12:49:09 EDT 2017
STINNER Victor added the comment:
Other common values used in C functions: empty byte string, empty Unicode string, empty tuple. The problem is to make sure that singletons are created in the right order :-/
This issue reminded me an old idea of writing a generalization of the _Py_IDENTIFIER() API. I created an issue #29881: Add a new private API for "static C variables" (_PyStaticVar) to clear them at exit. To be clear: it's related but different to this issue, the two issues are exclusive.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue29878>
_______________________________________
More information about the Python-bugs-list
mailing list