mirror of
https://github.com/python/cpython.git
synced 2026-05-18 10:24:42 -04:00
change Py3k backquote warning to a SyntaxWarning and add a test
This commit is contained in:
+1
-1
@@ -1364,7 +1364,7 @@ ast_for_atom(struct compiling *c, const node *n)
|
||||
case BACKQUOTE: { /* repr */
|
||||
expr_ty expression;
|
||||
if (Py_Py3kWarningFlag) {
|
||||
if (PyErr_WarnExplicit(PyExc_DeprecationWarning,
|
||||
if (PyErr_WarnExplicit(PyExc_SyntaxWarning,
|
||||
"backquote not supported in 3.x; use repr()",
|
||||
c->c_filename, LINENO(n),
|
||||
NULL, NULL)) {
|
||||
|
||||
Reference in New Issue
Block a user