From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24630 invoked by alias); 14 Aug 2017 03:41: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 6070 invoked by uid 89); 14 Aug 2017 03:40:48 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-25.7 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: gproxy9-pub.mail.unifiedlayer.com Received: from gproxy9-pub.mail.unifiedlayer.com (HELO gproxy9-pub.mail.unifiedlayer.com) (69.89.20.122) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 14 Aug 2017 03:40:46 +0000 Received: from cmgw4 (unknown [10.0.90.85]) by gproxy9.mail.unifiedlayer.com (Postfix) with ESMTP id 63BC01E06C7 for ; Sun, 13 Aug 2017 21:40:45 -0600 (MDT) Received: from box522.bluehost.com ([74.220.219.122]) by cmgw4 with id wrgh1v00L2f2jeq01rgk3B; Sun, 13 Aug 2017 21:40:45 -0600 X-Authority-Analysis: v=2.2 cv=ELV26xRC c=1 sm=1 tr=0 a=GsOEXm/OWkKvwdLVJsfwcA==:117 a=GsOEXm/OWkKvwdLVJsfwcA==:17 a=KeKAF7QvOSUA:10 a=zstS-IiYAAAA:8 a=R2UQp1W6-Gx6124IX6oA:9 a=A9lhXlrJD-OPwzow:21 a=ucIoJXKIi0aYcehK:21 a=4G6NA9xxw8l3yy4pmD5M:22 Received: from 75-166-24-97.hlrn.qwest.net ([75.166.24.97]:55932 helo=bapiya.Home) by box522.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.87) (envelope-from ) id 1dh6F7-0025eE-Hh; Sun, 13 Aug 2017 21:40:41 -0600 From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [RFA v2 11/13] Improve "backtrace" help text Date: Mon, 14 Aug 2017 03:41:00 -0000 Message-Id: <20170814034030.20863-12-tom@tromey.com> In-Reply-To: <20170814034030.20863-1-tom@tromey.com> References: <20170814034030.20863-1-tom@tromey.com> X-BWhitelist: no X-Exim-ID: 1dh6F7-0025eE-Hh X-Source-Sender: 75-166-24-97.hlrn.qwest.net (bapiya.Home) [75.166.24.97]:55932 X-Source-Auth: tom+tromey.com X-Email-Count: 12 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTIyLmJsdWVob3N0LmNvbQ== X-Local-Domain: yes X-SW-Source: 2017-08/txt/msg00283.txt.bz2 This improves help text in stack.c in two ways. First, it removes trailing newlines from various help strings. I think these are never needed. Second, it adds a "Usage" line to the "backtrace" text, as suggested by Pedro. ChangeLog 2017-08-13 Tom Tromey * stack.c (_initialize_stack): Remove trailing newlines from help text. Add "Usage" line to "backtrace" help. --- gdb/ChangeLog | 5 +++++ gdb/stack.c | 13 +++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 9af53f8..84df331 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,10 @@ 2017-08-13 Tom Tromey + * stack.c (_initialize_stack): Remove trailing newlines from help + text. Add "Usage" line to "backtrace" help. + +2017-08-13 Tom Tromey + PR python/16486: * python/py-framefilter.c (py_print_args): Call wrap_hint. diff --git a/gdb/stack.c b/gdb/stack.c index 94f24b2..20cdd97 100644 --- a/gdb/stack.c +++ b/gdb/stack.c @@ -2585,22 +2585,23 @@ This is useful in command scripts.")); Select and print a stack frame.\nWith no argument, \ print the selected stack frame. (See also \"info frame\").\n\ An argument specifies the frame to select.\n\ -It can be a stack frame number or the address of the frame.\n")); +It can be a stack frame number or the address of the frame.")); add_com_alias ("f", "frame", class_stack, 1); add_com_suppress_notification ("select-frame", class_stack, select_frame_command, _("\ Select a stack frame without printing anything.\n\ An argument specifies the frame to select.\n\ -It can be a stack frame number or the address of the frame.\n"), +It can be a stack frame number or the address of the frame."), &cli_suppress_notification.user_selected_context); add_com ("backtrace", class_stack, backtrace_command, _("\ Print backtrace of all stack frames, or innermost COUNT frames.\n\ -With a negative argument, print outermost -COUNT frames.\nUse of the \ -'full' qualifier also prints the values of the local variables.\n\ +Usage: backtrace [QUALIFIERS]... [COUNT]\n\ +With a negative argument, print outermost -COUNT frames.\n\ +Use of the 'full' qualifier also prints the values of the local variables.\n\ Use of the 'no-filters' qualifier prohibits frame filters from executing\n\ -on this backtrace.\n")); +on this backtrace.")); add_com_alias ("bt", "backtrace", class_stack, 0); add_com_alias ("where", "backtrace", class_alias, 0); @@ -2618,7 +2619,7 @@ on this backtrace.\n")); if (dbx_commands) add_com ("func", class_stack, func_command, _("\ Select the stack frame that contains .\n\ -Usage: func \n")); +Usage: func ")); add_setshow_enum_cmd ("frame-arguments", class_stack, print_frame_arguments_choices, &print_frame_arguments, -- 2.9.4