public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug python/10953] New: gdb.Type does not give access to Base classes
@ 2009-11-13 15:55 andre dot poenitz at nokia dot com
  2009-11-17 17:03 ` [Bug python/10953] " pmuldoon at redhat dot com
                   ` (11 more replies)
  0 siblings, 12 replies; 13+ messages in thread
From: andre dot poenitz at nokia dot com @ 2009-11-13 15:55 UTC (permalink / raw)
  To: gdb-prs

That's archer-tromey-python, at dad6b53fe4

The problem is that gdb.selected_frame().read_var("d").type.fields()  reports an
empty list. The list becomes non-empty as soon as the contents of derived.cpp is
moved to main.cpp.

------------------ Makefile ------------------
run:
        g++ -g base.cpp derived.cpp main.cpp -o yy
        ~/bin/gdb-archer -ex 'b main' -ex 'run' \
          -ex 'python print gdb.selected_frame().read_var("d").type.fields()' \
          ./yy


------------------ base.h ------------------
#ifndef BASE_H
struct Base
{
    virtual ~Base();
};
#endif


------------------ base.cpp ------------------
#include "base.h"

Base::~Base() {}


------------------ derived.h ------------------
#ifndef DERIVED_H

#include "base.h"

struct Derived : Base
{
    virtual ~Derived();
};
#endif


------------------ derived.cpp ------------------
#include "derived.h"

Derived::~Derived() {}


------------------ main.cpp ------------------

#include "derived.h"

int main()
{
    Derived d;
}
~

-- 
           Summary: gdb.Type does not give access to Base classes
           Product: gdb
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: python
        AssignedTo: unassigned at sourceware dot org
        ReportedBy: andre dot poenitz at nokia dot com
                CC: gdb-prs at sourceware dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


http://sourceware.org/bugzilla/show_bug.cgi?id=10953

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2010-08-23 20:31 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-13 15:55 [Bug python/10953] New: gdb.Type does not give access to Base classes andre dot poenitz at nokia dot com
2009-11-17 17:03 ` [Bug python/10953] " pmuldoon at redhat dot com
2009-11-18  8:08 ` dodji at redhat dot com
2009-11-24 17:06 ` pmuldoon at redhat dot com
2009-11-24 17:27 ` pmuldoon at redhat dot com
2010-05-26 13:54 ` andre dot poenitz at nokia dot com
2010-05-26 14:24 ` andre dot poenitz at nokia dot com
2010-05-26 15:07 ` andre dot poenitz at nokia dot com
2010-08-11 20:54 ` tromey at redhat dot com
2010-08-11 21:14 ` pmuldoon at redhat dot com
2010-08-20 18:27 ` tromey at redhat dot com
2010-08-20 18:34 ` tromey at redhat dot com
2010-08-23 20:31 ` tromey at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).