From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13857 invoked by alias); 23 Oct 2002 01:42:58 -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 13847 invoked from network); 23 Oct 2002 01:42:57 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sources.redhat.com with SMTP; 23 Oct 2002 01:42:57 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id g9N1Law21098 for ; Tue, 22 Oct 2002 21:21:36 -0400 Received: from pobox.corp.redhat.com (pobox.corp.redhat.com [172.16.52.156]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id g9N1guf08160; Tue, 22 Oct 2002 21:42:56 -0400 Received: from localhost.redhat.com (IDENT:WTT4KhnsWBUTKpdyLWaJW6+ysIbF3QgU@tooth.toronto.redhat.com [172.16.14.29]) by pobox.corp.redhat.com (8.11.6/8.11.6) with ESMTP id g9N1gl032180; Tue, 22 Oct 2002 21:42:49 -0400 Received: by localhost.redhat.com (Postfix, from userid 469) id 811A5FF79; Tue, 22 Oct 2002 21:39:59 -0400 (EDT) From: Elena Zannoni MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15797.65007.413282.953611@localhost.redhat.com> Date: Tue, 22 Oct 2002 18:42:00 -0000 To: Michael Snyder Cc: Andrew Cagney , Jim Blandy , Adam Fedor , gdb-patches@sources.redhat.com Subject: Re: [PATCH] Objective-C language support. In-Reply-To: <3DB5E74A.A633D6F3@redhat.com> References: <3D889A97.90202@doc.com> <3DA36F49.8AD2DD1E@redhat.com> <3DB47FA1.5080706@redhat.com> <3DB5E74A.A633D6F3@redhat.com> X-SW-Source: 2002-10/txt/msg00450.txt.bz2 Michael Snyder writes: > Andrew Cagney wrote: > > > > > This change is approved. (Thanks for the reminder, Michael.) > > > > > > Michael Snyder writes: > > > > I think, here, that garish macro needs to be re-written as a function. > > Any symtab maintainer care to do it? > > Mumble mumble... I'm trying to get to it, but stuff-for-which-I-get-paid > keeps coming up. ;-( > me doing it now...there are a few other macros worth zapping. Elena > > > > > Andrew > > > > >> Adam Fedor wrote: > > > > > >> > > > >> > This patch adds Objective-C language support to gdb based upon a patch > > >> > provided by Apple Computer Inc from their version of gdb. Note that the > > >> > patch only contains changes to existing files. New files (objc-lang.h, > > >> > objc-lang.c, objc-exp.y) and a gdb.objc testsuite directory are located at > > >> > > > >> > ftp://ftp.gnustep.org/pub/gnustep/contrib/gdb-objc-patch.tar.gz > > > > > >> > > >> This change is (remotely) related to symbol tables, which belong to > > >> Jim Blandy and Elena Zannoni. Jim, do you have any objection to this > > >> change? I think it's almost obvious, and recommend it for approval. > > >> > > >> > > > > > >> > * symtab.h: New objc_specific struct. > > >> > (SYMBOL_INIT_LANGUAGE_SPECIFIC): Handle ObjC. > > >> > (SYMBOL_DEMANGLED_NAME): Likewise. > > > > > >> > > > > > >> > Index: gdb/symtab.h > > >> > =================================================================== > > >> > RCS file: /cvs/src/src/gdb/symtab.h,v > > >> > retrieving revision 1.39 > > >> > diff -u -p -r1.39 symtab.h > > >> > --- gdb/symtab.h 12 Sep 2002 19:19:37 -0000 1.39 > > >> > +++ gdb/symtab.h 17 Sep 2002 19:31:07 -0000 > > >> > @@ -89,6 +89,11 @@ struct general_symbol_info > > >> > char *demangled_name; > > >> > } > > >> > cplus_specific; > > >> > + struct objc_specific > > >> > + { > > >> > + char *demangled_name; > > >> > + } > > >> > + objc_specific; > > >> > #if 0 > > >> > /* OBSOLETE struct chill_specific *//* For Chill */ > > >> > /* OBSOLETE { */ > > >> > @@ -146,6 +151,10 @@ extern CORE_ADDR symbol_overlayed_addres > > >> > { \ > > >> > SYMBOL_CPLUS_DEMANGLED_NAME (symbol) = NULL; \ > > >> > } \ > > >> > + else if (SYMBOL_LANGUAGE (symbol) == language_objc) \ > > >> > + { \ > > >> > + SYMBOL_OBJC_DEMANGLED_NAME (symbol) = NULL; \ > > >> > + } \ > > >> > /* OBSOLETE else if (SYMBOL_LANGUAGE (symbol) == language_chill) */ \ > > >> > /* OBSOLETE { */ \ > > >> > /* OBSOLETE SYMBOL_CHILL_DEMANGLED_NAME (symbol) = NULL; */ \ > > >> > @@ -170,12 +179,17 @@ extern void symbol_init_demangled_name ( > > >> > (SYMBOL_LANGUAGE (symbol) == language_cplus \ > > >> > || SYMBOL_LANGUAGE (symbol) == language_java \ > > >> > ? SYMBOL_CPLUS_DEMANGLED_NAME (symbol) \ > > >> > + : (SYMBOL_LANGUAGE (symbol) == language_objc \ > > >> > + ? SYMBOL_OBJC_DEMANGLED_NAME (symbol) \ > > >> > : /* OBSOLETE (SYMBOL_LANGUAGE (symbol) == language_chill */ \ > > >> > /* OBSOLETE ? SYMBOL_CHILL_DEMANGLED_NAME (symbol) */ \ > > >> > - NULL) > > >> > + NULL)) > > >> > > > >> > /* OBSOLETE #define SYMBOL_CHILL_DEMANGLED_NAME(symbol) */ > > >> > /* OBSOLETE (symbol)->ginfo.language_specific.chill_specific.demangled_name */ > > >> > + > > >> > +#define SYMBOL_OBJC_DEMANGLED_NAME(symbol) \ > > >> > + (symbol)->ginfo.language_specific.objc_specific.demangled_name > > >> > > > >> > /* Macro that returns the "natural source name" of a symbol. In C++ this is > > >> > the "demangled" form of the name if demangle is on and the "mangled" form > > > > > >