From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E7773393D008; Sun, 18 Apr 2021 12:44:48 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E7773393D008 From: "bernd.edlinger at hotmail dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug preprocessor/99446] [11 Regression] ICE in linemap_position_for_loc_and_offset, at libcpp/line-map.c:1005 since r11-6325 Date: Sun, 18 Apr 2021 12:44:48 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: preprocessor X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: bernd.edlinger at hotmail dot de X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: nathan at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Apr 2021 12:44:49 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D99446 --- Comment #13 from Bernd Edlinger --- Hi Nathan, I've been playing with a variant of c-c++-common/raw-string-6.c with your patch: $ cat raw-string-6.c $ cat raw-string-6.c=20 // { dg-do compile } // { dg-options "-std=3Dgnu99" { target c } } // { dg-options "-std=3Dc++0x" { target c++ } } #include "xxxx.h" $ cat xxxx.h=20 const void *s0 =3D R"ouch()ouCh"; $ gcc -x c raw-string-6.c In file included from raw-string-6.c:5: xxxx.h:1:18: error: unterminated raw string 1 | const void *s0 =3D R"ouch()ouCh"; | ^ raw-string-6.c:6: error: expected expression at end of input $ gcc -x c++ raw-string-6.c=20 In file included from raw-string-6.c:5: xxxx.h:1:18: error: unterminated raw string 1 | const void *s0 =3D R"ouch()ouCh"; | ^ xxxx.h:1:16: error: expected primary-expression at end of input 1 | const void *s0 =3D R"ouch()ouCh"; | ^ Do you agree that the C++ FE places the error about the end of input on a somewhat surprising place? Bernd.=