Closed Bug 904184 Opened 10 years ago Closed 10 years ago
Layers .h:22:1: warning: multi-line comment [-Wcomment]
I get several copies of these build warnings, when building mozilla-central with gcc 4.8: > gfx/tests/gtest/TestLayers.h:22:1: warning: multi-line comment [-Wcomment] > gfx/tests/gtest/TestLayers.h:24:1: warning: multi-line comment [-Wcomment] The warning indicates that we have a "//" comment that ends with a "\", making the single-line comment continue onto the next line. The "\" is actually part of an ASCII art picture. We should just make this a C-style comment with /* ... */. That fixes this.
IMO this warning isn't useful. I don't like /**/ because they don't nest very well.
Fixed with search-and-replace. (replacing "//" with " *" except on the first line of the comment, and added a final "*/" line)
Assignee: nobody → dholbert
Status: NEW → ASSIGNED
Attachment #789085 - Flags: review?(bgirard)
Comment on attachment 789085 [details] [diff] [review] fix v1 I'm ok with this because I rather be warning clean over minimizing /**/ but I wouldn't mind if we disabled this warning.
Attachment #789085 - Flags: review?(bgirard) → review+
(In reply to Benoit Girard (:BenWa) from comment #3) > I'm ok with this because I rather be warning clean over minimizing /**/ but > I wouldn't mind if we disabled this warning. (I'd be against disabling this warning, FWIW, since it also checks for /* within existing /**/ comment, which is more clearly-wrong and worth catching/fixing.)
(Not to mention: if the ascii-art "\" is in the *last* line of a comment, right before some code, you'll unintentionally be commenting out the first line of code.)
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla26
You need to log in before you can comment on or make changes to this bug.