From owner-freebsd-arch@FreeBSD.ORG Wed Aug 10 05:56:21 2005 Return-Path: X-Original-To: freebsd-arch@freebsd.org 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 1A84316AA18 for ; Wed, 10 Aug 2005 05:55:32 +0000 (GMT) (envelope-from obrien@NUXI.com) Received: from dragon.NUXI.org (trang.nuxi.com [66.93.134.19]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6B7D945B6C for ; Wed, 10 Aug 2005 03:23:12 +0000 (GMT) (envelope-from obrien@NUXI.com) Received: from dragon.NUXI.org (obrien@localhost [127.0.0.1]) by dragon.NUXI.org (8.13.4/8.13.4) with ESMTP id j7A3N9Ou081038; Tue, 9 Aug 2005 20:23:09 -0700 (PDT) (envelope-from obrien@dragon.NUXI.org) Received: (from obrien@localhost) by dragon.NUXI.org (8.13.4/8.13.1/Submit) id j7A3N87V081037; Tue, 9 Aug 2005 20:23:08 -0700 (PDT) (envelope-from obrien) Date: Tue, 9 Aug 2005 20:23:08 -0700 From: "David O'Brien" To: Craig Rodrigues Message-ID: <20050810032308.GA80916@dragon.NUXI.org> Mail-Followup-To: obrien@freebsd.org, Craig Rodrigues , freebsd-arch@freebsd.org References: <20050810005323.GA42721@crodrigues.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050810005323.GA42721@crodrigues.org> X-Operating-System: FreeBSD 7.0-CURRENT Organization: The NUXI BSD Group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 User-Agent: Mutt/1.5.9i Cc: freebsd-arch@freebsd.org Subject: Re: [RFC] -Wredundant-decls: keep it or remove it? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: obrien@freebsd.org List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Aug 2005 05:56:21 -0000 On Tue, Aug 09, 2005 at 08:53:23PM -0400, Craig Rodrigues wrote: > It is illegal in ISO C to declare a struct as extern (implying external > linkage) , and then declare it as static (implying internal linkage). .. > OPTION 2: > Forward declare routedomain as static, but remove -Wredundant-decls > from kernel makefiles: > static struct domain routedomain; > .... > static struct domain routedomain = { ..... } > > For OPTION 2, it is necessary to remove -Wredundant-decls > because you will get a new compiler warning: > > warning: redundant redeclaration of 'routedomain' > warnig: previous declaration was here ... This is a GCC bug that I am working to get fixed. -- -- David (obrien@FreeBSD.org)