From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6059 invoked by alias); 13 Jul 2004 17:11:56 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 6047 invoked from network); 13 Jul 2004 17:11:55 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 13 Jul 2004 17:11:55 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.10/8.12.10) with ESMTP id i6DHBte3017023; Tue, 13 Jul 2004 13:11:55 -0400 Received: from lacrosse.corp.redhat.com (lacrosse.corp.redhat.com [172.16.52.154]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i6DHBt010790; Tue, 13 Jul 2004 13:11:55 -0400 Received: from miranda.boston.redhat.com (sebastian-int.corp.redhat.com [172.16.52.221]) by lacrosse.corp.redhat.com (8.11.6/8.11.6) with ESMTP id i6DHBrF26786; Tue, 13 Jul 2004 13:11:53 -0400 Received: by miranda.boston.redhat.com (Postfix, from userid 2638) id 47C5C247AA; Tue, 13 Jul 2004 13:11:50 -0400 (EDT) To: Bernardo Innocenti Cc: Richard Henderson , Andrew Pinski , GCC Patches , gdb-patches@redhat.com, binutils@redhat.com, Ian Lance Taylor , DJ Delorie Subject: Re: [libiberty] Add ARG_UNUSED as a C++-friendly replacement for ATTRIBUTE_UNUSED From: Jason Merrill In-Reply-To: <40F39A33.5040706@develer.com> (Bernardo Innocenti's message of "Tue, 13 Jul 2004 10:15:47 +0200") References: <200407120419.i6C4Jq318362@tin.geop.uc.edu> <40F3944C.1000502@develer.com> <20040713081153.GA3089@redhat.com> <40F39A33.5040706@develer.com> Date: Tue, 13 Jul 2004 17:11:00 -0000 Message-ID: User-Agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2004-07/txt/msg00154.txt.bz2 On Tue, 13 Jul 2004 10:15:47 +0200, Bernardo Innocenti wrote: > Richard Henderson wrote: >> On Tue, Jul 13, 2004 at 09:50:36AM +0200, Bernardo Innocenti wrote: >> >>>define ARG_UNUSED(T,N) to "T N"). >> >> >> If we do this, I'd prefer >> >> T ARG_UNUSED(N) >> >> #ifdef __cplusplus >> # define ARG_UNUSED(N) >> #elif somegccversion >> # define ARG_UNUSED(N) N ATTRIBUTE_UNUSED >> #else >> # define ARG_UNUSED(N) N >> #endif > > This wouldn't allow us to support g++ < 3.4: > > # define ARG_UNUSED(T,N) ATTRIBUTE_UNUSED T N Huh? rth's definition above supports all C++ compilers just fine. Jason