Message294869
Python parser supports only ' ', '\t', '\x0c' and '\r' as whitespaces. The parser of f-strings raises incorrect error messages for subexpressions consistent only from whitespaces, if they contain whitespaces out this set.
>>> eval("\xa0")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<string>", line 1
^
SyntaxError: invalid character in identifier
>>> eval("f'''{\xa0}'''")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<string>", line 1
SyntaxError: f-string: empty expression not allowed |
|
Date |
User |
Action |
Args |
2017-05-31 20:24:52 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, eric.smith |
2017-05-31 20:24:52 | serhiy.storchaka | set | messageid: <1496262292.77.0.0898281487446.issue30529@psf.upfronthosting.co.za> |
2017-05-31 20:24:52 | serhiy.storchaka | link | issue30529 messages |
2017-05-31 20:24:52 | serhiy.storchaka | create | |
|