Re: [PATCH:MI] Return a subset of a variable object's children

Vladimir Prus
2008-04-30T10:11:37Z

AndrÃ© PÃ¶nitz wrote:

> On Wednesday 30 April 2008 11:19:59 Vladimir Prus wrote:
>> AndrÃ© PÃ¶nitz wrote:
>> >> I wonder if deleting children that are not visible is possible/desirable.
>> >
>> > Well, I would still prefer a simple toggle that would allow me to switch off
>> > any automatic creation of children
>>
>> There's no automatic creation. Until you do -list-children, no child is created.
>
> That's what I meant. Right now I can't get a list of children without
> varobjects being created.

Yes, why is that a bad thing?

>> > and one-shot 'expression evaluation' and one-shot 'children listing'.
>>
>> What is 'expression evaluation'.
>
> A shortcut for
>
> -var-create foo * exp
> -var-evaluate-expression foo
> -var-delete foo
>
> optionally including a
>
> -var-list-children foo
>
> Maybe its already there and I just did not see it...

Well, there's data-evaluate-expression but it throws raw data at you, there's
no "children", just string.

I seems that doing the 3 or 4 commands above is just fine. Why do you want
to delete varobj immediately and what problem does sending 4 commands cause?

>> I'm afraid I don't get your point. If you want funny representations of
>> any type you can either:
>>
>> 1. Use Python visualizers (that can be switched on the fly)
>
> Right. I guess that's probably the route to go for me in the long run.
> I am a bit scared by the additional dependency, though, so I wouldn't
> mind to have a reasonably well working 'pure MI' solution as fallback,
> too.

Probably won't happen.

>> 2. Just get the raw data and show it as you see fit.
>
> This does not work too well with structures containing pointers
> or such. It's fine for 'position independent' data like bitmaps or
> so, though.

If a structure contains a pointer, and you want some custom visualization,
you can do something with the pointer value. I don't really understand
what you're trying to do :-(

- Volodya