aboutsummaryrefslogtreecommitdiff
path: root/gcc/cccp.c
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1995-09-28 14:29:40 -0400
committerRichard Kenner <kenner@gcc.gnu.org>1995-09-28 14:29:40 -0400
commit823a28aa77fff51880e92db9473ae015a2128ab5 (patch)
tree2af3d34051ce3d6422c7334a6ab6ff1d4bd2d1aa /gcc/cccp.c
parent75fbfd0c125bbde33fd02d07b03f85f944ec9ba2 (diff)
downloadgcc-823a28aa77fff51880e92db9473ae015a2128ab5.zip
gcc-823a28aa77fff51880e92db9473ae015a2128ab5.tar.gz
gcc-823a28aa77fff51880e92db9473ae015a2128ab5.tar.bz2
(rescan): Expand `#if foo && #bar' without a bogus complaint about preprocessor directives within macro args.
(rescan): Expand `#if foo && #bar' without a bogus complaint about preprocessor directives within macro args. Expand `foo' in `foo#bar' without requiring a space before `#'. From-SVN: r10412
Diffstat (limited to 'gcc/cccp.c')
-rw-r--r--gcc/cccp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/cccp.c b/gcc/cccp.c
index 9ae8fd0..64f5f75 100644
--- a/gcc/cccp.c
+++ b/gcc/cccp.c
@@ -2770,6 +2770,8 @@ do { ip = &instack[indepth]; \
case '#':
if (assertions_flag) {
+ if (ident_length)
+ goto specialchar;
/* Copy #foo (bar lose) without macro expansion. */
obp[-1] = '#'; /* In case it was '%'. */
SKIP_WHITE_SPACE (ibp);
@@ -2783,6 +2785,7 @@ do { ip = &instack[indepth]; \
obp += ip->bufp - ibp;
ibp = ip->bufp;
}
+ break;
}
/* If this is expanding a macro definition, don't recognize