From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8937 invoked by alias); 11 Jul 2006 20:33:32 -0000 Received: (qmail 8928 invoked by uid 22791); 11 Jul 2006 20:33:32 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Tue, 11 Jul 2006 20:33:30 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1G0OvA-00080k-8w for gdb-patches@sourceware.org; Tue, 11 Jul 2006 16:33:28 -0400 Date: Tue, 11 Jul 2006 20:33:00 -0000 From: Daniel Jacobowitz To: gdb-patches@sourceware.org Subject: Re: [RFA] New substitute-path commands Message-ID: <20060711203328.GA30744@nevyn.them.org> Mail-Followup-To: gdb-patches@sourceware.org References: <20060705215606.GF3580@adacore.com> <20060705230129.GA1145@nevyn.them.org> <20060706044733.GC673@adacore.com> <1152198199.6282.63.camel@dufur.beaverton.ibm.com> <20060706162952.GB24631@nevyn.them.org> <20060707052219.GA971@adacore.com> <20060711124739.GA18324@nevyn.them.org> <20060711203042.GA1262@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20060711203042.GA1262@adacore.com> User-Agent: Mutt/1.5.11+cvs20060403 X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-07/txt/msg00094.txt.bz2 On Tue, Jul 11, 2006 at 01:30:42PM -0700, Joel Brobecker wrote: > (1): Anchoring means that we replace from the start right, so > no search within the path, just a strncmp, correct? > > It might be simpler, but on the other hand less flexible. > I would personally prefer to have it non anchored, but > it's only a mild preference and I don't know of any > situation where having the replacement rule anchored > would cause us any problem in practice. > > (2): I am personally not against this, and it would fit what > we would do at AdaCore, but I don't see this as a necessary > constraint that the debugger should check. Again, a mild > preference. > > What do others think? I'm happy to implement whatever the group > thinks is best. The reason for anchoring is to reduce surprising behavior. Especially since this only replaces one occurance, it seems like the path of least astonishment. For instance, "substitute-path foo bar" would replace /fool with /barl and /tmp/myfoo with /tmp/mybar. I'd much prefer (1); I'm ambivalent on (2); whatever anyone prefers is fine. -- Daniel Jacobowitz CodeSourcery