https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117118

--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-14 branch has been updated by Lewis Hyatt
<lhy...@gcc.gnu.org>:

https://gcc.gnu.org/g:9214e3fdf914dd2b687f13980c39ac2db7b1565f

commit r14-10980-g9214e3fdf914dd2b687f13980c39ac2db7b1565f
Author: Lewis Hyatt <lhy...@gmail.com>
Date:   Mon Oct 14 17:59:46 2024 -0400

    libcpp: Fix ICE lexing invalid raw string in a deferred pragma [PR117118]

    The PR shows that we ICE after lexing an invalid unterminated raw string,
    because lex_raw_string() pops the main buffer unexpectedly. Resolve by
    handling this case the same way as for other directives.

    libcpp/ChangeLog:
            PR preprocessor/117118
            * lex.cc (lex_raw_string): Treat an unterminated raw string the
same
            way for a deferred pragma as is done for other directives.

    gcc/testsuite/ChangeLog:
            PR preprocessor/117118
            * c-c++-common/raw-string-directive-3.c: New test.
            * c-c++-common/raw-string-directive-4.c: New test.

Reply via email to