This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/86079] New: preprocessor fails to splice lines
- From: "jbeulich at novell dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 07 Jun 2018 08:50:42 +0000
- Subject: [Bug preprocessor/86079] New: preprocessor fails to splice lines
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86079
Bug ID: 86079
Summary: preprocessor fails to splice lines
Product: gcc
Version: 8.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: preprocessor
Assignee: unassigned at gcc dot gnu.org
Reporter: jbeulich at novell dot com
Target Milestone: ---
While gcc 4.3 looks to still handle this correctly, at least all versions from
4.7 onwards (I don't have the intermediate versions readily available to check)
fail to splice lines where the first one ends in an escaped newline, at least
in the common case. Note the inconsistency with
unsigned \
int \\
u \\\
;
where the second and third lines are being spliced by "gcc -E", but none of the
others.
This is a clear violation of the standard's translation phase 2, making it
impossible to e.g. preprocess something like
https://xenbits.xen.org/gitweb/?p=xen.git;a=blob;f=xen/include/asm-x86/alternative-asm.h;h=0b6151634a01e9662ae4100dcaf3c0736885eb87;hb=refs/heads/staging
into code usable by the .s files produced by the compiler.