From patchwork Thu Jan 12 03:00:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 63049 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 444FA3AA8C0A for ; Thu, 12 Jan 2023 03:06:47 +0000 (GMT) X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from alt-proxy28.mail.unifiedlayer.com (alt-proxy28.mail.unifiedlayer.com [74.220.216.123]) by sourceware.org (Postfix) with ESMTPS id 1E74838432E1 for ; Thu, 12 Jan 2023 03:01:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1E74838432E1 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tromey.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tromey.com Received: from cmgw11.mail.unifiedlayer.com (unknown [10.0.90.126]) by progateway1.mail.pro1.eigbox.com (Postfix) with ESMTP id 937541003F5E7 for ; Thu, 12 Jan 2023 03:01:50 +0000 (UTC) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTP id Fnqgp35DvFxgHFnqgpCH58; Thu, 12 Jan 2023 03:01:50 +0000 X-Authority-Reason: nr=8 X-Authority-Analysis: v=2.4 cv=ePfWMFl1 c=1 sm=1 tr=0 ts=63bf781e a=ApxJNpeYhEAb1aAlGBBbmA==:117 a=ApxJNpeYhEAb1aAlGBBbmA==:17 a=dLZJa+xiwSxG16/P+YVxDGlgEgI=:19 a=RvmDmJFTN0MA:10:nop_rcvd_month_year a=Qbun_eYptAEA:10:endurance_base64_authed_username_1 a=1u5DN_OqjYa4UBPCj6cA:9 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: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=4hmOIrChlCf7RD3jS3X2ElLZ/UMvGOimm+VhimHuMLo=; b=SRWOhLFeaUoVpJuM3uu5a1KBn+ I3iKuezhwFoaqunyDkP0AKJTtLWHi3v1A+9ff51F49HaKl/DBqtyuwIm9tGc4XvUiJLlb38Dt1hem 8lxezBxFjQF0hriBLDSMlyCw9; Received: from 97-122-76-186.hlrn.qwest.net ([97.122.76.186]:41092 helo=localhost.localdomain) by box5379.bluehost.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1pFnqg-000mJw-BU; Wed, 11 Jan 2023 20:01:50 -0700 From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [PATCH v2 73/79] Rename to allow_rust_tests Date: Wed, 11 Jan 2023 20:00:46 -0700 Message-Id: <20230112030052.3306113-74-tom@tromey.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230112030052.3306113-1-tom@tromey.com> References: <20230112030052.3306113-1-tom@tromey.com> MIME-Version: 1.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box5379.bluehost.com X-AntiAbuse: Original Domain - sourceware.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 97.122.76.186 X-Source-L: No X-Exim-ID: 1pFnqg-000mJw-BU X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 97-122-76-186.hlrn.qwest.net (localhost.localdomain) [97.122.76.186]:41092 X-Source-Auth: tom+tromey.com X-Email-Count: 74 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-Spam-Status: No, score=-3028.0 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, JMQ_SPF_NEUTRAL, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces+patchwork=sourceware.org@sourceware.org Sender: "Gdb-patches" This changes skip_rust_tests to invert the sense, and renames it to allow_rust_tests. --- gdb/testsuite/gdb.rust/dwindex.exp | 2 +- gdb/testsuite/gdb.rust/expr.exp | 2 +- gdb/testsuite/gdb.rust/fnfield.exp | 2 +- gdb/testsuite/gdb.rust/generics.exp | 2 +- gdb/testsuite/gdb.rust/methods.exp | 2 +- gdb/testsuite/gdb.rust/modules.exp | 2 +- gdb/testsuite/gdb.rust/pp.exp | 2 +- gdb/testsuite/gdb.rust/rawids.exp | 2 +- gdb/testsuite/gdb.rust/rust-style.exp | 2 +- gdb/testsuite/gdb.rust/simple.exp | 2 +- gdb/testsuite/gdb.rust/traits.exp | 2 +- gdb/testsuite/gdb.rust/unicode.exp | 2 +- gdb/testsuite/gdb.rust/union.exp | 2 +- gdb/testsuite/gdb.rust/unsized.exp | 2 +- gdb/testsuite/gdb.rust/watch.exp | 2 +- gdb/testsuite/lib/gdb.exp | 10 +++++----- 16 files changed, 20 insertions(+), 20 deletions(-) diff --git a/gdb/testsuite/gdb.rust/dwindex.exp b/gdb/testsuite/gdb.rust/dwindex.exp index a617457571f..841db216680 100644 --- a/gdb/testsuite/gdb.rust/dwindex.exp +++ b/gdb/testsuite/gdb.rust/dwindex.exp @@ -16,7 +16,7 @@ # Test that a rustc-produced .debug_aranges can be read. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs diff --git a/gdb/testsuite/gdb.rust/expr.exp b/gdb/testsuite/gdb.rust/expr.exp index 8fd6b23023f..4a0a48ade62 100644 --- a/gdb/testsuite/gdb.rust/expr.exp +++ b/gdb/testsuite/gdb.rust/expr.exp @@ -17,7 +17,7 @@ # Rust compiler. This serves as a smoke test. load_lib "rust-support.exp" -require !skip_rust_tests +require allow_rust_tests gdb_start diff --git a/gdb/testsuite/gdb.rust/fnfield.exp b/gdb/testsuite/gdb.rust/fnfield.exp index 2f6ddd74828..413104cca64 100644 --- a/gdb/testsuite/gdb.rust/fnfield.exp +++ b/gdb/testsuite/gdb.rust/fnfield.exp @@ -16,7 +16,7 @@ # Test trait object printing. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/generics.exp b/gdb/testsuite/gdb.rust/generics.exp index 5c0c105abe5..41112afd572 100644 --- a/gdb/testsuite/gdb.rust/generics.exp +++ b/gdb/testsuite/gdb.rust/generics.exp @@ -16,7 +16,7 @@ # Test expressions involving generics. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/methods.exp b/gdb/testsuite/gdb.rust/methods.exp index dfbebd6bc38..8374ab162ec 100644 --- a/gdb/testsuite/gdb.rust/methods.exp +++ b/gdb/testsuite/gdb.rust/methods.exp @@ -16,7 +16,7 @@ # Test method calls. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/modules.exp b/gdb/testsuite/gdb.rust/modules.exp index 9ab758b5d30..0ad1a4a6b75 100644 --- a/gdb/testsuite/gdb.rust/modules.exp +++ b/gdb/testsuite/gdb.rust/modules.exp @@ -16,7 +16,7 @@ # Test name lookup. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/pp.exp b/gdb/testsuite/gdb.rust/pp.exp index 28ae0545c5a..553bce3c1a9 100644 --- a/gdb/testsuite/gdb.rust/pp.exp +++ b/gdb/testsuite/gdb.rust/pp.exp @@ -17,7 +17,7 @@ load_lib gdb-python.exp load_lib rust-support.exp -require !skip_rust_tests allow_python_tests +require allow_rust_tests allow_python_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/rawids.exp b/gdb/testsuite/gdb.rust/rawids.exp index 234b4329f91..976b723833e 100644 --- a/gdb/testsuite/gdb.rust/rawids.exp +++ b/gdb/testsuite/gdb.rust/rawids.exp @@ -16,7 +16,7 @@ # Test raw identifiers. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests set v [split [rust_compiler_version] .] if {[lindex $v 0] == 1 && [lindex $v 1] < 30} { diff --git a/gdb/testsuite/gdb.rust/rust-style.exp b/gdb/testsuite/gdb.rust/rust-style.exp index ed76fbf9760..c942673bddb 100644 --- a/gdb/testsuite/gdb.rust/rust-style.exp +++ b/gdb/testsuite/gdb.rust/rust-style.exp @@ -16,7 +16,7 @@ # Test CLI output styling for Rust. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests save_vars { env(TERM) } { # We need an ANSI-capable terminal to get the output. diff --git a/gdb/testsuite/gdb.rust/simple.exp b/gdb/testsuite/gdb.rust/simple.exp index 5925a4cd12d..25152a35cd0 100644 --- a/gdb/testsuite/gdb.rust/simple.exp +++ b/gdb/testsuite/gdb.rust/simple.exp @@ -16,7 +16,7 @@ # Test expression parsing and evaluation that requires Rust compiler. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/traits.exp b/gdb/testsuite/gdb.rust/traits.exp index 63a6df451f8..9aa4cbfc75c 100644 --- a/gdb/testsuite/gdb.rust/traits.exp +++ b/gdb/testsuite/gdb.rust/traits.exp @@ -16,7 +16,7 @@ # Test trait object printing. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/unicode.exp b/gdb/testsuite/gdb.rust/unicode.exp index aa1ace0608a..2b4766b5553 100644 --- a/gdb/testsuite/gdb.rust/unicode.exp +++ b/gdb/testsuite/gdb.rust/unicode.exp @@ -16,7 +16,7 @@ # Test raw identifiers. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests # Non-ASCII identifiers were allowed starting in 1.53. set v [split [rust_compiler_version] .] diff --git a/gdb/testsuite/gdb.rust/union.exp b/gdb/testsuite/gdb.rust/union.exp index 28b787b38da..5f128c563a3 100644 --- a/gdb/testsuite/gdb.rust/union.exp +++ b/gdb/testsuite/gdb.rust/union.exp @@ -16,7 +16,7 @@ # Test of "union" for Rust. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/unsized.exp b/gdb/testsuite/gdb.rust/unsized.exp index ac46b2eefac..f81be8a3078 100644 --- a/gdb/testsuite/gdb.rust/unsized.exp +++ b/gdb/testsuite/gdb.rust/unsized.exp @@ -16,7 +16,7 @@ # Test expression parsing and evaluation that requires Rust compiler. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/gdb.rust/watch.exp b/gdb/testsuite/gdb.rust/watch.exp index 2c0e57db427..83cb41cc1eb 100644 --- a/gdb/testsuite/gdb.rust/watch.exp +++ b/gdb/testsuite/gdb.rust/watch.exp @@ -16,7 +16,7 @@ # Test watch -location with Rust. load_lib rust-support.exp -require !skip_rust_tests +require allow_rust_tests standard_testfile .rs if {[prepare_for_testing "failed to prepare" $testfile $srcfile {debug rust}]} { diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp index b6eff66f94d..9ce7c6b3aaf 100644 --- a/gdb/testsuite/lib/gdb.exp +++ b/gdb/testsuite/lib/gdb.exp @@ -2427,10 +2427,10 @@ proc allow_d_tests {} { return 1 } -# Return 1 to skip Rust tests, 0 to try them. -proc skip_rust_tests {} { +# Return 1 to try Rust tests, 0 to skip them. +proc allow_rust_tests {} { if { ![isnative] } { - return 1 + return 0 } # The rust compiler does not support "-m32", skip. @@ -2439,12 +2439,12 @@ proc skip_rust_tests {} { if {[board_info $board exists multilib_flags]} { foreach flag [board_info $board multilib_flags] { if { $flag == "-m32" } { - return 1 + return 0 } } } - return 0 + return 1 } # Return a 1 for configurations that support Python scripting.