From owner-svn-src-all@FreeBSD.ORG Tue Apr 21 07:42:59 2015 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0CF027AB; Tue, 21 Apr 2015 07:42:59 +0000 (UTC) Received: from theravensnest.org (theraven.freebsd.your.org [216.14.102.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "cloud.theravensnest.org", Issuer "StartCom Class 1 Primary Intermediate Server CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id C7C49102C; Tue, 21 Apr 2015 07:42:58 +0000 (UTC) Received: from [192.168.0.7] (cpc16-cmbg15-2-0-cust60.5-4.cable.virginm.net [86.5.162.61]) (authenticated bits=0) by theravensnest.org (8.15.1/8.15.1) with ESMTPSA id t3L7gmqO058209 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 21 Apr 2015 07:42:50 GMT (envelope-from theraven@FreeBSD.org) X-Authentication-Warning: theravensnest.org: Host cpc16-cmbg15-2-0-cust60.5-4.cable.virginm.net [86.5.162.61] claimed to be [192.168.0.7] Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2098\)) Subject: Re: svn commit: r281721 - head/sys/sys From: David Chisnall In-Reply-To: <20150421020808.D10623@besplex.bde.org> Date: Tue, 21 Apr 2015 08:42:41 +0100 Cc: John Baldwin , Justin Hibbits , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: <785A553E-317E-4C80-83A0-567C80697ED8@FreeBSD.org> References: <201504190033.t3J0XMDX041769@svn.freebsd.org> <476583045.Qcb6O2DFtY@ralph.baldwin.cx> <20150421020808.D10623@besplex.bde.org> To: Bruce Evans X-Mailer: Apple Mail (2.2098) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Apr 2015 07:42:59 -0000 On 20 Apr 2015, at 17:19, Bruce Evans wrote: >=20 > Enums should never be used in ABIs, since their size can be anything > large enough. The rules for the size of enums also differ between C and C++, though = clang (and, I think, gcc) support an attribute for specifying the enum = type. > They also cause namespace problems. The whole enum declaration must > be exposed in any header that uses an enum type. Both C and C++ permit forward declarations of enums for use in function = prototypes and so on, e.g.: enum foo; void bar(enum foo); David