From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 504 invoked by alias); 4 Aug 2008 03:22:33 -0000 Received: (qmail 353 invoked by uid 22791); 4 Aug 2008 03:22:33 -0000 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.31) with ESMTP; Mon, 04 Aug 2008 03:21:54 +0000 Received: from HOME-C4E4A596F7 ([84.229.228.238]) by i_mtaout5.012.net.il (HyperSendmail v2004.12) with ESMTPA id <0K5200MA43YWO8H0@i_mtaout5.012.net.il> for gdb-patches@sources.redhat.com; Mon, 04 Aug 2008 06:20:57 +0300 (IDT) Date: Mon, 04 Aug 2008 03:22:00 -0000 From: Eli Zaretskii Subject: Re: [RFA][patch 1/9] Yet another respin of the patch with initial Python support In-reply-to: <1217818243.9336.7.camel@localhost.localdomain> X-012-Sender: halo1@inter.net.il To: Thiago Jung Bauermann Cc: tromey@redhat.com, gdb-patches@sources.redhat.com Reply-to: Eli Zaretskii Message-id: References: <20080528205921.GA2969@caradoc.them.org> <20080615181833.uxmo25mg0kko40kw@imap.linux.ibm.com> <1216107418.14956.27.camel@localhost.localdomain> <1216245620.12209.18.camel@localhost.localdomain> <20080718195010.GA14356@caradoc.them.org> <1216653969.31797.6.camel@localhost.localdomain> <20080726173508.GA16470@caradoc.them.org> <1217818243.9336.7.camel@localhost.localdomain> 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-08/txt/msg00046.txt.bz2 > From: Thiago Jung Bauermann > Cc: tromey@redhat.com, gdb-patches@sources.redhat.com > Date: Sun, 03 Aug 2008 23:50:43 -0300 > > > When executing the @code{python} command, Python exceptions uncaught > > within the Python code are translated to calls to @value{GDBN} > > error-reporting mechanism, which terminates the currently executing > > command and prints an error message containing the Python exception > > name, the associated value, and the Python call stack backtrace at > > the point where the exception was raised. Example: > > ... it is not necessarily true that GDB will terminate the currently > executing command when the Python exception is converted to a GDB > exception. If the Python script is extending some GDB subsystem (one of > our goals), that subsystem can catch the exception and deal with it in > another way. So for this part I suggest: > > ... are translated to calls to @value{GDBN} error-handling mechanism, > which depending on the context of the Python script can either deal > with the error in a subsystem-specific way, or terminate the currently > executing command ... > > What do you think? I think what I suggested is still valid: no matter how the exception is caught, it will still terminate the current command, won't it? And, btw, do we actually have examples of such non-default exception handling in GDB?