From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15144 invoked by alias); 25 May 2018 17:31:26 -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 15118 invoked by uid 89); 25 May 2018 17:31:26 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy= X-HELO: gateway30.websitewelcome.com Received: from gateway30.websitewelcome.com (HELO gateway30.websitewelcome.com) (192.185.198.26) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 25 May 2018 17:31:25 +0000 Received: from cm10.websitewelcome.com (cm10.websitewelcome.com [100.42.49.4]) by gateway30.websitewelcome.com (Postfix) with ESMTP id 97757290B3 for ; Fri, 25 May 2018 12:31:23 -0500 (CDT) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with SMTP id MGYlfe9T3BcCXMGYlfXwDr; Fri, 25 May 2018 12:31:23 -0500 X-Authority-Reason: nr=8 Received: from 174-29-44-154.hlrn.qwest.net ([174.29.44.154]:48142 helo=pokyo) by box5379.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.91) (envelope-from ) id 1fMGYl-000mCA-D2; Fri, 25 May 2018 12:31:23 -0500 From: Tom Tromey To: Tom Tromey Cc: gdb-patches@sourceware.org Subject: Re: [RFA] Fix "set" handling of Python parameters References: <20180426225140.18640-1-tom@tromey.com> Date: Fri, 25 May 2018 17:34:00 -0000 In-Reply-To: <20180426225140.18640-1-tom@tromey.com> (Tom Tromey's message of "Thu, 26 Apr 2018 16:51:40 -0600") Message-ID: <87603bej6d.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-BWhitelist: no X-Source-L: No X-Exim-ID: 1fMGYl-000mCA-D2 X-Source-Sender: 174-29-44-154.hlrn.qwest.net (pokyo) [174.29.44.154]:48142 X-Source-Auth: tom+tromey.com X-Email-Count: 5 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-SW-Source: 2018-05/txt/msg00686.txt.bz2 >>>>> "Tom" == Tom Tromey writes: Tom> It's long bothered me that setting a Python parameter from the CLI Tom> will print the "set" help text by default. I think usually "set" Tom> commands should be silent. And, while you can modify this behavior a Tom> bit by providing a "get_set_string" method, if this method returns an Tom> empty string, a blank line will be printed. Tom> This patch removes the "help" behavior and changes the get_set_string Tom> behavior to avoid printing a blank line. The code has a comment about Tom> preserving API behavior, but I don't think this is truly important; Tom> and in any case the workaround -- implementing get_set_string -- is Tom> trivial. Tom> Regression tested on x86-64 Fedora 26. Ping. Tom