From patchwork Sat Aug 3 13:29:22 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 33946 Received: (qmail 96284 invoked by alias); 3 Aug 2019 13:29:40 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 95651 invoked by uid 89); 3 Aug 2019 13:29:37 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-19.3 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS autolearn=ham version=3.3.1 spammy= X-HELO: gateway30.websitewelcome.com Received: from gateway30.websitewelcome.com (HELO gateway30.websitewelcome.com) (192.185.196.18) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 03 Aug 2019 13:29:35 +0000 Received: from cm11.websitewelcome.com (cm11.websitewelcome.com [100.42.49.5]) by gateway30.websitewelcome.com (Postfix) with ESMTP id 691DB6189 for ; Sat, 3 Aug 2019 08:29:34 -0500 (CDT) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with SMTP id tu6Ihg5KYdnCetu6Ih8XZ5; Sat, 03 Aug 2019 08:29:34 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: Sender:Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=svkFIrfkv133mNJWuAOusL0ULwQeb7nY28T5caJWmFU=; b=XU8kq2n/UCE/6ruOxF47ZCt6oW IPCQoYIbWRvZJ80oZWClZFDghMbaCRh27970kwupzgRO+wbx5v9Lv4qete/k5I1bqhVtenmJES7b4 Atw7DpBFgFFzS4AVGS+bwklxy; Received: from 97-122-178-82.hlrn.qwest.net ([97.122.178.82]:36980 helo=bapiya.Home) by box5379.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92) (envelope-from ) id 1htu6I-003nqS-4o; Sat, 03 Aug 2019 08:29:34 -0500 From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [PATCH 16/19] Remove tui_erase_exec_info_content Date: Sat, 3 Aug 2019 07:29:22 -0600 Message-Id: <20190803132925.25074-17-tom@tromey.com> In-Reply-To: <20190803132925.25074-1-tom@tromey.com> References: <20190803132925.25074-1-tom@tromey.com> One call to tui_erase_exec_info_content can be removed. This call is not needed because the function in question then immediately sets the execution info window contents. Once this is done, tui_clear_exec_info_content is just a wrapper for the only call to tui_erase_exec_info_content, so tui_erase_exec_info_content can be renamed and the wrapper function removed. gdb/ChangeLog 2019-08-03 Tom Tromey * tui/tui-winsource.h (tui_erase_exec_info_content): Don't declare. * tui/tui-winsource.c (tui_source_window_base::refresh_all): Don't call tui_erase_exec_info_content. (tui_clear_exec_info_content): Rename from tui_erase_exec_info_content. (tui_clear_exec_info_content): Delete. --- gdb/ChangeLog | 10 ++++++++++ gdb/tui/tui-winsource.c | 9 +-------- gdb/tui/tui-winsource.h | 1 - 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/gdb/tui/tui-winsource.c b/gdb/tui/tui-winsource.c index c99e207b011..ed2af064c47 100644 --- a/gdb/tui/tui-winsource.c +++ b/gdb/tui/tui-winsource.c @@ -334,7 +334,6 @@ tui_source_window_base::refresh_all () { show_source_content (); check_and_display_highlight_if_needed (); - tui_erase_exec_info_content (this); update_exec_info (); } @@ -657,7 +656,7 @@ tui_source_window_base::show_exec_info_content () void -tui_erase_exec_info_content (struct tui_source_window_base *win_info) +tui_clear_exec_info_content (struct tui_source_window_base *win_info) { struct tui_gen_win_info *exec_info = win_info->execution_info; @@ -665,12 +664,6 @@ tui_erase_exec_info_content (struct tui_source_window_base *win_info) exec_info->refresh_window (); } -void -tui_clear_exec_info_content (struct tui_source_window_base *win_info) -{ - tui_erase_exec_info_content (win_info); -} - /* Function to update the execution info window. */ void tui_source_window_base::update_exec_info () diff --git a/gdb/tui/tui-winsource.h b/gdb/tui/tui-winsource.h index c902ee0f17e..d8a84b01846 100644 --- a/gdb/tui/tui-winsource.h +++ b/gdb/tui/tui-winsource.h @@ -188,7 +188,6 @@ extern void tui_update_source_windows_with_line (struct symtab *, int); extern void tui_clear_source_content (struct tui_source_window_base *); extern void tui_erase_source_content (struct tui_source_window_base *); -extern void tui_erase_exec_info_content (struct tui_source_window_base *); extern void tui_clear_exec_info_content (struct tui_source_window_base *); extern void tui_alloc_source_buffer (struct tui_source_window_base *);