From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Sun, 24 May 2020 05:20:44 +0000 (-0700) Subject: Use Py_ssize_t for the column number in the PEG support code (GH-20341) X-Git-Tag: v3.9.0b2~103 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=11fb605cb8b632387c5599bbe3ded1d966d50138;p=thirdparty%2FPython%2Fcpython.git Use Py_ssize_t for the column number in the PEG support code (GH-20341) (cherry picked from commit b23d7adfdfa66dd8e6f98e968b1ba885692b67d6) Co-authored-by: Pablo Galindo --- diff --git a/Parser/pegen/pegen.c b/Parser/pegen/pegen.c index f1e3f9efb2f6..9cade2a476de 100644 --- a/Parser/pegen/pegen.c +++ b/Parser/pegen/pegen.c @@ -408,7 +408,7 @@ _PyPegen_raise_error_known_location(Parser *p, PyObject *errtype, } } - int col_number = byte_offset_to_character_offset(error_line, col_offset); + Py_ssize_t col_number = byte_offset_to_character_offset(error_line, col_offset); tmp = Py_BuildValue("(OiiN)", p->tok->filename, lineno, col_number, error_line); if (!tmp) {