From owner-freebsd-audit Tue Dec 4 8:23:17 2001 Delivered-To: freebsd-audit@freebsd.org Received: from espresso.q9media.com (espresso.q9media.com [216.254.138.122]) by hub.freebsd.org (Postfix) with ESMTP id 61A6237B416; Tue, 4 Dec 2001 08:23:13 -0800 (PST) Received: (from mike@localhost) by espresso.q9media.com (8.11.6/8.11.6) id fB4GLm862899; Tue, 4 Dec 2001 11:21:48 -0500 (EST) (envelope-from mike) Date: Tue, 4 Dec 2001 11:21:48 -0500 From: Mike Barcroft To: David Malone Cc: audit@freebsd.org, markm@freebsd.org, Bruce Evans Subject: Re: Warns for tcopy and wc. Message-ID: <20011204112148.F57237@espresso.q9media.com> References: <20011203215452.E57237@espresso.q9media.com> <200112041341.aa05762@salmon.maths.tcd.ie> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200112041341.aa05762@salmon.maths.tcd.ie>; from dwmalone@maths.tcd.ie on Tue, Dec 04, 2001 at 01:41:07PM +0000 Organization: The FreeBSD Project Sender: owner-freebsd-audit@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG David Malone writes: > I presume casting to intmax_t will be the oficially blessed way of > printing typedefed things now? If so we should make gcc's format > warning code understand the %j modifier - maybe I should look into > that (or maybe some of the FreeBSD standards people are doing that?). Yes, intmax_t is guaranteed to be capable of representing any value of any signed integer. Similarly, uintmax_t is guaranteed to be capable of representing any value of any unsigned integer. It would probably be a good idea to teach GCC about these types. > Is it apropriate to use intmax_t where you want to count something > big? For example, would it be OK to change wc and tcopy to use > intmax_t instead of the int64_t and quad_t which they currently > use? That seems like a reasonable use to me. Best regards, Mike Barcroft To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-audit" in the body of the message