This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: set print object on should affect MI varobjs (PR mi/13393)
- From: xgsa <xgsa at yandex dot ru>
- To: Eli Zaretskii <eliz at gnu dot org>
- Cc: gdb-patches at sourceware dot org
- Date: Mon, 19 Mar 2012 09:10:08 +0200
- Subject: Re: set print object on should affect MI varobjs (PR mi/13393)
- References: <4ED92C05.9080803@yandex.ru> <m3mxanjiy0.fsf@fleche.redhat.com> <4EF22A4D.80703@yandex.ru> <20111221193630.GA28985@host2.jankratochvil.net> <4EF30389.5010008@yandex.ru> <20111223200951.GA19581@host2.jankratochvil.net> <4EF5D1C5.5010902@yandex.ru> <20120102022153.GA686@host2.jankratochvil.net> <4F07177C.5080201@yandex.ru> <m38vkfljq5.fsf@fleche.redhat.com> <4F32C009.2050103@yandex.ru> <87pqdma1mo.fsf@fleche.redhat.com> <4F412637.2010405@yandex.ru> <4F660CF6.9070008@yandex.ru> <8339953anu.fsf@gnu.org>
What exactly is the nature of the change, as will be visible by GDB
users? With that information in hand, I could answer your questions.
That was the reply on the original patch, so I thought that I can omit
the description, sorry.
That patch makes "set print object" option affect MI interface. Here is
an example:
struct Base {
Base() : a(1) {}
virtual ~Base() {} // Enforce type to have RTTI
int a;
};
struct Derived : public Base {
Derived() : b(2) {}
int b;
};
int main() {
Derived b;
Base* aPtr = &b;
return 0; // [1]
}
Start gdb in MI mode and run to line [1]. Make -var-create for aPtr. If
"set print object" is "on" you will see the type Derived* for the
created varobj.
See also more details here:
http://sourceware.org/bugzilla/show_bug.cgi?id=13393
Thanks,
Anton