This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
Re: gdb/2211: Cannot Share GDB variables with 'set env' or 'shell' commands
- From: Daniel Jacobowitz <drow at false dot org>
- To: nobody at sources dot redhat dot com
- Cc: gdb-prs at sources dot redhat dot com,
- Date: 7 Dec 2006 15:28:02 -0000
- Subject: Re: gdb/2211: Cannot Share GDB variables with 'set env' or 'shell' commands
- Reply-to: Daniel Jacobowitz <drow at false dot org>
The following reply was made to PR gdb/2211; it has been noted by GNATS.
From: Daniel Jacobowitz <drow@false.org>
To: mbgdbgnu@bytnar.net
Cc: gdb-gnats@sources.redhat.com
Subject: Re: gdb/2211: Cannot Share GDB variables with 'set env' or 'shell' commands
Date: Thu, 7 Dec 2006 10:20:32 -0500
On Mon, Dec 04, 2006 at 05:59:01PM -0000, mbgdbgnu@bytnar.net wrote:
> There is no means to evaluate a GDB expression in the 'set env' or
> 'shell' commands. Please correct me if I am wrong, since the
> documentation and use of GDB has not revealed a way to do so.
You are correct, there is no way to do this.
Convenience variables in the GDB command line interface all have types
similar to C types. They can be ints, or char *s, but not real
strings; and without real strings, there's no sensible way to do this.
Rather than adding more hacks of this sort to the GDB CLI, I suspect we
will add a more complete scripting language in a future version (Guile
or Python).
--
Daniel Jacobowitz
CodeSourcery