From b6d9014380599b256146987362e5bbbf443d065d Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Thu, 8 Dec 1994 14:19:11 -0500 Subject: [PATCH] (discard_comments): If traditional, replace a comment with nothing instead of with a space. From-SVN: r8628 --- gcc/cccp.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) 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] == '*' -- 2.30.2