summaryrefslogtreecommitdiffstats
path: root/Python/ast_opt.c
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@python.org>2021-04-07 11:01:09 (GMT)
committerGitHub <noreply@github.com>2021-04-07 11:01:09 (GMT)
commitd36d6a9c1808e87628ebaa855d4bec80130189f4 (patch)
tree2b4633ff2e80878f75abad58d8a768a14160b1fc /Python/ast_opt.c
parent67969f5eb80844b68005181fd887bcf94c01fb40 (diff)
downloadcpython-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 'Python/ast_opt.c')
-rw-r--r--Python/ast_opt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Python/ast_opt.c b/Python/ast_opt.c
index 0310466..46dba76 100644
--- a/Python/ast_opt.c
+++ b/Python/ast_opt.c
@@ -451,8 +451,8 @@ astfold_body(asdl_stmt_seq *stmts, PyArena *ctx_, _PyASTOptimizeState *state)
return 0;
}
asdl_seq_SET(values, 0, st->v.Expr.value);
- expr_ty expr = JoinedStr(values, st->lineno, st->col_offset,
- st->end_lineno, st->end_col_offset, ctx_);
+ expr_ty expr = _Py_JoinedStr(values, st->lineno, st->col_offset,
+ st->end_lineno, st->end_col_offset, ctx_);
if (!expr) {
return 0;
}