From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2115 invoked by alias); 18 Dec 2008 19:57:52 -0000 Received: (qmail 2107 invoked by uid 22791); 18 Dec 2008 19:57:51 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from smtp-outbound-1.vmware.com (HELO smtp-outbound-1.vmware.com) (65.115.85.69) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 18 Dec 2008 19:57:16 +0000 Received: from mailhost4.vmware.com (mailhost4.vmware.com [10.16.67.124]) by smtp-outbound-1.vmware.com (Postfix) with ESMTP id 25E424A005; Thu, 18 Dec 2008 11:57:15 -0800 (PST) Received: from [10.20.92.151] (promb-2s-dhcp151.eng.vmware.com [10.20.92.151]) by mailhost4.vmware.com (Postfix) with ESMTP id 1ADE9C9A63; Thu, 18 Dec 2008 11:57:15 -0800 (PST) Message-ID: <494AA9EC.5080506@vmware.com> Date: Thu, 18 Dec 2008 19:57:00 -0000 From: Michael Snyder User-Agent: Thunderbird 1.5.0.12 (X11/20080411) MIME-Version: 1.0 To: Joel Brobecker CC: Jie Zhang , "gdb-patches@sourceware.org" Subject: Re: Testsuite: Don't use global command in gdb_expect References: <4945F3EF.6050004@analog.com> <20081215075228.GK6866@adacore.com> In-Reply-To: <20081215075228.GK6866@adacore.com> Content-Type: text/plain; charset=us-ascii; 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: 2008-12/txt/msg00329.txt.bz2 Joel Brobecker wrote: >> The Tcl global command has no effect unless executed in the context of >> a proc body. So the global commands in the following code are >> useless. > > Verified in the Tcl 8.4 documentation. > >> Even worse, they would cause unexpected result. When gdb_expect gets >> something containing "global", it will try to execute hex as a command, >> which will cause an error. > > I'm wondering how this is happening, though. I presume that the test > was working when the testcase was added by the original author... That would be me, I think. I probably did not understand the issue, and I support whatever solution you two arrive at. ;-) > It's working for me too, actually. > > That being said, these are only side questions. The patch looks correct > to me. > >> 2008-12-15 Jie Zhang >> >> * gdb.base/consecutive.exp: Don't use global in gdb_expect. > > OK. >