From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id EFKoCX3Ps2F7ZAAAWB0awg (envelope-from ) for ; Fri, 10 Dec 2021 17:06:53 -0500 Received: by simark.ca (Postfix, from userid 112) id 24E271F0D0; Fri, 10 Dec 2021 17:06:53 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, NICE_REPLY_A,RDNS_DYNAMIC autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (ip-8-43-85-97.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 8E95B1ECEB for ; Fri, 10 Dec 2021 17:06:52 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 762D93857C7F for ; Fri, 10 Dec 2021 22:06:51 +0000 (GMT) Received: from mail-wr1-f42.google.com (mail-wr1-f42.google.com [209.85.221.42]) by sourceware.org (Postfix) with ESMTPS id CA1FE3858D3C for ; Fri, 10 Dec 2021 22:06:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org CA1FE3858D3C Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=palves.net Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-wr1-f42.google.com with SMTP id o13so17180549wrs.12 for ; Fri, 10 Dec 2021 14:06:40 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:in-reply-to :content-transfer-encoding; bh=AW0x32Tud4tVxNkk6hBTkUox31JjI7U5MNp/gunO+lY=; b=EoUggiCT2X69T5BUNHtzlvvBrwwjy2ILlohftbN36UbWrK8InNWegBhEvDhIm0CQch 1l5kQOtJDhfD57egGSG5n51Sa8MWssHB42oFTRaW+16NCuAEDEdwm05tulMqQd5ORSO1 KgWgWJaMWC2VUMQSpWzxuuXLTKjBD2Ov2KAW++to+pUvdIxf+5WcrvwXjRY+zQcgN9LA WJKSWsPhWGokwfertxoxtpVyrUy2nMncFkF41ACgt7Oewsa7/8Dkab8w55p9UMshS8RI P2NO0/OygRQbuEhtG2FVW8x9xfmqXNeL7VB3eei7Y0kErbfOO+AoQufrNj/25unLK77Y b7nw== X-Gm-Message-State: AOAM532qaV+Ij2lc28C7ICt/Jw3rc02D2SlwSab/4cBvYbpFYgy3ah2B BreYp+7nXxRv5PgoXqsrKrkGqvlinE4= X-Google-Smtp-Source: ABdhPJzcULZRG9DWqOsYptVSnlnk4UIdrBN7CTGvSPX2MHUE+DKl3YG2pciIzYQk48yq5/EWDBLZig== X-Received: by 2002:a5d:680b:: with SMTP id w11mr16912944wru.345.1639173999875; Fri, 10 Dec 2021 14:06:39 -0800 (PST) Received: from ?IPV6:2001:8a0:f912:1a00:d3db:ac91:4b9e:1449? ([2001:8a0:f912:1a00:d3db:ac91:4b9e:1449]) by smtp.gmail.com with ESMTPSA id bg12sm21083wmb.5.2021.12.10.14.06.38 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 10 Dec 2021 14:06:38 -0800 (PST) Message-ID: <1e3bc3bb-9e6a-e6e8-11fa-73719977ba47@palves.net> Date: Fri, 10 Dec 2021 22:06:37 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.3.2 Subject: Re: [PATCH 02/29] gdb/testsuite: Remove duplicates from gdb.base/miscexprs.exp Content-Language: en-US To: Lancelot SIX , gdb-patches@sourceware.org References: <20211121175636.779325-1-lsix@lancelotsix.com> <20211121175636.779325-3-lsix@lancelotsix.com> From: Pedro Alves In-Reply-To: <20211121175636.779325-3-lsix@lancelotsix.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" On 2021-11-21 17:56, Lancelot SIX via Gdb-patches wrote: > When running the testsuite I see: > > Running .../gdb/testsuite/gdb.base/miscexprs.exp ... > DUPLICATE: gdb.base/miscexprs.exp: print value of !ibig.i[100] > DUPLICATE: gdb.base/miscexprs.exp: print value of !ibig.i[100] > > Fix the name of some misnamed tests. > > Tested on x86_64. > --- > gdb/testsuite/gdb.base/miscexprs.exp | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/gdb/testsuite/gdb.base/miscexprs.exp b/gdb/testsuite/gdb.base/miscexprs.exp > index 86f41215283..c1fc7420545 100644 > --- a/gdb/testsuite/gdb.base/miscexprs.exp > +++ b/gdb/testsuite/gdb.base/miscexprs.exp > @@ -118,10 +118,10 @@ gdb_test "print !sbig.s\[90\]" " = $false" \ > "print value of !sbig.s\[90\]" > > gdb_test "print !fbig.f\[100\]" " = $false" \ > - "print value of !ibig.i\[100\]" > + "print value of !fbig.f\[100\]" > > gdb_test "print !dbig.d\[202\]" " = $false" \ > - "print value of !ibig.i\[100\]" > + "print value of !dbig.d\[202\]" > > gdb_test "print sbig.s\[90\] * 10" " = 2550" \ > "print value of !sbig.s\[90\] * 10" > Can you just drop the explicit names instead? That's the actual problem, the duplication, and us humans failing at it. Removing the duplication nips the problem in the bud, so it doesn't ever happen again if someone adds more tests. So we'd just have: gdb_test "print sbig.s\[90\] * 10" " = 2550" etc. We lose the "value of" part but that seems harmless.