This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Obtaining number of children of a dynamic varobj
- From: "Elmenthaler, Jens" <jens dot elmenthaler at verigy dot com>
- To: <gdb at sourceware dot org>
- Date: Thu, 11 Feb 2010 03:27:46 -0600
- Subject: Obtaining number of children of a dynamic varobj
Hi,
Trying to enable the python pretty printers in the Eclipse CDT, a question about the MI API for varobjs arose.
If I read the documentation correctly, I should not call -var-list-children without the range of children, because in general I should assume that the varobj has a huge number of children and fetching them all is potential too expensive.
Quite reasonable sofar. Nevertheless, I have the problem that I have to know the number of children a dynamic varobj has.
The only way I see to obtain the number of children, however, is to call -var-list-children without a range specification. I can omit the values to be transferred. Does that have the same scalability issues, after all it still creates a varobj for each child?
Jens.