From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25654 invoked by alias); 13 Jun 2007 13:09:54 -0000 Received: (qmail 25631 invoked by uid 22791); 13 Jun 2007 13:09:53 -0000 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 13 Jun 2007 13:09:51 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 1EA56982DE; Wed, 13 Jun 2007 13:09:49 +0000 (GMT) Received: from caradoc.them.org (22.svnf5.xdsl.nauticom.net [209.195.183.55]) by nan.false.org (Postfix) with ESMTP id C31AF98212; Wed, 13 Jun 2007 13:09:48 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.67) (envelope-from ) id 1HySbr-00062t-1w; Wed, 13 Jun 2007 09:10:03 -0400 Date: Wed, 13 Jun 2007 13:09:00 -0000 From: Daniel Jacobowitz To: Ulrich Weigand Cc: Vladimir Prus , gdb-patches@sourceware.org Subject: Re: [2/10] Remove &builtin_type_ from tdep code (amd64/s390/sparc64) Message-ID: <20070613131002.GA23051@caradoc.them.org> Mail-Followup-To: Ulrich Weigand , Vladimir Prus , gdb-patches@sourceware.org References: <200706131108.00541.vladimir@codesourcery.com> <200706131306.l5DD6BO8021072@d12av02.megacenter.de.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200706131306.l5DD6BO8021072@d12av02.megacenter.de.ibm.com> User-Agent: Mutt/1.5.15 (2007-04-09) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2007-06/txt/msg00222.txt.bz2 On Wed, Jun 13, 2007 at 03:06:11PM +0200, Ulrich Weigand wrote: > To that purpose, the builtin_type_double global variable will > go away, and is (temporarily) replaced by a macro > > #define builtin_type_double > builtin_type (current_gdbarch)->builtin_double > > However, this macro is not fully equivalent; in particular it > is no longer possible to use &builtin_type_double. You keep saying this, but is it true? :-) You can't take the address of a function's return value, but you can take the address of a dereference. Of course using &builtin_type_double in m68k_gdbarch_init won't work since current_gdbarch is NULL then. But we should be able to save builtin_type (gdbarch)->builtin_double if we wanted to, I think. -- Daniel Jacobowitz CodeSourcery