From owner-freebsd-hackers Tue Mar 5 13: 0:24 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from rwcrmhc53.attbi.com (rwcrmhc53.attbi.com [204.127.198.39]) by hub.freebsd.org (Postfix) with ESMTP id E48F237B416; Tue, 5 Mar 2002 13:00:15 -0800 (PST) Received: from InterJet.elischer.org ([12.232.206.8]) by rwcrmhc53.attbi.com (InterMail vM.4.01.03.27 201-229-121-127-20010626) with ESMTP id <20020305210015.SKCQ2951.rwcrmhc53.attbi.com@InterJet.elischer.org>; Tue, 5 Mar 2002 21:00:15 +0000 Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id MAA32427; Tue, 5 Mar 2002 12:59:44 -0800 (PST) Date: Tue, 5 Mar 2002 12:59:43 -0800 (PST) From: Julian Elischer To: Giorgos Keramidas Cc: hackers@freebsd.org Subject: Re: RFC: style(9) isn't explicit about booleans for testing. In-Reply-To: <20020305201350.GC4820@hades.hell.gr> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII 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 On Tue, 5 Mar 2002, Giorgos Keramidas wrote: > > > > Read the man page to try and decide if you should write "if (x)" or > > if (x != 0). > > > > >Fix: > > > > Apply the attached page to the style(9) man page. [...] the one that I stop to think about is: if (!(flags & FLAGSET)) or should that be if ((flags & FLAGSET) == 0) it depends on what you define as a Boolean. If FLAGSET has > 1 bit in it then it it still possibly a boolean? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message