diff options
author | Victor Stinner <vstinner@python.org> | 2021-04-07 11:01:09 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-07 11:01:09 (GMT) |
commit | d36d6a9c1808e87628ebaa855d4bec80130189f4 (patch) | |
tree | 2b4633ff2e80878f75abad58d8a768a14160b1fc /Include/internal/pycore_ast.h | |
parent | 67969f5eb80844b68005181fd887bcf94c01fb40 (diff) | |
download | cpython-d36d6a9c1808e87628ebaa855d4bec80130189f4.zip cpython-d36d6a9c1808e87628ebaa855d4bec80130189f4.tar.gz cpython-d36d6a9c1808e87628ebaa855d4bec80130189f4.tar.bz2 |
bpo-43244: Remove Yield macro from pycore_ast.h (GH-25243)
* pycore_ast.h no longer defines the Yield macro.
* Fix a compiler warning on Windows: "warning C4005: 'Yield': macro
redefinition".
* Python-ast.c now defines directly functions with their real
_Py_xxx() name, rather than xxx().
* Remove "#undef Yield" in C files including pycore_ast.h.
Diffstat (limited to 'Include/internal/pycore_ast.h')
-rw-r--r-- | Include/internal/pycore_ast.h | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/Include/internal/pycore_ast.h b/Include/internal/pycore_ast.h index ac1e387..5099cf6 100644 --- a/Include/internal/pycore_ast.h +++ b/Include/internal/pycore_ast.h @@ -12,8 +12,6 @@ extern "C" { #include "pycore_asdl.h" -#undef Yield /* undefine macro conflicting with <winbase.h> */ - typedef struct _mod *mod_ty; typedef struct _stmt *stmt_ty; @@ -729,7 +727,6 @@ expr_ty _Py_GeneratorExp(expr_ty elt, asdl_comprehension_seq * generators, int #define Await(a0, a1, a2, a3, a4, a5) _Py_Await(a0, a1, a2, a3, a4, a5) expr_ty _Py_Await(expr_ty value, int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena *arena); -#define Yield(a0, a1, a2, a3, a4, a5) _Py_Yield(a0, a1, a2, a3, a4, a5) expr_ty _Py_Yield(expr_ty value, int lineno, int col_offset, int end_lineno, int end_col_offset, PyArena *arena); #define YieldFrom(a0, a1, a2, a3, a4, a5) _Py_YieldFrom(a0, a1, a2, a3, a4, a5) |