[issue28611] Syntax error when using raw strings ending with a backslash.
Emanuel Barry
report at bugs.python.org
Fri Nov 4 12:35:45 EDT 2016
Emanuel Barry added the comment:
That's how strings work, unfortunately. You can't end any string (raw or not) with an odd number of backslashes. You could do the following to get around this limitation:
>>> r"C:\Folder" "\\"
'C:\\Folder\\'
As a side note, please don't upload screenshots if what you're capturing consists only of text (you can paste it directly in your message). This makes it impossible to copy-paste input in the interpreter to try to replicate the issue, and makes it harder/impossible for the blind and visually-impaired to contribute. Thanks!
----------
nosy: +ebarry
resolution: -> not a bug
stage: -> resolved
status: open -> closed
type: compile error -> behavior
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue28611>
_______________________________________
More information about the Python-bugs-list
mailing list