[issue40246] Different error messages for same error - invalid string prefixes
Lysandros Nikolaou
report at bugs.python.org
Tue Apr 28 20:45:55 EDT 2020
Lysandros Nikolaou <lisandrosnik at gmail.com> added the comment:
A possible solution would be to only emit a SyntaxError if the NAME directly preceding a STRING token contains one of the valid string prefixes (either one of 'f', 'r', 'u', 'b'). This would still output a nicer error message, but would not break code like the one of the example. What do you think about this?
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue40246>
_______________________________________
More information about the Python-bugs-list
mailing list