Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d98f150

Browse files
committed
fix flags in _PyCompile_CodeGen
1 parent ce45de8 commit d98f150

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Python/compile.c

+4
Original file line numberDiff line numberDiff line change
@@ -9996,6 +9996,10 @@ _PyCompile_CodeGen(PyObject *ast, PyObject *filename, PyCompilerFlags *flags,
99969996
return NULL;
99979997
}
99989998

9999+
PyCompilerFlags local_flags = _PyCompilerFlags_INIT;
10000+
if (!flags) {
10001+
flags = &local_flags;
10002+
}
999910003
if (!compiler_setup(&c, mod, filename, flags, optimize, arena)) {
1000010004
goto finally;
1000110005
}

0 commit comments

Comments
 (0)