From owner-svn-src-head@FreeBSD.ORG Mon May 20 14:03:08 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 72083ADC; Mon, 20 May 2013 14:03:08 +0000 (UTC) (envelope-from stefan@fafoe.narf.at) Received: from fep17.mx.upcmail.net (fep17.mx.upcmail.net [62.179.121.37]) by mx1.freebsd.org (Postfix) with ESMTP id 655EDB3B; Mon, 20 May 2013 14:03:07 +0000 (UTC) Received: from edge01.upcmail.net ([192.168.13.236]) by viefep17-int.chello.at (InterMail vM.8.01.05.05 201-2260-151-110-20120111) with ESMTP id <20130520140305.RZB11712.viefep17-int.chello.at@edge01.upcmail.net>; Mon, 20 May 2013 16:03:05 +0200 Received: from mole.fafoe.narf.at ([80.109.55.137]) by edge01.upcmail.net with edge id eE351l00Z2xdvHc01E35ej; Mon, 20 May 2013 16:03:05 +0200 X-SourceIP: 80.109.55.137 Received: by mole.fafoe.narf.at (Postfix, from userid 1001) id 175E56D449; Mon, 20 May 2013 16:03:05 +0200 (CEST) Date: Mon, 20 May 2013 16:03:04 +0200 From: Stefan Farfeleder To: Ed Schouten Subject: Re: svn commit: r250806 - head/sys/sys Message-ID: <20130520140304.GA1429@mole.fafoe.narf.at> References: <201305190744.r4J7i2FD055067@svn.freebsd.org> <20130519094813.GA1465@mole.fafoe.narf.at> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 May 2013 14:03:08 -0000 On Mon, May 20, 2013 at 01:06:50PM +0200, Ed Schouten wrote: > Hi Stefan, > > 2013/5/19 Stefan Farfeleder : > > Shouldn't we fix lint and our headers to use a different macro name? One > > starting with __? > > Fixing lint: yes. Changing our macros to use a different name: no. > The reason why we had __volatile, __inline, etc. in the first place, > was because adding definitions for volatile and inline directly would > be against the standard, as these words can be used freely in C11 only added keywords starting with _[A-Z], which is reserved by all > the older standards, meaning we are completely free to define them in > any way we like. > > This specific breakage was unrelated to the naming of the keyword. The > breakage existed, because existing tools do a build with -Dlint set. > Because we use _Thread_local in our own header files already > (runetype.h, I think), this caused a variable declared in a header > file to be of the wrong kind (TLS vs non-TLS). > > In my opinion we should not add __[a-z] definitions for things that > are part of C11. Doing this only makes our code less easily exportable > to other systems. Hi Ed, I think you misunderstood what I meant. We now have quiet a few occurrences of `#ifdef lint' or equivalent in /usr/include. I think those should be changed to `#ifdef __lint' to allow application code to do #define lint foo #include which is perfectly fine POSIX code (at least to my knowledge) and should not change the behaviour of the included header. Stefan