From owner-freebsd-hackers Tue Mar 5 16: 8:14 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mailsrv.otenet.gr (mailsrv.otenet.gr [195.170.0.5]) by hub.freebsd.org (Postfix) with ESMTP id 8E0B537B400; Tue, 5 Mar 2002 16:08:10 -0800 (PST) Received: from hades.hell.gr (patr530-a217.otenet.gr [212.205.215.217]) by mailsrv.otenet.gr (8.12.2/8.12.2) with ESMTP id g26087Dg008032; Wed, 6 Mar 2002 02:08:08 +0200 (EET) Received: from hades.hell.gr (hades [127.0.0.1]) by hades.hell.gr (8.12.2/8.12.2) with ESMTP id g260870O007016; Wed, 6 Mar 2002 02:08:07 +0200 (EET) (envelope-from keramida@freebsd.org) Received: (from charon@localhost) by hades.hell.gr (8.12.2/8.12.2/Submit) id g26087T9007015; Wed, 6 Mar 2002 02:08:07 +0200 (EET) (envelope-from keramida@freebsd.org) X-Authentication-Warning: hades.hell.gr: charon set sender to keramida@freebsd.org using -f Date: Wed, 6 Mar 2002 02:08:07 +0200 From: Giorgos Keramidas To: "David O'Brien" Cc: hackers@freebsd.org Subject: Re: RFC: style(9) isn't explicit about booleans for testing. Message-ID: <20020306000806.GC6839@hades.hell.gr> References: <20020305201350.GC4820@hades.hell.gr> <20020305155850.A38095@dragon.nuxi.com> Mime-Version: 1.0 Content-Type: application/pgp; x-action=sign; format=text Content-Disposition: inline; filename="msg.pgp" In-Reply-To: <20020305155850.A38095@dragon.nuxi.com> User-Agent: Mutt/1.3.27i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 2002-03-05 15:58, David O'Brien wrote: > On Tue, Mar 05, 2002 at 10:13:50PM +0200, Giorgos Keramidas wrote: > > > -Don't use '!' for tests unless it's a boolean, e.g. use > > > +For tests, always compare the value to the appropriate 0 instead of > > > +checking it directly, unless the value is a boolean. ... > > Please show examples from /sys that back up this change. To state this > explicitly, I think a significant number of /sys files should be > following it. Actually I was asking for comments, but anyways. I will try to skim through the sources, and look for conditionals, to get the general feel of what is being used. I should note though, that I'm neither supporting or against this change. I'll see what I can do, and hopefully be able to post a followup sooner or later. Giorgos Keramidas FreeBSD Documentation Project keramida@{freebsd.org,ceid.upatras.gr} http://www.FreeBSD.org/docproj/ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) iD8DBQE8hV3m1g+UGjGGA7YRAnTFAJ9Ua0RAbgerbZmWfFAledzJ5xofCACfeiMe CbFAB4YXaf4r37+6Hn8Ye88= =uL9x -----END PGP SIGNATURE----- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message