Skip to content

[3.12] gh-113993: For string interning, do not rely on (or assert) _Py_IsImmortal (GH-121358) (GH-121851) - #124938

Merged
encukou merged 1 commit into
python:3.12from
encukou:3.12-static-immortal-skip-assert
Oct 4, 2024
Merged

encukou merged 1 commit into
python:3.12from
encukou:3.12-static-immortal-skip-assert

Conversation

@encukou

@encukou encukou commented Oct 3, 2024 •

Copy link
Copy Markdown
Member

Older stable ABI extensions are allowed to make immortal objects mortal. Instead, use _PyUnicode_STATE (interned and statically_allocated).

(cherry picked from commit 956270d)

Fixes: gh-124887

…rt) _Py_IsImmortal (pythonGH-121358) (pythonGH-121851)

pythongh-113993: For string interning, do not rely on (or assert) _Py_IsImmortal (pythonGH-121358)

Older stable ABI extensions are allowed to make immortal objects mortal.
Instead, use `_PyUnicode_STATE` (`interned` and `statically_allocated`).
(cherry picked from commit 956270d)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
@encukou

encukou commented Oct 3, 2024

Copy link
Copy Markdown
Member Author

I missed this in the big backport. My apologies :(

@encukou encukou added the 🔨 test-with-buildbots Test PR w/ buildbots; report in status section label Oct 3, 2024
@bedevere-bot

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @encukou for commit 3e07c20 🤖

If you want to schedule another build, you need to add the 🔨 test-with-buildbots label again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants