From patchwork Thu Jul 19 14:54:21 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 28483 Received: (qmail 58432 invoked by alias); 19 Jul 2018 14:55:04 -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 58412 invoked by uid 89); 19 Jul 2018 14:55:03 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.4 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.2 spammy=utils.c, UD:utils.c, utilsc X-HELO: gateway21.websitewelcome.com Received: from gateway21.websitewelcome.com (HELO gateway21.websitewelcome.com) (192.185.45.133) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 19 Jul 2018 14:55:01 +0000 Received: from cm15.websitewelcome.com (cm15.websitewelcome.com [100.42.49.9]) by gateway21.websitewelcome.com (Postfix) with ESMTP id 159F6400ED3C9 for ; Thu, 19 Jul 2018 09:55:00 -0500 (CDT) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with SMTP id gAK4fgSzkbXuJgAKNfo1OU; Thu, 19 Jul 2018 09:54:59 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=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: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=WzIDzlH98mXgLWV58a8Bq8ZdY/KYzJoMZnzoW/O4Slc=; b=Z5T3sWQAH0P60+DyvQbw165lmD 68dLJAgfxjBLlW7Tu9kzcFDSYDQE5Z89S1Pg6mHHN2ZQKCi0ud3Bmtk6MZgx+ujMYZgUax/X7Y2zV Hud0quAZcoZkVVhWuGidcQl6j; Received: from 75-166-85-72.hlrn.qwest.net ([75.166.85.72]:51774 helo=pokyo.Home) by box5379.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.91) (envelope-from ) id 1fgAK4-001V3k-90; Thu, 19 Jul 2018 09:54:28 -0500 From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [FYI] Remove make_cleanup_value_free_to_mark Date: Thu, 19 Jul 2018 08:54:21 -0600 Message-Id: <20180719145421.31242-1-tom@tromey.com> Pedro's patch to introduce gdbscm_wrap removed the last caller of make_cleanup_value_free_to_mark. This patch removes this function. I'm checking this in as obvious. Tested by rebuilding, and by grepping. gdb/ChangeLog 2018-07-19 Tom Tromey * utils.c (do_value_free_to_mark) (make_cleanup_value_free_to_mark): Remove. * utils.h (make_cleanup_value_free_to_mark): Remove. --- gdb/ChangeLog | 6 ++++++ gdb/utils.c | 17 ----------------- gdb/utils.h | 4 ---- 3 files changed, 6 insertions(+), 21 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index c28b24053ca..7f254b9ae82 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2018-07-19 Tom Tromey + + * utils.c (do_value_free_to_mark) + (make_cleanup_value_free_to_mark): Remove. + * utils.h (make_cleanup_value_free_to_mark): Remove. + 2018-07-19 Pedro Alves * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a diff --git a/gdb/utils.c b/gdb/utils.c index 09381d9092d..bfcb45bc950 100644 --- a/gdb/utils.c +++ b/gdb/utils.c @@ -141,23 +141,6 @@ show_pagination_enabled (struct ui_file *file, int from_tty, because while they use the "cleanup API" they are not part of the "cleanup API". */ -/* Helper for make_cleanup_value_free_to_mark. */ - -static void -do_value_free_to_mark (void *value) -{ - value_free_to_mark ((struct value *) value); -} - -/* Free all values allocated since MARK was obtained by value_mark - (except for those released) when the cleanup is run. */ - -struct cleanup * -make_cleanup_value_free_to_mark (struct value *mark) -{ - return make_cleanup (do_value_free_to_mark, mark); -} - /* This function is useful for cleanups. Do diff --git a/gdb/utils.h b/gdb/utils.h index c728449429e..68523994b94 100644 --- a/gdb/utils.h +++ b/gdb/utils.h @@ -248,10 +248,6 @@ private: /* Cleanup utilities. */ -/* For make_cleanup_close see common/filestuff.h. */ - -extern struct cleanup *make_cleanup_value_free_to_mark (struct value *); - /* A deleter for a hash table. */ struct htab_deleter {