summaryrefslogtreecommitdiffstats
path: root/Python/ceval.c
diff options
context:
space:
mode:
Diffstat (limited to 'Python/ceval.c')
-rw-r--r--Python/ceval.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/Python/ceval.c b/Python/ceval.c
index 0527537..7c358db 100644
--- a/Python/ceval.c
+++ b/Python/ceval.c
@@ -1337,6 +1337,13 @@ eval_code2(co, globals, locals,
continue;
case DELETE_FAST:
+ x = GETLOCAL(oparg);
+ if (x == NULL) {
+ PyErr_SetObject(PyExc_NameError,
+ PyTuple_GetItem(co->co_varnames,
+ oparg));
+ break;
+ }
SETLOCAL(oparg, NULL);
continue;