From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 45791 invoked by alias); 16 Apr 2019 06:48:50 -0000 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 Received: (qmail 45780 invoked by uid 89); 16 Apr 2019 06:48:49 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-7.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.1 spammy=About, H*i:sk:0dd32af, H*f:sk:0dd32af X-HELO: mailsec105.isp.belgacom.be Received: from mailsec105.isp.belgacom.be (HELO mailsec105.isp.belgacom.be) (195.238.20.101) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 16 Apr 2019 06:48:46 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=skynet.be; i=@skynet.be; q=dns/txt; s=securemail; t=1555397326; x=1586933326; h=message-id:subject:from:to:date:in-reply-to:references: mime-version:content-transfer-encoding; bh=rzXtw3WrPrCWcPAVQxDtUZECYGVgUko8dL9tifL6NEM=; b=l02U3/lr9PTZpJSM6w7GU1Okv0tvssmMsBq9qDrA6uIVGYptFYg9954r VZwNPQUMPj3EOkFsg1bvR0+fTzJLnA==; Received: from 45.123-131-109.adsl-dyn.isp.belgacom.be (HELO md) ([109.131.123.45]) by relay.skynet.be with ESMTP/TLS/AES256-GCM-SHA384; 16 Apr 2019 08:48:43 +0200 Message-ID: <1555397322.1473.10.camel@skynet.be> Subject: Re: / (slash) command : fast way to temporarily change setting(s) to run a command From: Philippe Waroquiers To: Simon Marchi , gdb@sourceware.org Date: Tue, 16 Apr 2019 06:48:00 -0000 In-Reply-To: <0dd32aff-8b46-92c8-5761-6b4f72efbaf0@polymtl.ca> References: <1555313564.1473.2.camel@skynet.be> <0dd32aff-8b46-92c8-5761-6b4f72efbaf0@polymtl.ca> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2019-04/txt/msg00008.txt.bz2 On Mon, 2019-04-15 at 23:06 -0400, Simon Marchi wrote: > Hi Philippe, > > I like the idea, I would probably use it most with /e (for long strings) and /p. > I just tried it a little bit, and I appreciate the fact that it's easy to apply > to your previous command. Just type up and add the prefix to the beginning of the > line. Interesting, that was not the primary use case I was thinking to. We could make this even easier by making COMMAND optional in: Usage: /SETTING... [COMMAND] and giving no command means to repeat the previous command with the additional given settings e.g. : (gdb) some command .... some command output (gdb) /e => executes /e some command (gdb) /e some command ... some command output (gdb) /p => executes /ep some command I guess we probably call dont_repeat () in / command when no COMMAND is given. > > About that help, I would just add a few newlines here and there to space things > out and ease the reading. Other than that, it's quite clear. Ok, will add some new lines in the v2 of the patch. Thanks for the feedback Philippe