Mercurial > cpython-lru_cache-weakref
diff Python/pythonrun.c @ 74520:2bd7f40108b4
Issue #12705: Raise SyntaxError when compiling multiple statements as single interactive statement
| author | Meador Inge <meadori@gmail.com> |
|---|---|
| date | Thu, 19 Jan 2012 01:08:41 -0600 |
| parents | a321ffb21367 |
| children | ed76dc34b39d |
line wrap: on
line diff
--- a/Python/pythonrun.c Thu Jan 19 00:44:45 2012 -0600 +++ b/Python/pythonrun.c Thu Jan 19 01:08:41 2012 -0600 @@ -2129,6 +2129,9 @@ case E_IDENTIFIER: msg = "invalid character in identifier"; break; + case E_BADSINGLE: + msg = "multiple statements found while compiling a single statement"; + break; default: fprintf(stderr, "error=%d\n", err->error); msg = "unknown parsing error";
