This is the mail archive of the gdb@sources.redhat.com 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]

Re: gdb questions


Mickael Gicquaire wrote:
> 
> Hi all,
> I have a few enquiries concerning GDB.
> 
> It seems that there is no way at the moment to see what commands are being
> issued to gdb while sourcing a file using the source command. I am right?
> I think it could be useful in some instances.
> 

Sure.  We just need a volunteer to submit a patch.  

However, this will require that a switch is added to the "source"
command syntax
and that will lead us to a long discussion on the syntax of switches
("\" or "-").

> Another thing is why is it not possible to issue mi commands inside a file that
> is being sourced or why is there not an equivalent command to the source
> command in the mi set of commands ?
> 

IMO, that is conceptually wrong.  The MI is not another command line
syntax -- it is
a machine protocol between two programs.  It was chosen to be in ASCII
and readable
for easy of debugging and implementation.

The idea is that the MI source command reads and executes commands (from
a file) that
are in the normal GDB command line (cli) script language.  It was not
implemented yet
because GDB is slowly being modified to allow switching the format of
commands on the
fly.  This requires adding parameters to functions and passing them down
so it takes
some time to do.


Thanks for the comments and suggestions.

-- 
Fernando Nasser
Red Hat Canada Ltd.                     E-Mail:  fnasser@redhat.com
2323 Yonge Street, Suite #300
Toronto, Ontario   M4P 2C9


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