This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] [python] PR python/15461 (gate architecture calls)
- From: Tom Tromey <tromey at redhat dot com>
- To: Phil Muldoon <pmuldoon at redhat dot com>
- Cc: "gdb-patches\ at sourceware dot org" <gdb-patches at sourceware dot org>
- Date: Wed, 28 Aug 2013 09:54:55 -0600
- Subject: Re: [patch] [python] PR python/15461 (gate architecture calls)
- Authentication-results: sourceware.org; auth=none
- References: <521DE761 dot 6010403 at redhat dot com> <87k3j5x3yq dot fsf at fleche dot redhat dot com> <521E1419 dot 5040404 at redhat dot com>
Phil> I don't disagree on the efficiency argument, but my goal here was to
Phil> follow the pattern that other objects use to determine validity of the
Phil> underlying GDB data. To bring a sense of uniformity to how we do
Phil> things in Python. So how we check a gdb.Frame's, et al, validity, the
Phil> pattern will be the same, as far as possible, for other objects.
Ok.
If you look at other ones, they set the Python exception. At least that
is true for py-block.c (twice), py-inferior.c, py-inthread.c,
py-symbol.c, py-symtab.c (twice), etc.
FWIW I don't mind inconsistency in these little details. What matters
is the context in which the macro is most useful.
Tom