Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 357f515 commit 98e818bCopy full SHA for 98e818b
1 file changed
Python/compile.c
@@ -1772,6 +1772,10 @@ compiler_class(struct compiler *c, stmt_ty s)
1772
}
1773
i = compiler_lookup_arg(c->u->u_cellvars, str);
1774
Py_DECREF(str);
1775
+ if (i < 0) {
1776
+ compiler_exit_scope(c);
1777
+ return 0;
1778
+ }
1779
assert(i == 0);
1780
/* Return the cell where to store __class__ */
1781
ADDOP_I(c, LOAD_CLOSURE, i);
0 commit comments