This is the mail archive of the 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: [PATCH] specify arguments to debugee from commandline (second try)

> Date: Wed, 11 Apr 2001 01:35:53 -0400
> From: David Deephanphongs <>
> Thus spake Eli Zaretskii (
> > > From: Tom Tromey <>
> > > Date: 06 Apr 2001 12:12:22 -0600
> > > 
> > > I'm not sure I follow you though.  Are you saying that some other
> > > approach should be taken?  If so, what?
> > 
> > No, I'm saying that I don't think this problem has a general
> > solution.  So we should decide up front what cases we want to support
> > and which ones not.
> I'm not convinced that we want to support any special handling...
> We could force the user to just escape everything appropriately:
> If they want equivalent to:
> set args "this is a" test
> force them to do:
> gdb echo -- \"this is a\" test

But that's exactly what Tom was trying to avoid!  His intent was to
allow substitution of "gdb COMMAND --run ARGS" for each case of
"COMMAND ARGS" in a mechanical way, which means ARGS should not be
modified in any way.

In other words, Tom was not talking about a user who types a command
at the shell prompt, but about a script that should behave the same in
both of these situations.  A human can easily be asked to escape
special characters in a command, but a shell script cannot do that
without lots of tricky and shell-dependent code.

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