From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31392 invoked by alias); 16 Feb 2011 12:19:29 -0000 Received: (qmail 31336 invoked by uid 22791); 16 Feb 2011 12:19:20 -0000 X-SWARE-Spam-Status: No, hits=-1.5 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mtagate2.uk.ibm.com (HELO mtagate2.uk.ibm.com) (194.196.100.162) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 16 Feb 2011 12:19:16 +0000 Received: from d06nrmr1507.portsmouth.uk.ibm.com (d06nrmr1507.portsmouth.uk.ibm.com [9.149.38.233]) by mtagate2.uk.ibm.com (8.13.1/8.13.1) with ESMTP id p1GCJCl5019171 for ; Wed, 16 Feb 2011 12:19:12 GMT Received: from d06av04.portsmouth.uk.ibm.com (d06av04.portsmouth.uk.ibm.com [9.149.37.216]) by d06nrmr1507.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p1GCJIYR1810558 for ; Wed, 16 Feb 2011 12:19:18 GMT Received: from d06av04.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av04.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p1GCJCGK031853 for ; Wed, 16 Feb 2011 05:19:12 -0700 Received: from leonard.localnet (dyn-9-152-224-51.boeblingen.de.ibm.com [9.152.224.51]) by d06av04.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id p1GCJBhd031843 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 16 Feb 2011 05:19:12 -0700 From: Ken Werner To: Andreas Schwab , Jan Kratochvil Subject: Re: [patch] OpenCL datatypes test fixes Date: Wed, 16 Feb 2011 13:03:00 -0000 User-Agent: KMail/1.13.5 (Linux/2.6.35-25-generic-pae; KDE/4.5.1; i686; ; ) Cc: "Ulrich Weigand" , gdb-patches@sourceware.org References: <201102152101.p1FL1tt5009248@d06av02.portsmouth.uk.ibm.com> <201102161108.54061.ken@linux.vnet.ibm.com> In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201102161319.11247.ken@linux.vnet.ibm.com> X-IsSubscribed: yes 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 X-SW-Source: 2011-02/txt/msg00365.txt.bz2 On Wednesday, February 16, 2011 11:24:21 am Andreas Schwab wrote: > Ken Werner writes: > > On Tuesday, February 15, 2011 10:01:55 pm Ulrich Weigand wrote: > >> Ken Werner wrote: > >> > -gdb_test "whatis c2" "type = char \\\[2\\\]" > >> > +gdb_test "whatis c2" "type = char2|char \\\[2\\\]" > >> > >> Don't we need some parentheses here (and everywere you've > >> introduced alternatives via |)? Otherwise, it seems that > >> this would stop working with the older compilers ... > > > > Hi Ulrich, > > > > Thanks for looking into this patch. Sometimes the GDB testsuite is a > > mystery to me. This time it seems to work without parentheses: > > > > old compiler: > > whatis c2 > > type = char [2] > > (gdb) PASS: gdb.opencl/datatypes.exp: whatis c2 > > > > new compiler: > > whatis c2 > > type = char2 > > (gdb) PASS: gdb.opencl/datatypes.exp: whatis c2 > > > > Any suggestions? > > This passes because "char \\\[2\\\]" matches (a substring of) the first > output, but you really want to match the whole string "type = char [2]". > > +gdb_test "whatis c2" "type = char(2| \\\[2\\\])" Does this also mean: gdb_test "whatis c2" "type = .*(char(2| \\\[2\\\]))" as suggested by Jan? My intension was to exactly match either "char2" or "char [2]". Thanks Ken