In article <201108230521.baa12...@sparkle.rodents-montreal.org>, Mouse <mo...@rodents-montreal.org> wrote: >>> [...] gcc errors due to comparison of signed and unsigned values. > >> It is best to fix the errors. > >What errors? > >It is not necessarily an error to compare signed and unsigned values. >In my experience, that warning produces so many more false positives >than useful warnings that I normally shut it off entirely.
And it is not an error to put assignments in conditionals, or not place parentheses to clarify operator precedence, etc. It is a warning; the compiler is telling you that it is unclear what you are trying to do, and you should check to make sure that this is what you want to do (and let the compiler know by making your intentions clear). For some of us this is helpful. The compiler writers try to help protect programmers against common mistakes. If you don't like the warnings you are free to turn them off. christos