From patchwork Tue Apr 8 06:05:06 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yao Qi X-Patchwork-Id: 425 Return-Path: X-Original-To: siddhesh@wilcox.dreamhost.com Delivered-To: siddhesh@wilcox.dreamhost.com Received: from homiemail-mx22.g.dreamhost.com (mx2.sub5.homie.mail.dreamhost.com [208.113.200.128]) by wilcox.dreamhost.com (Postfix) with ESMTP id C07B336007D for ; Mon, 7 Apr 2014 23:07:48 -0700 (PDT) Received: by homiemail-mx22.g.dreamhost.com (Postfix, from userid 14314964) id 611B946A2966; Mon, 7 Apr 2014 23:07:48 -0700 (PDT) X-Original-To: gdb@patchwork.siddhesh.in Delivered-To: x14314964@homiemail-mx22.g.dreamhost.com Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by homiemail-mx22.g.dreamhost.com (Postfix) with ESMTPS id 3934A46A2948 for ; Mon, 7 Apr 2014 23:07:48 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:cc :subject:references:in-reply-to:content-type :content-transfer-encoding; q=dns; s=default; b=UkjSoKuxqs1+0Inq FNokHiHqikE2ix4JXP19GXH/8pyMcBC006IY63uCJQaNgVBQTTlcyl4zMKBQYYgk HbrGOu7oFGBtdw/1uRWZUl4fCsk2mQWMuJACEOnbYmOSRli/MivazWeHy+6v4GJc zZH3N13vndWN+lul+BFk2ZXp+jI= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:cc :subject:references:in-reply-to:content-type :content-transfer-encoding; s=default; bh=kyAAMAunxzyzO7jophZWTd Pi2uw=; b=uj6eu4GBW7K2jEUPSWLnUXaosYYqP2ImjbL3xp8vrQbaTwqtQMHk/O pyWChJiesTZQ4T3fGDxrRr9JrRAne4CjhQlUFQevKSiyhsvE9IAj2EoB3mbOMU7t 5ecd8dZyA8PvI1QZvsqchn34GxRv7mjp7xNw7U/MTsE2qTlo2luU4= Received: (qmail 18612 invoked by alias); 8 Apr 2014 06:07:46 -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 18600 invoked by uid 89); 8 Apr 2014 06:07:45 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL, BAYES_00 autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 08 Apr 2014 06:07:44 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1WXPC7-0007kX-Ep from Yao_Qi@mentor.com ; Mon, 07 Apr 2014 23:07:39 -0700 Received: from SVR-ORW-FEM-06.mgc.mentorg.com ([147.34.97.120]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Mon, 7 Apr 2014 23:07:39 -0700 Received: from qiyao.dyndns.org (147.34.91.1) by SVR-ORW-FEM-06.mgc.mentorg.com (147.34.97.120) with Microsoft SMTP Server id 14.2.247.3; Mon, 7 Apr 2014 23:07:38 -0700 Message-ID: <53439192.9040801@codesourcery.com> Date: Tue, 8 Apr 2014 14:05:06 +0800 From: Yao Qi User-Agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: Joel Brobecker CC: Subject: Re: [PATCH] [testsuite] Disable Ctrl-V use for mingw hosts. References: <1395712934-29531-1-git-send-email-yao@codesourcery.com> <533A2362.3030405@codesourcery.com> <20140407163922.GB4250@adacore.com> In-Reply-To: <20140407163922.GB4250@adacore.com> X-IsSubscribed: yes X-DH-Original-To: gdb@patchwork.siddhesh.in On 04/08/2014 12:39 AM, Joel Brobecker wrote: > Sorry about the wait. OK, but with a small change in the comment > to say that the ctrl-v character is not only unnecessary on MinGW > but actually harmful for the test because that character isn't > recognized as an escape character. OK, comments are updated. Patch below is pushed in. > > It'd be nice to know when @ is actually an escape character (just > thinking out loud, not asking you to do the research - a google > research doesn't quite clarify this for me). I don't know either. diff --git a/gdb/testsuite/gdb.base/printcmds.exp b/gdb/testsuite/gdb.base/printcmds.exp index 8f38aca..3253d91 100644 --- a/gdb/testsuite/gdb.base/printcmds.exp +++ b/gdb/testsuite/gdb.base/printcmds.exp @@ -631,8 +631,16 @@ proc test_print_typedef_arrays {} { proc test_artificial_arrays {} { # Send \026@ instead of just @ in case the kill character is @. - gdb_test_escape_braces "p int1dim\[0\]\026@2" " = {0, 1}" {p int1dim[0]@2} - gdb_test_escape_braces "p int1dim\[0\]\026@2\026@3" \ + # \026 (ctrl-v) is to escape the next character (@), but it is + # not only unnecessary to do so on MingW hosts, but also harmful + # for the test because that character isn't recognized as an + # escape character. + set ctrlv "\026" + if [ishost *-*-mingw*] { + set ctrlv "" + } + gdb_test_escape_braces "p int1dim\[0\]${ctrlv}@2" " = {0, 1}" {p int1dim[0]@2} + gdb_test_escape_braces "p int1dim\[0\]${ctrlv}@2${ctrlv}@3" \ "({{0, 1}, {2, 3}, {4, 5}}|\[Cc\]annot.*)" \ {p int1dim[0]@2@3} gdb_test_escape_braces {p/x (short [])0x12345678} \