[Bug preprocessor/99446] [11 Regression] ICE in linemap_position_for_loc_and_offset, at libcpp/line-map.c:1005 since r11-6325
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Apr 13 12:07:29 GMT 2021
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99446
--- Comment #11 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Nathan Sidwell <nathan@gcc.gnu.org>:
https://gcc.gnu.org/g:4acb3af3669db4ca79ffc97cd615fcea205bcccb
commit r11-8150-g4acb3af3669db4ca79ffc97cd615fcea205bcccb
Author: Nathan Sidwell <nathan@acm.org>
Date: Tue Apr 13 05:03:19 2021 -0700
preprocessor: Fix column adjustment [PR 99446]
This ICE was because when adjusting a column offset we could advance
into a linemap for a different file. We only checked the next line
map was not for a line further advanced in any file, forgetting that
it could be for an earlier line in a different file. The testcase
needed adjusting as column 512 was unrepresentable, once that was
taken into consideration.
PR preprocessor/99446
libcpp/
* line-map.c (line-map.c): Do not advance to linemaps for
different files.
gcc/testsuite/
* g++.dg/diagnostic/pr72803.C: Adjust expected column.
More information about the Gcc-bugs
mailing list