From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10889 invoked by alias); 18 Aug 2008 22:32:54 -0000 Received: (qmail 10881 invoked by uid 22791); 18 Aug 2008 22:32:54 -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; Mon, 18 Aug 2008 22:32:15 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 6D1B4983A9; Mon, 18 Aug 2008 22:32:13 +0000 (GMT) Received: from caradoc.them.org (22.svnf5.xdsl.nauticom.net [209.195.183.55]) by nan.false.org (Postfix) with ESMTP id 321F698337; Mon, 18 Aug 2008 22:32:13 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.69) (envelope-from ) id 1KVDGm-0003QX-C5; Mon, 18 Aug 2008 18:32:12 -0400 Date: Mon, 18 Aug 2008 22:32:00 -0000 From: Daniel Jacobowitz To: Andreas Schwab Cc: Tom Tromey , Joel Brobecker , gdb-patches@sourceware.org Subject: Re: RFA: shrink main_type Message-ID: <20080818223212.GA13117@caradoc.them.org> Mail-Followup-To: Andreas Schwab , Tom Tromey , Joel Brobecker , gdb-patches@sourceware.org References: <20080818130009.GM16894@adacore.com> <20080818132001.GA9434@caradoc.them.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2008-05-11) 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: 2008-08/txt/msg00503.txt.bz2 On Tue, Aug 19, 2008 at 12:17:01AM +0200, Andreas Schwab wrote: > Tom Tromey writes: > > > + /* Copy the common fields of types. For the main type, we simply > > + copy the entire thing and then update specific fields as needed. */ > > + memcpy (TYPE_MAIN_TYPE (new_type), TYPE_MAIN_TYPE (type), > > + sizeof (struct main_type)); > > IMHO this should be written as an assignment. I think it's equally clear this way... -- Daniel Jacobowitz CodeSourcery