From owner-freebsd-hackers Tue Mar 16 0:59:16 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from relay.nuxi.com (nuxi.ucdavis.edu [169.237.7.38]) by hub.freebsd.org (Postfix) with ESMTP id 8B0551514E for ; Tue, 16 Mar 1999 00:59:15 -0800 (PST) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by relay.nuxi.com (8.9.2/8.9.1) id AAA73848; Tue, 16 Mar 1999 00:58:54 -0800 (PST) (envelope-from obrien) Date: Tue, 16 Mar 1999 00:58:54 -0800 From: "David O'Brien" To: Jason Thorpe Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Use of "register" in code Message-ID: <19990316005854.B73567@relay.nuxi.com> Reply-To: obrien@NUXI.com References: <199903160539.VAA17718@lestat.nas.nasa.gov> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.4i In-Reply-To: <199903160539.VAA17718@lestat.nas.nasa.gov>; from Jason Thorpe on Mon, Mar 15, 1999 at 09:39:58PM -0800 X-Operating-System: FreeBSD 3.1-STABLE Organization: The NUXI BSD group X-PGP-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Keyid: 34F9F9D5 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, Mar 15, 1999 at 09:39:58PM -0800, Jason Thorpe wrote: > Uhh... "register" isn't in Standard C, is it? ANSI X3.159-1989: 3.1.1 Keywords -------------- "register" listed 3.5.1 Storage-Class Specifiers ------------------------------ A declaration of an identifier for an object with storage-class specifier "register" suggests that access to the object be as fast as possible. The extent to which such suggestions are effective is implementation-defined.(footnote 58) (footnote 58) The implementation may treat any "register" declaration simply as an "auto" declaration. However, whether or not addressable storage is actually used, the address of any part of an object declared with storage-class specifier "register" may not be computed, either explicitly (by use of the unary "&" operator as discussed in 3.3.3.2) or implicitly (by converting an array name to a pointer as discussed in 3.2.2.1). Thus the only operator that can be applied to an array declared with storage-class specifier "register" is "sizeof". -- -- David (obrien@NUXI.com -or- obrien@FreeBSD.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message