This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] Testsuite addition for x86 linux GDB and SIGALRM fix
- To: Fernando Nasser <fnasser at redhat dot com>
- Subject: Re: [RFA] Testsuite addition for x86 linux GDB and SIGALRM fix
- From: Eli Zaretskii <eliz at is dot elta dot co dot il>
- Date: Thu, 26 Jul 2001 18:18:52 +0300 (IDT)
- cc: Andrew Cagney <ac131313 at cygnus dot com>, Michael Snyder <msnyder at cygnus dot com>, Daniel Jacobowitz <dmj+ at andrew dot cmu dot edu>, gdb-patches at sourceware dot cygnus dot com
On Thu, 26 Jul 2001, Fernando Nasser wrote:
> > o step executes instructions until you
> > leave the current line
> > (be it enter a function or reach a new
> > line)
> >
>
> 'step' should never leave you in the same line from where you've issued
> it. That is counter intuitive, even if you had a stop-finish in the
> middle.
Agreed.
> "finish" is a source level command and source level commands should not
> leave you in the middle of source lines.
I'm not sure I understand what you mean here (or that you mean what I
understand ;-). We could have a source line like this:
int i = (foo (), bar ());
or even like this:
int i = foo (); bar ();
Where would you suggest that "finish" leaves you in these cases, and what
does ``in the middle of source lines'' mean in these cases? Also, do you
think these two cases are fundamentally different from "foo (bar ());",
and if so, how are they different?
> When the user issues a "step" on 'foo (bar ())' source line, he/she may
> want to enter either bar() or foo(). We cannot know that, so we must
> stop at each one and he/she can go to the next by issuing "finish",
> i.e., "finish _this_ subroutine".
Now I'm confused: this seems to suggest that the first "step" gets her
inside bar(), and if she then types "finish", she will be after the call
to bar(), but before the call to foo() (that's how I interpret ``finish
_this_ subroutine''). But that is in the middle of a source line, which
seems to contradict your previous requirement.
What am I missing?