Skip to content

Conversation

@brandtbucher
Copy link
Member

@brandtbucher brandtbucher commented Oct 10, 2023

This modifies _PyFunction_LookupByVersion to return a borrowed reference, which is what the caller assumes (and most internal "lookup" functions do, in general).

@brandtbucher brandtbucher added type-bug An unexpected behavior, bug, or error interpreter-core (Objects, Python, Grammar, and Parser dirs) labels Oct 10, 2023
@brandtbucher brandtbucher self-assigned this Oct 10, 2023
@brandtbucher brandtbucher changed the title GH-104854: Fix refleak when tracing through calls GH-104584: Fix refleak when tracing through calls Oct 10, 2023
Copy link
Member

@gvanrossum gvanrossum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(I love how this already violates a likely future C API requirement. Glad that those requirements don't apply to internal APIs. :-)

@brandtbucher brandtbucher enabled auto-merge (squash) October 10, 2023 08:15
@brandtbucher brandtbucher merged commit 13380da into python:main Oct 10, 2023
@gvanrossum gvanrossum deleted the uops-refleak branch October 10, 2023 09:57
Glyphack pushed a commit to Glyphack/cpython that referenced this pull request Sep 2, 2024
@brandtbucher brandtbucher restored the uops-refleak branch August 20, 2025 20:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

interpreter-core (Objects, Python, Grammar, and Parser dirs) type-bug An unexpected behavior, bug, or error

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants