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: [RFA] New python module gdb.types


On Wed, Oct 6, 2010 at 3:11 PM, Tom Tromey <tromey@redhat.com> wrote:
> I wouldn't mind if has_field were made a method on Type, but of course
> that can be done at any time.

It could, but there are design issues.
E.g., the has_field function calls get_basic_type and traverses base
types (instead of treating base types as a field which is what the
current gdb.Type API does.  It's an internal implementation detail of
gdb that got exposed.  Maybe it's reasonable to keep, I don't know).
Whether Type.has_field should do that ... I'm not sure.
It felt safer to see what works as a separate function before
expanding gdb.Type.

> I think the documentation would be a little improved if the gdb.Type
> documentation had an xref to the new module's documentation.

Thanks.


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