This is the mail archive of the gdb-patches@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: [RFC] New GDB/MI command "-info-gdb-mi-command"


> From: Joel Brobecker <brobecker@adacore.com>
> Cc: gdb-patches@sourceware.org
> Date: Tue, 12 Nov 2013 15:25:04 +0400
> 
> This patch adds a new GDB/MI command meant for graphical frontends
> trying to determine whether a given GDB/MI command exists or not.
> 
> Examples:
> 
>     -info-gdb-mi-command unsupported-command
>     ^done,command={exists="false"}
>     (gdb)
>     -info-gdb-mi-command symbol-list-lines
>     ^done,command={exists="true"}
>     (gdb)

Sounds good to me.

> +@subheading The @code{-info-gdb-mi-command} Command
> +@findex -info-gdb-mi-command

This should be prominently indexed with @cindex entries, as this
command is very important, and should be easily found.

> +@subsubheading Synopsis
> +
> +@smallexample
> + -info-gdb-mi-command CMD_NAME
> +@end smallexample
> +
> +Query support for the @sc{gdb/mi} command named @var{CMD_NAME}

Ts-ts-ts... ASCII art habits die hard.  Use @var in the example, and
don't upcase CMD_NAME (it is upcased in Info anyway, and will look
better in print in lower case).

> +(the leading dash (@code{-}) in the command name should be omitted).

Is this wise?  How about if we support both with and without the dash?

> +There is no corresponding @value{GDBN} command.

Having a way of querying that in CLI would facilitate better .gdbinit
files, I think.

> +@smallexample
> +-info-gdb-mi-command symbol-list-lines
> +^done,command=@{exists="true"@}
> +@end smallexample

Btw, why "command="?  Perhaps "result="?

Other than that, the documentation is fine with me.

Thanks.


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