Bruce Evans writes: > >In fact, style(9) should say: > > > > If at all possible, your code should compile without warnings > > when the gcc -Wall flag is given. > > Avoiding warnings is more an engineering than a stylistic matter. > You turn on warnings to help avoid bugs that the compiler can find > easily. You ask everyone else to turn on warnings so that compiling > their sources with the same CFLAGS as your sources doesn't cause a > spew of warnings.
Well said. Personally, it would take me twice as long to debug code without -Wall. > >As it stands now (and I QUOTE!) it says: > > > > Don't use parentheses unless they're required for precedence, or > > the statement is really confusing without them. > > > > a = b->c[0] + ~d == (e || f) || g && h ? i : j >> 1; > > > >That's ridiculous! > > I think it's trying to be funny. This makes it a bad example either > way. Perhaps its point is that complicated expressions can't be made > less confusing by adding parentheses. Guess I missed the joke then.. :-) You're right, some things are inherently complicated. I think line formatting is as importatn as parentheses, for example. -Archie ___________________________________________________________________________ Archie Cobbs * Whistle Communications, Inc. * http://www.whistle.com To Unsubscribe: send mail to majord...@freebsd.org with "unsubscribe freebsd-current" in the body of the message