From owner-cvs-all Wed Jan 20 07:07:56 1999 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id HAA08935 for cvs-all-outgoing; Wed, 20 Jan 1999 07:07:56 -0800 (PST) (envelope-from owner-cvs-all@FreeBSD.ORG) Received: from ceia.nordier.com (m2-5-dbn.dial-up.net [196.34.155.69]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id HAA08914; Wed, 20 Jan 1999 07:07:45 -0800 (PST) (envelope-from rnordier@nordier.com) Received: (from rnordier@localhost) by ceia.nordier.com (8.8.7/8.6.12) id RAA03282; Wed, 20 Jan 1999 17:05:38 +0200 (SAT) From: Robert Nordier Message-Id: <199901201505.RAA03282@ceia.nordier.com> Subject: Re: -Werror In-Reply-To: <199901201459.WAA20451@spinner.netplex.com.au> from Peter Wemm at "Jan 20, 99 10:59:26 pm" To: peter@netplex.com.au (Peter Wemm) Date: Wed, 20 Jan 1999 17:05:35 +0200 (SAT) Cc: eivind@FreeBSD.ORG, rnordier@nordier.com, fenner@parc.xerox.com, bde@zeta.org.au, cvs-committers@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk Peter Wemm wrote: > Eivind Eklund wrote: > > On Wed, Jan 20, 1999 at 04:31:29PM +0200, Robert Nordier wrote: > > > but rewriting to eliminate the errors would violate a style(9) > > > guideline (unnecessary parentheses). There's an awful lot of BSD > > > code like this, that could cause huge {Net,Open}BSD diffs if > > > rewritten. > > > > NetBSD and OpenBSD does, AFAIK, compile their kernel with -Wall > > -Werror. > > I'm pretty sure I saw that NetBSD also do something like this for large > chunks of userland too. If I recall correctly (I don't have the source > handy), they have bsd.*.mk hook to enable tree based (Makefile.inc) > setting of the flags, and allowing overrides on a per directory basis as > well. Yes, looking at a bit of OpenBSD code, they do seem to have made sweeping changes to eliminate the quoted warnings. > Re: style(9).. Some argue that parentheses to aid readability are > not "unnecessary". style(9) says "Don't add braces that aren't > necessary." - it doesn't say ".. for correct compilation". Having code > clear and readable is "necessary". :-) It actually says, "Don't use parentheses unless they're required for precedence, or the statement is really confusing without them." :) > > > Eivind. > > Cheers, > -Peter > > -- Robert Nordier To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message