diff options
| author | kristerw <kristerw@NetBSD.org> | 2003-05-26 00:03:50 +0000 |
|---|---|---|
| committer | kristerw <kristerw@NetBSD.org> | 2003-05-26 00:03:50 +0000 |
| commit | 66cf1d6099e7edf80f8deecf20cf83ade79dddfe (patch) | |
| tree | 953a07488b8e7460777094732f9a025c47665221 /gnu | |
| parent | 5d42d770eb611614ec2383479bfddaa0c1bdcdaf (diff) | |
Handle comments in macros when the -C flag is specified to the
pre-processor.
This makes code of the form
#define FOO(X) (BAR(X))
#define BAR(X) (X)
#define BAZ 23 /* comment, comment. */
int foo(void) { return FOO(BAZ); }
be output as expected. (The old behaviour got confused by the ','
within the comment.)
Diffstat (limited to 'gnu')
| -rw-r--r-- | gnu/dist/toolchain/gcc/cccp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gnu/dist/toolchain/gcc/cccp.c b/gnu/dist/toolchain/gcc/cccp.c index 348ddebb26e..41d58f8f2d6 100644 --- a/gnu/dist/toolchain/gcc/cccp.c +++ b/gnu/dist/toolchain/gcc/cccp.c @@ -8944,7 +8944,7 @@ macarg1 (start, limit, macro, depthptr, newlines, comments, rest_args) ++*newlines; break; case '/': - if (macro) + if (macro && !put_out_comments) break; if (bp[1] == '\\' && bp[2] == '\n') newline_fix (bp + 1); |
