Message371399
> + Py_ssize_t linesize = PyUnicode_GET_LENGTH(line);
This line is wrong though, since PyUnicode_GET_LENGTH returns the length in code points and PyUnicode_DecodeUTF8 expects the number of bytes. For non-ascii input this would push the caret further to the left. For example:
$ ./python.exe
Python 3.10.0a0 (heads/master-dirty:e2fb8a2c42, Jun 12 2020, 20:22:52)
[Clang 11.0.0 (clang-1100.0.33.8)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> "Ṕýţĥòñ" +
File "<stdin>", line 1
"Ṕýţĥòñ" +
^
SyntaxError: invalid syntax |
|
| Date |
User |
Action |
Args |
| 2020-06-12 17:28:31 | lys.nikolaou | set | recipients:
+ lys.nikolaou, christian.heimes, pablogsal |
| 2020-06-12 17:28:31 | lys.nikolaou | set | messageid: <[email protected]> |
| 2020-06-12 17:28:31 | lys.nikolaou | link | issue40958 messages |
| 2020-06-12 17:28:30 | lys.nikolaou | create | |
|