From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 103783 invoked by alias); 22 Jun 2019 11:48:24 -0000 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 Received: (qmail 103762 invoked by uid 89); 22 Jun 2019 11:48:23 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=voice, hmm, changeable, online X-HELO: mail-wm1-f66.google.com Received: from mail-wm1-f66.google.com (HELO mail-wm1-f66.google.com) (209.85.128.66) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 22 Jun 2019 11:48:22 +0000 Received: by mail-wm1-f66.google.com with SMTP id x15so8511914wmj.3 for ; Sat, 22 Jun 2019 04:48:22 -0700 (PDT) Return-Path: Received: from ?IPv6:2001:8a0:f913:f700:4c97:6d52:2cea:997b? ([2001:8a0:f913:f700:4c97:6d52:2cea:997b]) by smtp.gmail.com with ESMTPSA id l8sm11101775wrg.40.2019.06.22.04.48.19 (version=TLS1_3 cipher=AEAD-AES128-GCM-SHA256 bits=128/128); Sat, 22 Jun 2019 04:48:19 -0700 (PDT) Subject: Re: [PATCH v2.1] Introduce the "with" command To: Philippe Waroquiers , Eli Zaretskii References: <20190618003902.19805-1-palves@redhat.com> <20190618003902.19805-5-palves@redhat.com> <83sgs6sv44.fsf@gnu.org> <3e69e8c9-9025-90ec-e6f6-73e04bd22360@redhat.com> <83lfxxqzy5.fsf@gnu.org> <918fb7a7-4c62-68cd-006a-8d213b26d571@redhat.com> <1561199437.1556.1.camel@skynet.be> Cc: gdb-patches@sourceware.org From: Pedro Alves Message-ID: Date: Sat, 22 Jun 2019 11:48:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: <1561199437.1556.1.camel@skynet.be> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-SW-Source: 2019-06/txt/msg00454.txt.bz2 On 6/22/19 11:30 AM, Philippe Waroquiers wrote: > On Wed, 2019-06-19 at 18:20 +0100, Pedro Alves wrote: >> Here's the updated full patch that incorporates the changes addressing >> both Eli's and Philippe's comments. > I quickly re-read the patch and did some trials. > Thanks! > Two small remarks: > * The tests related to "maint with" are failing. > It looks like this patch misses the change > "maint test-settings" to "maint set|show test-settings". Hmm, with.exp and settings.exp both pass for me. Could you try the users/palves/cli-options branch? It contains the latest version, including the change below. > * Maybe it would be worth expanding slightly the on-line help? > What about: > > (gdb) help with > Temporarily set SETTING to VALUE, run COMMAND, and restore SETTING. > Usage: with SETTING [VALUE] [-- COMMAND] > Usage: w SETTING [VALUE] [-- COMMAND] > With no COMMAND, repeats the last executed command. > > SETTING is any setting you can change with the "set" subcommands. > Examples: >   with language pascal -- print obj >   with print elements unlimited -- print obj >    > Multiple settings can be changed using nested with, and abbreviations > can be used for commands and/or values. > Example: >   w la p -- w p el u -- p obj > (gdb)  Sounds good to me, with a change to switch to active voice, to go with the "changeable" -> "you can change" tweak in the previous round. Like: (gdb) help with Temporarily set SETTING to VALUE, run COMMAND, and restore SETTING. Usage: with SETTING [VALUE] [-- COMMAND] Usage: w SETTING [VALUE] [-- COMMAND] With no COMMAND, repeats the last executed command. SETTING is any setting you can change with the "set" subcommands. E.g.: with language pascal -- print obj with print elements unlimited -- print obj You can change multiple settings using nested with, and use abbreviations for commands and/or values. E.g.: w la p -- w p el u -- p obj (gdb) WDYT? Thanks, Pedro Alves