Skip to content

Commit b23d7ad

Browse files
authored
Use Py_ssize_t for the column number in the PEG support code (GH-20341)
1 parent 13206b5 commit b23d7ad

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Parser/pegen/pegen.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ _PyPegen_raise_error_known_location(Parser *p, PyObject *errtype,
408408
}
409409
}
410410

411-
int col_number = byte_offset_to_character_offset(error_line, col_offset);
411+
Py_ssize_t col_number = byte_offset_to_character_offset(error_line, col_offset);
412412

413413
tmp = Py_BuildValue("(OiiN)", p->tok->filename, lineno, col_number, error_line);
414414
if (!tmp) {

0 commit comments

Comments
 (0)