This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/12963] Wrong and misleading warning encourages writing non-portable code


------- Additional Comments From abramobagnara at tin dot it  2004-09-21 07:24 -------
(In reply to comment #1)
> The warning is correct for this implementation and since you are compiling
with this 
> implementation, you can recieve warnings (yes it would be better if it was
enabled by a -
> W* but I think it is good warning no matter what).  To disable the warning use
-w (notice 
> the lower case w).

I hope that there is a general consensus about the fact that the presence of
expected warnings not avoidable on compilation log is a bad thing.

This lower the attention threshold of programmers and contributors about true
problems and reduce the readability of compilation log. I suppose that the
availability of -Werror is derived from this same reasoning.

Taken for granted that, I think that the presence of warning options like
-wWARNING-NAME to disable specific warnings could solve the problem in a per
file fashion.

Better than that the availability of something like
#pragma expected-warning line WARNING-NAME
might remove the warning generated by the following line labeling it as checked,
expected and/or unavoidable.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12963


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]