From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29429 invoked by alias); 17 Jan 2014 13:36:16 -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 29419 invoked by uid 89); 17 Jan 2014 13:36:15 -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,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mga11.intel.com Received: from mga11.intel.com (HELO mga11.intel.com) (192.55.52.93) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 17 Jan 2014 13:36:14 +0000 Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP; 17 Jan 2014 05:36:10 -0800 X-ExtLoop1: 1 Received: from irsmsx102.ger.corp.intel.com ([163.33.3.155]) by fmsmga002.fm.intel.com with ESMTP; 17 Jan 2014 05:36:02 -0800 Received: from irsmsx151.ger.corp.intel.com (163.33.192.59) by IRSMSX102.ger.corp.intel.com (163.33.3.155) with Microsoft SMTP Server (TLS) id 14.3.123.3; Fri, 17 Jan 2014 13:34:35 +0000 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.215]) by IRSMSX151.ger.corp.intel.com ([169.254.4.126]) with mapi id 14.03.0123.003; Fri, 17 Jan 2014 13:34:35 +0000 From: "Agovic, Sanimir" To: 'Tom Tromey' CC: "palves@redhat.com" , "xdje42@gmail.com" , "gdb-patches@sourceware.org" , "Boell, Keven" Subject: RE: [PATCH v4 12/13] test: basic c99 vla tests for C primitives Date: Fri, 17 Jan 2014 13:36:00 -0000 Message-ID: <0377C58828D86C4588AEEC42FC3B85A7176D419D@IRSMSX105.ger.corp.intel.com> References: <1387282678-3847-1-git-send-email-sanimir.agovic@intel.com> <1387282678-3847-13-git-send-email-sanimir.agovic@intel.com> <871u09orgl.fsf@fleche.redhat.com> <0377C58828D86C4588AEEC42FC3B85A7176D3671@IRSMSX105.ger.corp.intel.com> <87zjmvn863.fsf@fleche.redhat.com> In-Reply-To: <87zjmvn863.fsf@fleche.redhat.com> Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2014-01/txt/msg00677.txt.bz2 > >>>>> "Sanimir" =3D=3D Agovic, Sanimir writes: >=20 > Tom> I didn't see any tests for the case where there should be a side eff= ect. >=20 > Sanimir> This line from above: > Sanimir> gdb_test "print sizeof (++int_vla\[0\])" [...] > Sanimir> Is used to ensure that no side effect happen to arguments > Sanimir> passed to sizeof. > Sanimir> The test is trying to express the following: > Sanimir> int i =3D 42; sizeof(++i); assert (i =3D=3D 42) > Sanimir> Is it OK? >=20 > Yeah, that's good -- but I think there are also cases where a side > effect is expected, and it would be good to have a test for that as > well. >=20 Can you please guide me and point out some cases? I will add them to the test. Thanks. -Sanimir=20 Intel GmbH Dornacher Strasse 1 85622 Feldkirchen/Muenchen, Deutschland Sitz der Gesellschaft: Feldkirchen bei Muenchen Geschaeftsfuehrer: Christian Lamprechter, Hannes Schwaderer, Douglas Lusk Registergericht: Muenchen HRB 47456 Ust.-IdNr./VAT Registration No.: DE129385895 Citibank Frankfurt a.M. (BLZ 502 109 00) 600119052