bpo-43892: Make match patterns explicit in the AST (GH-25585)
Co-authored-by: Brandt Bucher <brandtbucher@gmail.com>
This commit is contained in:
@@ -831,11 +831,7 @@ builtin_compile_impl(PyObject *module, PyObject *source, PyObject *filename,
|
||||
if (arena == NULL)
|
||||
goto error;
|
||||
mod = PyAST_obj2mod(source, arena, compile_mode);
|
||||
if (mod == NULL) {
|
||||
_PyArena_Free(arena);
|
||||
goto error;
|
||||
}
|
||||
if (!_PyAST_Validate(mod)) {
|
||||
if (mod == NULL || !_PyAST_Validate(mod)) {
|
||||
_PyArena_Free(arena);
|
||||
goto error;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user