Skip to content

[3.14] gh-137814: Fix __qualname__ of __annotate__ functions in the interpreter#148221

Open
JelleZijlstra wants to merge 1 commit intopython:3.14from
JelleZijlstra:annotate-func-interp
Open

[3.14] gh-137814: Fix __qualname__ of __annotate__ functions in the interpreter#148221
JelleZijlstra wants to merge 1 commit intopython:3.14from
JelleZijlstra:annotate-func-interp

Conversation

@JelleZijlstra
Copy link
Copy Markdown
Member

@JelleZijlstra JelleZijlstra commented Apr 7, 2026

I'd still like to do #137842 on 3.15+, but that requires changing bytecode and we can't really afford to do that in 3.14. So to fix this in 3.14, let's patch things up in the ceval loop instead.

This is safe because the compiler only sets annotate to just-created dedicated annotate functions.

… the interpreter

I'd still like to do python#137842 on 3.15+, but that requires changing bytecode and we can't
really afford to do that in 3.14. So to fix this in 3.14, let's patch things up in the
ceval loop instead.

This is safe because the compiler only sets __annotate__ to just-created dedicated
annotate functions.
@JelleZijlstra JelleZijlstra changed the title gh-137814: [3.14] Fix __qualname__ of __annotate__ functions in the interpreter [3.14] gh-137814: Fix __qualname__ of __annotate__ functions in the interpreter Apr 7, 2026
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.

1 participant