This is the mail archive of the
archer@sourceware.org
mailing list for the Archer project.
Subclassing gdb.Value
- From: Jim Blandy <jimb at red-bean dot com>
- To: archer at sourceware dot org
- Date: Fri, 6 Feb 2009 15:09:41 -0800
- Subject: Subclassing gdb.Value
It seems like it would be very convenient to be able to subclass
gdb.Value. Having implemented a bunch of operations in Python on
gdb.Value objects, one wants to wrap them up in a class for all the
usual reasons --- and then there's no good reason to have to make a
distinction between the gdb.Value that I can do gdb-like things with,
and an instance of my class that I can do application-specific things
with. Clearly, my value "is a" gdb value.
However, gdb.Value doesn't have Py_TPFLAGS_BASETYPE set. Could
someone give me a heads-up about what sorts of problems I'm liable to
encounter if I try to make this work?