warning: multi-line comment (why?)
Wed Sep 20 09:38:00 GMT 2000
Jamie Lokier wrote:-
> The motivation is for when you do "comment-region" in Emacs to comment
> out code that includes macros.
Hmm, OK you've persuaded me.
> Hmm. The nulls which warn are part of the multi-line comment. Fair
> enough, I'll fix that and get the correct column numbers too.
A tight while loop with is_nvspace is enough; don't bother with
skip_whitespace - it does too much.
> Trigraph-escaped slashes aren't checked for, so you still get the
> warning in that case. Do you care?
Those warnings are not meant to be there; they're just on for about 48
hours between patches :) I'll commit a patch RSN that turns them off
in comments. What I meant was this:-
// this \
/ is all one comment.
I know it's pedantic, but it's valid and we should continue to get it
right. I think your loop will terminate the comment at the end of the
2nd line. A call to get_effective_char will handle that (instead of
If you do this, would you provide a testcase for the bug above, and
that ensures the warning about multiline comments in not emitted in
the case you're talking about? Don't bother about null character
testcases; in my experience they really confuse CVS.
More information about the Gcc