From: Richard Kenner Date: Thu, 8 Dec 1994 19:19:11 +0000 (-0500) Subject: (discard_comments): If traditional, replace a comment with nothing X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b6d9014380599b256146987362e5bbbf443d065d;p=gcc.git (discard_comments): If traditional, replace a comment with nothing instead of with a space. From-SVN: r8628 --- diff --git a/gcc/cccp.c b/gcc/cccp.c index fa6d363dea5..45900f0cad3 100644 --- a/gcc/cccp.c +++ b/gcc/cccp.c @@ -8407,8 +8407,12 @@ discard_comments (start, length, newlines) } if (ibp[0] != '*' || ibp + 1 >= limit) break; - /* Comments are equivalent to spaces. */ - obp[-1] = ' '; + /* Comments are equivalent to spaces. + For -traditional, a comment is equivalent to nothing. */ + if (traditional) + obp--; + else + obp[-1] = ' '; ibp++; while (ibp + 1 < limit) { if (ibp[0] == '*'