From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 553 invoked by alias); 17 Feb 2008 00:19:47 -0000 Received: (qmail 544 invoked by uid 22791); 17 Feb 2008 00:19:47 -0000 X-Spam-Check-By: sourceware.org Received: from viper.snap.net.nz (HELO viper.snap.net.nz) (202.37.101.8) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sun, 17 Feb 2008 00:19:20 +0000 Received: from kahikatea.snap.net.nz (207.31.255.123.static.snap.net.nz [123.255.31.207]) by viper.snap.net.nz (Postfix) with ESMTP id 4055C3DA64A; Sun, 17 Feb 2008 13:19:17 +1300 (NZDT) Received: by kahikatea.snap.net.nz (Postfix, from userid 1000) id 1BA6A8FC6D; Sun, 17 Feb 2008 13:19:14 +1300 (NZDT) From: Nick Roberts MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <18359.32130.501577.586179@kahikatea.snap.net.nz> Date: Sun, 17 Feb 2008 00:19:00 -0000 To: Daniel Jacobowitz , Vladimir Prus , gdb@sources.redhat.com Subject: Re: Variable objects and STL containers In-Reply-To: <18357.23056.842755.97621@kahikatea.snap.net.nz> References: <18343.64413.689019.489727@kahikatea.snap.net.nz> <18344.836.184542.934917@kahikatea.snap.net.nz> <20080205131634.GA10652@caradoc.them.org> <18357.23056.842755.97621@kahikatea.snap.net.nz> X-Mailer: VM 7.19 under Emacs 22.1.90.2 X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-02/txt/msg00112.txt.bz2 > Creating variable objects using internals wasn't so hard for vectors but > it gets a bit more tricky with lists. Actually it looks doable for lists, maps etc if the children of a variable object were stored as a list rather than a vector. This is so that a new child can be added, or an old one deleted, at any point in the list. Ironically, the children were previously stored in a linked list and I guess vectors were used because Nathan Sidwell has created an API in C for them. There doesn't appear to be a similar API for lists, but since they are more flexible, would it be possible to revert var->children to a linked list? -- Nick http://www.inet.net.nz/~nickrob