From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23491 invoked by alias); 12 Sep 2012 23:29:37 -0000 Received: (qmail 23480 invoked by uid 22791); 12 Sep 2012 23:29:36 -0000 X-SWARE-Spam-Status: No, hits=-7.1 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 12 Sep 2012 23:29:22 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q8CNTM2Q014945 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 12 Sep 2012 19:29:22 -0400 Received: from valrhona.uglyboxes.com (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q8CNTKj5004193 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Wed, 12 Sep 2012 19:29:21 -0400 Message-ID: <50511AD0.6000702@redhat.com> Date: Wed, 12 Sep 2012 23:29:00 -0000 From: Keith Seitz User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120605 Thunderbird/13.0 MIME-Version: 1.0 To: Jan Kratochvil CC: "gdb-patches@sourceware.org ml" Subject: Re: Testsuite regression gdb.cp/converts.exp [Re: [RFA] gdb/13483] References: <5041274D.1050508@redhat.com> <87ehm9evyb.fsf@fleche.redhat.com> <504E2438.6020701@redhat.com> <20120911054549.GA25093@host2.jankratochvil.net> <5050E4A4.2080600@redhat.com> <20120912195845.GA16888@host2.jankratochvil.net> In-Reply-To: <20120912195845.GA16888@host2.jankratochvil.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit 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: 2012-09/txt/msg00230.txt.bz2 On 09/12/2012 12:58 PM, Jan Kratochvil wrote: > Yes, I agree. Although rather to replace it in .c by an explanatory comment > like > > /* .exp file contains line > gdb_test "p foo1_7(&foo1_7)" " = 17" > which is not compiled here for verification as older GCCs (~4.1) fail the > compilation due to: > warning: the address of 'int foo1_7(bool)', will always evaluate as 'true' > */ Sure. For the record, here is what I committed: 2012-09-12 Keith Seitz * gdb.cp/converts.cc (main): Comment out the pointer to boolean conversion statement. Index: gdb.cp/converts.cc =================================================================== RCS file: /cvs/src/src/gdb/testsuite/gdb.cp/converts.cc,v retrieving revision 1.5 diff -u -p -r1.5 converts.cc --- gdb.cp/converts.cc 10 Sep 2012 17:12:52 -0000 1.5 +++ gdb.cp/converts.cc 12 Sep 2012 23:27:03 -0000 @@ -78,7 +78,15 @@ int main() foo1_7 (long_int); // long to boolean foo1_7 (*a); // char to boolean foo1_7 (MY_A); // unscoped enum to boolean + /* converts.exp tests the next statement directly. It is not compiled + here for verification because older versions of GCC (~4.1) fail to + compile it: + + warning: the address of 'int foo1_7(bool)' will always evaluate as true + foo1_7 (&foo1_7); // pointer to boolean + */ + foo1_7 (&A::member_); // pointer to member to boolean foo1_7 (a); // pointer to boolean foo1_7 (fp); // float to boolean Keith