This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pablogsal
Recipients christian.heimes, lys.nikolaou, pablogsal
Date 2020-06-12.13:08:51
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1591967331.12.0.426265290394.issue40958@roundup.psfhosted.org>
In-reply-to
Content
Correcting my previous post (deleted):

You can get an assert failure without ASAN with this patch:

diff --git a/Parser/pegen.c b/Parser/pegen.c
index e29910bf86..65fa44921f 100644
--- a/Parser/pegen.c
+++ b/Parser/pegen.c
@@ -145,6 +145,9 @@ byte_offset_to_character_offset(PyObject *line, int col_offset)
     if (!str) {
         return 0;
     }
+    assert(col_offset <= PyUnicode_GET_LENGTH(line));
     PyObject *text = PyUnicode_DecodeUTF8(str, col_offset, "replace");
     if (!text) {
         return 0;
History
Date User Action Args
2020-06-12 13:08:51pablogsalsetrecipients: + pablogsal, christian.heimes, lys.nikolaou
2020-06-12 13:08:51pablogsalsetmessageid: <1591967331.12.0.426265290394.issue40958@roundup.psfhosted.org>
2020-06-12 13:08:51pablogsallinkissue40958 messages
2020-06-12 13:08:51pablogsalcreate