mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
EOF in source is a SyntaxError, not an EOFError.
This commit is contained in:
parent
4ddf8cc408
commit
c4884007f9
1 changed files with 1 additions and 1 deletions
|
@ -192,7 +192,7 @@ err_input(err)
|
|||
err_nomem();
|
||||
break;
|
||||
case E_EOF:
|
||||
err_setstr(EOFError, "unexpected EOF while parsing");
|
||||
err_setstr(SyntaxError, "unexpected EOF while parsing");
|
||||
break;
|
||||
default:
|
||||
err_setstr(SystemError, "unknown parsing error");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue