From owner-freebsd-arch@FreeBSD.ORG Wed Dec 22 18:37:12 2004 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1388616A4CE; Wed, 22 Dec 2004 18:37:12 +0000 (GMT) Received: from harmony.village.org (rover.village.org [168.103.84.182]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9C91643D2D; Wed, 22 Dec 2004 18:37:11 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.13.1/8.13.1) with ESMTP id iBMIXlWS023463; Wed, 22 Dec 2004 11:33:47 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Wed, 22 Dec 2004 11:34:11 -0700 (MST) Message-Id: <20041222.113411.76074974.imp@bsdimp.com> To: peadar.edwards@gmail.com From: "M. Warner Losh" In-Reply-To: <34cb7c8404122205002bd7de18@mail.gmail.com> References: <20041222090855.GO79646@cirb503493.alcatel.com.au> <20041222103844.GI801@straylight.m.ringlet.net> <34cb7c8404122205002bd7de18@mail.gmail.com> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit cc: grog@freebsd.org cc: PeterJeremy@optushome.com.au cc: arch@freebsd.org Subject: Re: Header files with enums instead of defines? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Dec 2004 18:37:12 -0000 In order to gain the benefits of the enums, errno would need to be an enum errno_t or some such. This breaks C++ code that sets errno = 0, since you can't assign integers to errno values. So even if you retained EBOGUS or whatever, this wouldn't work with C++. errno has to be an int to work there. Warner