[PATCH] -stack-info-frames

Daniel Jacobowitz drow@false.org
Mon Jun 20 13:51:00 GMT 2005


On Mon, Jun 20, 2005 at 05:03:05PM +1200, Nick Roberts wrote:
> The other thing I find inappropriate about these messages is that they
> print out the name of the procedure which is not of immediate interest.

I agree.  I don't think the function or command name in all these error
messages is valuable.

> How about changing the format (for all MI commands) to
> 
> -stack-info-frame 4
> &"Usage: -stack-info-frame\n"
> ^error,msg="Usage: -stack-info-frame"
> (gdb) 
> 
> (gdb) 
> -stack-select-frame
> &"Usage: -stack-select-frame FRAME_SPEC\n"
> ^error,msg="Usage: -stack-select-frame FRAME_SPEC"
> (gdb) 
> 
> etc.
> 
> They should only occur when a developer is writing a frontend, not when it is
> being used.  The procedure name is only of interest to someone writing MI code
> For that person it should be quite easy to find the relevant code and, even if
> it was not, it should only be printed if a debug flag is set.

I like this idea; in fact, this is the style I was going to recommend
to you (until I went through and noticed that it is only used for
functions with arguments, not without, at the moment).

-- 
Daniel Jacobowitz
CodeSourcery, LLC



More information about the Gdb-patches mailing list