From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9501 invoked by alias); 26 Jun 2013 08:38:26 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 9459 invoked by uid 48); 26 Jun 2013 08:38:21 -0000 From: "manu at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug preprocessor/57714] Newline rendered incorrectly in output Date: Wed, 26 Jun 2013 08:38:00 -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: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: manu at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- 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-SW-Source: 2013-06/txt/msg01541.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D57714 --- Comment #9 from Manuel L=C3=B3pez-Ib=C3=A1=C3=B1ez --- I think what happens is that the preprocessor is trying to avoid breaking u= p a valid token like in: void foo(void) {re\ turn; } It would be an improvement if it ignored the \ between valid tokens boundar= ies even if there is no whitespace, but I think there is not going to be anyone sufficiently bothered to fix this ever. So unless you want to give it a try, let's leave this bug report closed. I added a note to the FAQ. >>From gcc-bugs-return-425163-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Wed Jun 26 08:45:37 2013 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 12194 invoked by alias); 26 Jun 2013 08:45:37 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 12138 invoked by uid 48); 26 Jun 2013 08:45:27 -0000 From: "potswa at mac dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug preprocessor/57714] Newline rendered incorrectly in output Date: Wed, 26 Jun 2013 08:45:00 -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: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: potswa at mac dot com X-Bugzilla-Status: RESOLVED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-06/txt/msg01542.txt.bz2 Content-length: 551 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57714 --- Comment #10 from David Krauss --- I don't plan on fixing this in GCC, but I did implement the feature today in my own preprocessor, http://code.google.com/p/c-plus/source/list . It does require a handshake between phases 2 and 3, because a token divided over two lines needs to go into the earlier line, and then the extra newlines are flushed once the token is complete. But a newline inside a whitespace "token" is not postponed. OK, on to bigger and better things :)