From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1327 invoked by alias); 6 Feb 2008 02:48:17 -0000 Received: (qmail 1317 invoked by uid 22791); 6 Feb 2008 02:48:17 -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, 06 Feb 2008 02:47:51 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 38EA998100; Wed, 6 Feb 2008 02:47: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 1BBD1980E0; Wed, 6 Feb 2008 02:47:49 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.68) (envelope-from ) id 1JMaKB-0006VH-Hz; Tue, 05 Feb 2008 21:47:47 -0500 Date: Wed, 06 Feb 2008 02:48:00 -0000 From: Daniel Jacobowitz To: Joel Brobecker Cc: gdb-patches@sourceware.org Subject: Re: [RFA/commit/Ada] Replace home-made string_vector struct with VEC Message-ID: <20080206024747.GA24828@caradoc.them.org> Mail-Followup-To: Joel Brobecker , gdb-patches@sourceware.org References: <20071228122825.GC24450@adacore.com> <20080129172800.GA3773@caradoc.them.org> <20080204231510.GI21614@adacore.com> <20080204232951.GA31411@caradoc.them.org> <20080205223151.GA3727@adacore.com> <20080206015703.GA16367@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20080206015703.GA16367@adacore.com> User-Agent: Mutt/1.5.17 (2007-12-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-02/txt/msg00119.txt.bz2 On Tue, Feb 05, 2008 at 05:57:03PM -0800, Joel Brobecker wrote: > 1. Would it make sense to have standard VECs predefined somewhere? > For instance, I wonder how often a VEC of strings will be useful > in GDB... Sounds reasonable to me. > 2. Would it make sense to expand the VEC API to have a method > that will return a copy of the underlying array? After some > thoughts, and a look at the current usage, it seemed to me > that it didn't make much sense. I didn't see any other places > where we need to make that copy, and making that copy is > pretty simple. I agree. The memory allocation doesn't work out to make this advantageous. If we want to save the copy, allowing some other way to register a destructor for the array might do more good. Thanks! -- Daniel Jacobowitz CodeSourcery