From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@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, 08 Apr 2014 06:07:00 -0000 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> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2014-04/txt/msg00092.txt.bz2 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. -- Yao (齐尧) gdb/testsuite: 2014-04-08 Pierre Muller * gdb.base/printcmds.exp (test_artificial_arrays): Disable Ctrl-V use for mingw hosts. --- gdb/testsuite/gdb.base/printcmds.exp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) 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} \ -- 1.8.1.4