diff options
author | Richard Kenner <kenner@gcc.gnu.org> | 1994-12-08 14:19:11 -0500 |
---|---|---|
committer | Richard Kenner <kenner@gcc.gnu.org> | 1994-12-08 14:19:11 -0500 |
commit | b6d9014380599b256146987362e5bbbf443d065d (patch) | |
tree | 17d0b6d146451194440818eb7613fcfe09d80d6d | |
parent | c03413c782ddde861c023ee127a9f24dd1104df9 (diff) | |
download | gcc-b6d9014380599b256146987362e5bbbf443d065d.zip gcc-b6d9014380599b256146987362e5bbbf443d065d.tar.gz gcc-b6d9014380599b256146987362e5bbbf443d065d.tar.bz2 |
(discard_comments): If traditional, replace a comment with nothing
instead of with a space.
From-SVN: r8628
-rw-r--r-- | gcc/cccp.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -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] == '*' |