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 <rep...@bugs.python.org> <http://bugs.python.org/issue29878> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com