]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
And yet another fix for the patch. Paul Moore has send me a note that I've missed...
authorChristian Heimes <christian@cheimes.de>
Fri, 23 Nov 2007 13:25:31 +0000 (13:25 +0000)
committerChristian Heimes <christian@cheimes.de>
Fri, 23 Nov 2007 13:25:31 +0000 (13:25 +0000)
Python/ast.c

index a9bc2d47a5aa10ea8c956fa32dcb2e52e733c0d0..b97da1d4427c921421d2cfe0adf7dfc3fb217205 100644 (file)
@@ -1336,15 +1336,16 @@ ast_for_atom(struct compiling *c, const node *n)
         return Dict(keys, values, LINENO(n), n->n_col_offset, c->c_arena);
     }
     case BACKQUOTE: { /* repr */
+        expr_ty expression;
         if (Py_Py3kWarningFlag) {
-               if (PyErr_WarnExplicit(PyExc_DeprecationWarning,
-                                      "backquote not supported in 3.x",
-                                      "<unknown>", LINENO(n),
-                                      NULL, NULL)) {
-                       return NULL;
-               }
-       }
-        expr_ty expression = ast_for_testlist(c, CHILD(n, 1));
+            if (PyErr_WarnExplicit(PyExc_DeprecationWarning,
+                                   "backquote not supported in 3.x",
+                                   "<unknown>", LINENO(n),
+                                   NULL, NULL)) {
+            return NULL;
+            }
+        }
+        expression = ast_for_testlist(c, CHILD(n, 1));
         if (!expression)
             return NULL;