From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30276 invoked by alias); 11 Feb 2009 21:55:28 -0000 Received: (qmail 30250 invoked by uid 22791); 11 Feb 2009 21:55:22 -0000 X-SWARE-Spam-Status: No, hits=-1.5 required=5.0 tests=AWL,BAYES_00,SPF_SOFTFAIL X-Spam-Check-By: sourceware.org Received: from mtaout5.012.net.il (HELO mtaout5.012.net.il) (84.95.2.13) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 11 Feb 2009 21:55:15 +0000 Received: from conversion-daemon.i_mtaout5.012.net.il by i_mtaout5.012.net.il (HyperSendmail v2004.12) id <0KEX00D008VAKS00@i_mtaout5.012.net.il> for gdb-patches@sourceware.org; Wed, 11 Feb 2009 23:54:55 +0200 (IST) Received: from HOME-C4E4A596F7 ([84.229.24.112]) by i_mtaout5.012.net.il (HyperSendmail v2004.12) with ESMTPA id <0KEX002878VHYQP0@i_mtaout5.012.net.il>; Wed, 11 Feb 2009 23:54:55 +0200 (IST) Date: Wed, 11 Feb 2009 21:55:00 -0000 From: Eli Zaretskii Subject: Re: RFC: add ability to "source" Python code In-reply-to: To: ratmice@gmail.com, brobecker@adacore.com, tromey@redhat.com, bauerman@br.ibm.com, drow@false.org, pedro@codesourcery.com, gdb-patches@sourceware.org Reply-to: Eli Zaretskii Message-id: References: <200902100000.22671.pedro@codesourcery.com> <20090210034834.GA20077@caradoc.them.org> <1234267091.13871.4.camel@localhost.localdomain> <20090211060911.GB4225@adacore.com> <20090211203921.GC13021@adacore.com> <8ba6bed40902111325h3625a268mf0da744e25dcf409@mail.gmail.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: 2009-02/txt/msg00265.txt.bz2 > Date: Wed, 11 Feb 2009 23:48:26 +0200 > From: Eli Zaretskii > Cc: brobecker@adacore.com, tromey@redhat.com, bauerman@br.ibm.com, drow@false.org, pedro@codesourcery.com, gdb-patches@sourceware.org > > > Date: Wed, 11 Feb 2009 13:25:40 -0800 > > From: Matt Rice > > Cc: Joel Brobecker , tromey@redhat.com, bauerman@br.ibm.com, drow@false.org, pedro@codesourcery.com, gdb-patches@sourceware.org > > > > On Wed, Feb 11, 2009 at 1:06 PM, Eli Zaretskii wrote: > > > > > > Also, would an arbitrary Python script necessarily do anything useful > > > in GDB? Some of them probably will, but not just any one, I think. > > > > > > > Yes, > > > > (gdb) python execfile("/home/ratmice/bar.py") > > (gdb) python foo() > > foo > > > > where the foo function is defined in bar.py. > > so it acts just like 'source' in a shell i would imagine. > > Sorry, I don't understand how this is related. I mean I don't understand how printing "foo" is doing "something useful in GDB".