]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-125268: Use static string for "1e309" in AST (#125272)
authorSam Gross <colesbury@gmail.com>
Thu, 10 Oct 2024 20:21:29 +0000 (16:21 -0400)
committerGitHub <noreply@github.com>
Thu, 10 Oct 2024 20:21:29 +0000 (16:21 -0400)
commit427dcf24de4e06d239745d74d08c4b2e541dca5a
tree37a7ca3937862498b957402323c1a29195ce11eb
parentbb594e801b6a84823badbb85b88f0fc8b221d7bf
gh-125268: Use static string for "1e309" in AST (#125272)

When formatting the AST as a string, infinite values are replaced by
1e309, which evaluates to infinity. The initialization of this string
replacement was not thread-safe in the free threading build.
Include/internal/pycore_global_objects.h
Include/internal/pycore_global_objects_fini_generated.h
Include/internal/pycore_global_strings.h
Include/internal/pycore_runtime_init_generated.h
Include/internal/pycore_unicodeobject_generated.h
Parser/asdl_c.py
Python/Python-ast.c
Python/ast_unparse.c