cpython
cpython copied to clipboard
gh-113993: Don't immortalize in PyUnicode_InternInPlace; keep immortalizing in other API
- Switch PyUnicode_InternInPlace to _PyUnicode_InternMortal
- Keep immortalizing in functions that take
char*, and are almost exclusively used with strings known at compile-time:- PyUnicode_InternFromString
- PyDict_SetItemString
- PyObject_SetAttrString
- PyObject_DelAttrString
- PyUnicode_InternFromString
- PyModule_Add* convenience functions.
- Clarify docs
- Don't immortalize
PyCSimpleTypedescriptor names, which aren't known at compile time
- Issue: gh-113993
📚 Documentation preview 📚: https://cpython-previews--121364.org.readthedocs.build/