From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20530 invoked by alias); 24 Oct 2007 14:26:45 -0000 Received: (qmail 20520 invoked by uid 22791); 24 Oct 2007 14:26:45 -0000 X-Spam-Check-By: sourceware.org Received: from mail.artimi.com (HELO mail.artimi.com) (194.72.81.2) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 24 Oct 2007 14:26:40 +0000 Received: from rainbow ([192.168.8.46]) by mail.artimi.com with Microsoft SMTPSVC(6.0.3790.3959); Wed, 24 Oct 2007 15:26:37 +0100 From: "Dave Korn" To: "'Daniel Jacobowitz'" , "'Anitha Boyapati'" Cc: References: <20071024115310.GA19251@caradoc.them.org> <20071024123559.GA21751@caradoc.them.org> Subject: RE: conditional breakpoints for strings Date: Wed, 24 Oct 2007 14:26:00 -0000 Message-ID: <026f01c81649$e2cdc920$2e08a8c0@CAM.ARTIMI.COM> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <20071024123559.GA21751@caradoc.them.org> 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: 2007-10/txt/msg00200.txt.bz2 On 24 October 2007 13:36, Daniel Jacobowitz wrote: >> This is quite interesting. Maybe I would just look into its internals. >> Generally speaking, why is this char*->string so hard ? > > Two parts. One is that GDB does not know how to construct new > objects. The other is that figuring out which constructors or > operators to call is complicated; do you convert std::string to > char * or char * to std::string, for instance. The C++ language > standard has pages and pages of rules for this sort of thing. We probably want to get the compiler to do it for us then. LTO might well make this almost trivial, when it's ready. cheers, DaveK -- Can't think of a witty .sigline today....