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: MI: type prefixes for values


> From: Vladimir Prus <ghost@cs.msu.su>
> Date: Fri, 17 Feb 2006 13:29:33 +0300
> Cc: gdb@sources.redhat.com
> 
> > Are you saying that you don't want to show your users the fact that
> > the pointed object is a function?
> 
> At the very least, not in the way that gdb assumes.

In what way, then?

> > > I imagine it's a simple matter of wrapping some code in
> > > "ui_output_is_mi_like_p". Can somebody comment on this proposal?
> >
> > I think this will lose useful information.  So for now I object.
> 
> You can get the type information via the -var-info-type, which is more formal 
> way to get this information.

Why is it more formal, and why should we force the front end to send
yet another command to get this information?  Increasing
communications between the front end and GDB is not a good idea, I
think.

> > >     (gdb)
> > >     -thread-select 2
> > >     ^done,new-thread-id="2",frame={level="0",func="thread",
> > >     args=[{name="p",value="0x0"}],..........
> > >    (gdb)
> > >    -stack-list-arguments 1 0 0
> > >    ^done,stack-args=[frame={level="0",
> > >    args=[{name="p",value="(void *) 0x0"}]}]
> > >
> > > Note that first output has "0x0" as value of 'p', and the second has
> > > "(void *)0x0".
> >
> > Also, the first one shows the func= part, the second doesn't.  
> 
> Heh, the second is not supposed to show func= part at all. MI does not have a 
> command equivalent to "backtrace". One has to list -stack-list-frames (that 
> does include func=) and -stack-list-arguments (that includes only argument). 
> BTW, not very convenient.

Perhaps MI should have an equivalent of backtrace.

> > Looks 
> > like a bug to me: those two should both use the same code.
> 
> Should I file a bug?

Yes, I think so.


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