summaryrefslogtreecommitdiff
path: root/Python/compile.c
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2013-05-16 22:17:17 +0200
committerVictor Stinner <victor.stinner@gmail.com>2013-05-16 22:17:17 +0200
commit3be142c560917a899230a0695dccb1052bda0f3a (patch)
tree0fec0d1ef22c783570d55ec8b207250a178c7215 /Python/compile.c
parentdf197a8dcb7f4aba4ba0e6b28f910cb28088549e (diff)
downloadcpython-3be142c560917a899230a0695dccb1052bda0f3a.tar.gz
fix compilation on Windows
Diffstat (limited to 'Python/compile.c')
-rw-r--r--Python/compile.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Python/compile.c b/Python/compile.c
index 65043e4396..4fc7575926 100644
--- a/Python/compile.c
+++ b/Python/compile.c
@@ -1360,10 +1360,11 @@ compiler_mod(struct compiler *c, mod_ty mod)
static int
get_ref_type(struct compiler *c, PyObject *name)
{
+ int scope;
if (c->u->u_scope_type == COMPILER_SCOPE_CLASS &&
!PyUnicode_CompareWithASCIIString(name, "__class__"))
return CELL;
- int scope = PyST_GetScope(c->u->u_ste, name);
+ scope = PyST_GetScope(c->u->u_ste, name);
if (scope == 0) {
char buf[350];
PyOS_snprintf(buf, sizeof(buf),