summaryrefslogtreecommitdiff
path: root/Modules
diff options
context:
space:
mode:
Diffstat (limited to 'Modules')
-rw-r--r--Modules/main.c2
-rw-r--r--Modules/parsermodule.c3
-rw-r--r--Modules/symtablemodule.c3
3 files changed, 3 insertions, 5 deletions
diff --git a/Modules/main.c b/Modules/main.c
index 6b9406f786..853afedd7b 100644
--- a/Modules/main.c
+++ b/Modules/main.c
@@ -524,7 +524,7 @@ pymain_run_python(int *exitcode)
}
}
- PyCompilerFlags cf = {.cf_flags = 0, .cf_feature_version = PY_MINOR_VERSION};
+ PyCompilerFlags cf = _PyCompilerFlags_INIT;
pymain_header(config);
pymain_import_readline(config);
diff --git a/Modules/parsermodule.c b/Modules/parsermodule.c
index 36f9214191..079d00f32a 100644
--- a/Modules/parsermodule.c
+++ b/Modules/parsermodule.c
@@ -336,8 +336,7 @@ parser_newstobject(node *st, int type)
if (o != 0) {
o->st_node = st;
o->st_type = type;
- o->st_flags.cf_flags = 0;
- o->st_flags.cf_feature_version = PY_MINOR_VERSION;
+ o->st_flags = _PyCompilerFlags_INIT;
}
else {
PyNode_Free(st);
diff --git a/Modules/symtablemodule.c b/Modules/symtablemodule.c
index d66cb44f69..9180f185e1 100644
--- a/Modules/symtablemodule.c
+++ b/Modules/symtablemodule.c
@@ -30,11 +30,10 @@ _symtable_symtable_impl(PyObject *module, PyObject *source,
struct symtable *st;
PyObject *t;
int start;
- PyCompilerFlags cf;
+ PyCompilerFlags cf = _PyCompilerFlags_INIT;
PyObject *source_copy = NULL;
cf.cf_flags = PyCF_SOURCE_IS_UTF8;
- cf.cf_feature_version = PY_MINOR_VERSION;
const char *str = _Py_SourceAsString(source, "symtable", "string or bytes", &cf, &source_copy);
if (str == NULL) {