This is the mail archive of the gdb@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: Variable objects and STL containers


On Sunday 17 February 2008 03:19:14 Nick Roberts wrote:
>  > Creating variable objects using internals wasn't so hard for vectors but
>  > it gets a bit more tricky with lists.  
> 
> Actually it looks doable for lists, maps etc if the children of a variable
> object were stored as a list rather than a vector.  This is so that a new
> child can be added, or an old one deleted, at any point in the list.
> 
> Ironically, the children were previously stored in a linked list and I guess
> vectors were used because Nathan Sidwell has created an API in C for them.
> There doesn't appear to be a similar API for lists, but since they are more
> flexible, would it be possible to revert var->children to a linked list?

I'm afraid I don't see any such flexibility. Can you clarify? The vectors were used
because they allowed to eliminate lots of custom list handling code, and
I'm reluctant to go back.

- Volodya




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