Skip to content

gh-111926: Simplify weakref creation logic #116843

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 15, 2024

Conversation

mpage
Copy link
Contributor

@mpage mpage commented Mar 14, 2024

Since 3.12 allocating a GC object cannot immediately trigger GC. This allows us to simplify the logic for creating the canonical callback-less weakref.

Since 3.12 allocating a GC object cannot immediately trigger GC. This
allows us to simplify the logic for creating the canonical callback-less
weakref.
@mpage
Copy link
Contributor Author

mpage commented Mar 15, 2024

The CIFuzz (memory) failure is unrelated to this PR. It's failing in the same way on other PRs and likely main.

@mpage mpage requested a review from colesbury March 15, 2024 01:36
@mpage mpage marked this pull request as ready for review March 15, 2024 01:37
@colesbury colesbury merged commit 001b21d into python:main Mar 15, 2024
vstinner pushed a commit to vstinner/cpython that referenced this pull request Mar 20, 2024
Since 3.12, allocating a GC object cannot immediately trigger GC. This
allows us to simplify the logic for creating the canonical callback-less
weakref.
adorilson pushed a commit to adorilson/cpython that referenced this pull request Mar 25, 2024
Since 3.12, allocating a GC object cannot immediately trigger GC. This
allows us to simplify the logic for creating the canonical callback-less
weakref.
diegorusso pushed a commit to diegorusso/cpython that referenced this pull request Apr 17, 2024
Since 3.12, allocating a GC object cannot immediately trigger GC. This
allows us to simplify the logic for creating the canonical callback-less
weakref.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants