From: Eli Zaretskii <eliz@gnu.org>
To: gdb-patches@sourceware.org
Subject: Re: Prevent crashes using $arg0
Date: Tue, 07 Feb 2006 20:46:00 -0000 [thread overview]
Message-ID: <u64nq6h17.fsf@gnu.org> (raw)
In-Reply-To: <20060207193932.GA28960@nevyn.them.org> (message from Daniel Jacobowitz on Tue, 7 Feb 2006 14:39:32 -0500)
> Date: Tue, 7 Feb 2006 14:39:32 -0500
> From: Daniel Jacobowitz <drow@false.org>
>
> This patch fixes a crash Andrew Stubbs reported:
>
> if 1 == 1
> print $arg0
> end
>
> The new response is:
> $arg0 used outside of any user function
Is it possible to have $arg0 behave outside user-defined functions as
any other convenience variable? That is, can we have this response
instead:
(gdb) if 1 == 1
>print $arg0
>end
$1 = void
(gdb)
? If this is not too hard, it's cleaner, since it doesn't reserve the
names of these variables globally.
[Time passes...] Actually, I'm quite sure we should behave like I
suggested, since we already do that without the if clause:
(gdb) print $arg0
$1 = void
(gdb)
next prev parent reply other threads:[~2006-02-07 20:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-02-07 19:39 Daniel Jacobowitz
2006-02-07 20:46 ` Eli Zaretskii [this message]
2006-02-20 16:04 ` Daniel Jacobowitz
2006-02-20 21:22 ` Eli Zaretskii
2006-03-30 17:20 ` Daniel Jacobowitz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=u64nq6h17.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox