]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-117486: Improve behavior for user-defined AST subclasses (#118212)
authorJelle Zijlstra <jelle.zijlstra@gmail.com>
Mon, 6 May 2024 22:57:27 +0000 (15:57 -0700)
committerGitHub <noreply@github.com>
Mon, 6 May 2024 22:57:27 +0000 (15:57 -0700)
commite0422198fb4de0a5d81edd3de0d0ed32c119e9bb
tree8fedfb2ee456f4a96ddb673fbea256085c631e74
parent040571f258d13a807f5c8e4ce0a182d5f9a2e81b
gh-117486: Improve behavior for user-defined AST subclasses (#118212)

Now, such classes will no longer require changes in Python 3.13 in the normal case.
The test suite for robotframework passes with no DeprecationWarnings under this PR.

I also added a new DeprecationWarning for the case where `_field_types` exists
but is incomplete, since that seems likely to indicate a user mistake.
Doc/library/ast.rst
Doc/whatsnew/3.13.rst
Lib/test/test_ast.py
Misc/NEWS.d/next/Library/2024-04-23-21-17-00.gh-issue-117486.ea3KYD.rst [new file with mode: 0644]
Parser/asdl_c.py
Python/Python-ast.c