From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id leVyKBJT0l8SRQAAWB0awg (envelope-from ) for ; Thu, 10 Dec 2020 11:55:46 -0500 Received: by simark.ca (Postfix, from userid 112) id 9886E1F0A9; Thu, 10 Dec 2020 11:55:46 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=0.3 required=5.0 tests=MAILING_LIST_MULTI,RDNS_NONE, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.2 Received: from sourceware.org (unknown [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 34CA61E552 for ; Thu, 10 Dec 2020 11:55:46 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id BA1E03844046; Thu, 10 Dec 2020 16:55:45 +0000 (GMT) Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by sourceware.org (Postfix) with ESMTPS id AA0033844046 for ; Thu, 10 Dec 2020 16:55:43 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org AA0033844046 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tdevries@suse.de X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id CD9BAAC6A; Thu, 10 Dec 2020 16:55:42 +0000 (UTC) Date: Thu, 10 Dec 2020 17:55:41 +0100 From: Tom de Vries To: gdb-patches@sourceware.org Subject: [PATCH][gdb/testsuite] Fix gdb.tui/new-layout.exp with tcl 8.5 Message-ID: <20201210165539.GA19956@delia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) 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: , Cc: Tom Tromey Errors-To: gdb-patches-bounces@sourceware.org Sender: "Gdb-patches" Hi, In commit 4d91ddd342 "[gdb/testsuite] Fix unbalanced braces in gdb.tui/new-layout.exp", I tried to fix a problem with test-case gdb.tui/new-layout.exp when running with tcl 8.5. However, at that point I only had access to the log containing the failure, and unfortunately my patch turned out not to be effective. So, finally fix this problem by guarding the problematic code with: ... if { [tcl_version_at_least 8 6] } { ... } ... Tested on x86_64-linux, specifically SLE-11 where I ran into the failure. Any comments? Thanks, - Tom [gdb/testsuite] Fix gdb.tui/new-layout.exp with tcl 8.5 gdb/testsuite/ChangeLog: 2020-12-10 Tom de Vries PR testsuite/26947 * gdb.tui/new-layout.exp: Don't execute tests with unbalanced curly braces for tcl 8.5 and earlier. --- gdb/testsuite/gdb.tui/new-layout.exp | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/gdb/testsuite/gdb.tui/new-layout.exp b/gdb/testsuite/gdb.tui/new-layout.exp index d736e7f42f..cd9b15bcd9 100644 --- a/gdb/testsuite/gdb.tui/new-layout.exp +++ b/gdb/testsuite/gdb.tui/new-layout.exp @@ -44,12 +44,16 @@ gdb_test "tui new-layout example src 1 src 1" \ "Window \"src\" seen twice in layout" gdb_test "tui new-layout example src 1" \ "New layout does not contain the \"cmd\" window" -gdb_test "tui new-layout example src 1\}" \ - "Extra '\}' in layout specification" -gdb_test "tui new-layout example {src 1} 1\}" \ - "Extra '\}' in layout specification" -gdb_test "tui new-layout example \{src 1" \ - "Missing '\}' in layout specification" + +# Avoid unbalanced curly braces problems with tcl 8.5. +if { [tcl_version_at_least 8 6] } { + gdb_test "tui new-layout example src 1\}" \ + "Extra '\}' in layout specification" + gdb_test "tui new-layout example {src 1} 1\}" \ + "Extra '\}' in layout specification" + gdb_test "tui new-layout example \{src 1" \ + "Missing '\}' in layout specification" +} gdb_test_no_output "tui new-layout example asm 1 status 0 cmd 1"