Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [RFA/doc] until/advance commands
@ 2003-01-15  0:11 Elena Zannoni
  2003-01-15  7:37 ` Eli Zaretskii
  0 siblings, 1 reply; 3+ messages in thread
From: Elena Zannoni @ 2003-01-15  0:11 UTC (permalink / raw)
  To: gdb-patches


This is the patch for the new commands.

Elena

2003-01-14  Elena Zannoni  <ezannoni@redhat.com>

	* gdb.texinfo (Continuing and Stepping): Add new command
	'advance'. Clarify behavior of 'until'.

Index: gdb.texinfo
===================================================================
RCS file: /cvs/uberbaum/gdb/doc/gdb.texinfo,v
retrieving revision 1.137
diff -u -p -r1.137 gdb.texinfo
--- gdb.texinfo	13 Jan 2003 17:59:49 -0000	1.137
+++ gdb.texinfo	15 Jan 2003 00:10:00 -0000
@@ -3462,8 +3462,35 @@ argument.
 Continue running your program until either the specified location is
 reached, or the current stack frame returns.  @var{location} is any of
 the forms of argument acceptable to @code{break} (@pxref{Set Breaks,
-,Setting breakpoints}).  This form of the command uses breakpoints,
-and hence is quicker than @code{until} without an argument.
+,Setting breakpoints}).  This form of the command uses breakpoints, and
+hence is quicker than @code{until} without an argument.  The specified
+location is actually reached only if it is in the current frame.  This
+implies that @code{until} can be used to skip over recursive function
+invocations.  For instance in the code below, if the current location is
+line @code{96}, issuing @code{until 99} will execute the program up to
+line @code{99} in the same invocation of factorial, i.e. after the inner
+invocations have returned.
+
+@smallexample
+94	int factorial (int value)
+95	@{
+96	    if (value > 1) @{
+97            value *= factorial (value - 1);
+98	    @}
+99	    return (value);
+100     @}
+@end smallexample
+
+
+@kindex advance @var{location}
+@itemx advance @var{location}
+Continue running the program up to the given location.  An argument is
+required, anything of the same form as arguments for the @code{break}
+command.  Execution will also stop upon exit from the current stack
+frame.  This command is similar to @code{until,} but @code{advance} will
+not skip over recursive function calls, and the target location doesn't
+have to be in the same frame as the current one.
+
 
 @kindex stepi
 @kindex si @r{(@code{stepi})}


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [RFA/doc] until/advance commands
  2003-01-15  0:11 [RFA/doc] until/advance commands Elena Zannoni
@ 2003-01-15  7:37 ` Eli Zaretskii
  2003-01-15 14:33   ` Elena Zannoni
  0 siblings, 1 reply; 3+ messages in thread
From: Eli Zaretskii @ 2003-01-15  7:37 UTC (permalink / raw)
  To: ezannoni; +Cc: gdb-patches

> From: Elena Zannoni <ezannoni@redhat.com>
> Date: Tue, 14 Jan 2003 19:15:16 -0500
> 
> This is the patch for the new commands.

Approved, but please move the comma out of the braces in this line:

> +frame.  This command is similar to @code{until,} but @code{advance} will

Thanks!


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [RFA/doc] until/advance commands
  2003-01-15  7:37 ` Eli Zaretskii
@ 2003-01-15 14:33   ` Elena Zannoni
  0 siblings, 0 replies; 3+ messages in thread
From: Elena Zannoni @ 2003-01-15 14:33 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: ezannoni, gdb-patches

Eli Zaretskii writes:
 > > From: Elena Zannoni <ezannoni@redhat.com>
 > > Date: Tue, 14 Jan 2003 19:15:16 -0500
 > > 
 > > This is the patch for the new commands.
 > 
 > Approved, but please move the comma out of the braces in this line:
 > 
 > > +frame.  This command is similar to @code{until,} but @code{advance} will
 > 
 > Thanks!

ah, good eye.

thanks
committed.

Elena


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-01-15 14:33 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-01-15  0:11 [RFA/doc] until/advance commands Elena Zannoni
2003-01-15  7:37 ` Eli Zaretskii
2003-01-15 14:33   ` Elena Zannoni

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox