[issue40985] PEG Parser: SyntaxError text empty when last line has a LINECONT
Lysandros Nikolaou
report at bugs.python.org
Mon Jun 15 09:50:22 EDT 2020
Lysandros Nikolaou <lisandrosnik at gmail.com> added the comment:
Copying and pasting the example messed the formatting up. Here it is again.
[16:49:16] lysnikolaou:cpython git:(master*) $ cat t.py
x = 6\% [16:49:23] lysnikolaou:cpython git:(master*) $ ./python t.py
File "/home/lysnikolaou/repos/cpython/t.py", line 2
^
SyntaxError: unexpected EOF while parsing
[16:49:56] lysnikolaou:cpython git:(master*) $ python3.9 -X oldparser t.py
File "/home/lysnikolaou/repos/cpython/t.py", line 2
x = 6\
^
SyntaxError: unexpected EOF while parsing
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue40985>
_______________________________________
More information about the Python-bugs-list
mailing list