summaryrefslogtreecommitdiffstats
path: root/Python/symtable.c
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2007-01-10 18:51:35 (GMT)
committerGuido van Rossum <guido@python.org>2007-01-10 18:51:35 (GMT)
commit16be03e4a206c24b00dc1d2d3c740dffbbfc4ac9 (patch)
tree459a125a265abb16399baeea398ab116b7bf4f9b /Python/symtable.c
parentb940e113bf90ff71b0ef57414ea2beea9d2a4bc0 (diff)
downloadcpython-16be03e4a206c24b00dc1d2d3c740dffbbfc4ac9.zip
cpython-16be03e4a206c24b00dc1d2d3c740dffbbfc4ac9.tar.gz
cpython-16be03e4a206c24b00dc1d2d3c740dffbbfc4ac9.tar.bz2
Some more changes related to the new except syntax and semantics,
by Collin Winter.
Diffstat (limited to 'Python/symtable.c')
-rw-r--r--Python/symtable.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Python/symtable.c b/Python/symtable.c
index 708e18c..d275cb9 100644
--- a/Python/symtable.c
+++ b/Python/symtable.c
@@ -1335,7 +1335,8 @@ symtable_visit_excepthandler(struct symtable *st, excepthandler_ty eh)
if (eh->type)
VISIT(st, expr, eh->type);
if (eh->name)
- VISIT(st, expr, eh->name);
+ if (!symtable_add_def(st, eh->name, DEF_LOCAL))
+ return 0;
VISIT_SEQ(st, stmt, eh->body);
return 1;
}