This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, doc RFA] Add ability to set random attributes in python objfiles,progspaces


On Thu, Oct 9, 2014 at 12:08 PM, Doug Evans <dje@google.com> wrote:
> Hi.
>
> I have a need to do some extra record keeping in progspaces and
> objfiles.  This patch adds the ability to add random attributes
> to objfile and progspace objects using the same mechanism used
> for gdb.Fields.
>
> Regression tested on amd64-linux.
>
> 2014-10-09  Doug Evans  <dje@google.com>
>
>         * NEWS: Mention ability add attributes to gdb.Objfile and
>         gdb.Progspace objects.
>         * python/py-objfile.c (objfile_object): New member dict.
>         (objfpy_dealloc): Py_XDECREF dict.
>         (objfpy_initialize): Initialize dict.
>         (objfile_getset): Add __dict__.
>         (objfile_object_type): Set tp_dictoffset member.
>         * python/py-progspace.c (progspace_object): New member dict.
>         (pspy_dealloc): Py_XDECREF dict.
>         (pspy_initialize): Initialize dict.
>         (pspace_getset): Add __dict__.
>         (pspace_object_type): Set tp_dictoffset member.
>
>         doc/
>         * gdb.texinfo (Progspaces In Python): Document ability to add
>         random attributes to gdb.Progspace objects.
>         (Objfiles In Python): Document ability to add random attributes to
>         gdb.objfile objects.
>
>         testsuite/
>         * gdb.python/py-objfile.exp: Add tests for setting random attributes
>         in objfiles.
>         * gdb.python/py-progspace.exp: Add tests for setting random attributes
>         in progspaces.

Oh, btw, if you're going to try this patch,
it depends on
https://sourceware.org/ml/gdb-patches/2014-10/msg00206.html


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]