[m-dev.] for review: new debugger command "next"

Mark Anthony BROWN dougl at cs.mu.OZ.AU
Tue Aug 8 14:26:36 AEST 2000


Zoltan Somogyi writes:
> For review by anyone. My main motivation is mainly that this new command
> will make it easier to provide imputs to the debugger test cases, but the
> command seems useful independently of that.
> 
> Add a new debugger command, next, which steps to the next event from the
> current call or its selected ancestor, thus stepping over events in called
> procedures. In concept it is therefore like gdb's next command. The
> implementation is very similar to the implementation of mdb's finish command,
> without the latter's requirement for the stopping event being a final event.
> 
> trace/mercury_trace.[ch]:
> 	Add the MR_CMD_NEXT movement command.
> 
> trace/mercury_trace_internal.c:
> 	Check for the "next" command, and implement it.
> 
> doc/user_guide.texi:
> 	Document the next command.
> 
> doc/mdb_categories.texi:
> 	Update the list of forward movement commands to include "next"
> 	and (a little late) "exception".
> 
> Zoltan.
> 
> Index: doc/user_guide.texi
> ===================================================================
> RCS file: /home/mercury1/repository/mercury/doc/user_guide.texi,v
> retrieving revision 1.213
> diff -u -b -r1.213 user_guide.texi
> --- doc/user_guide.texi	2000/07/25 09:27:38	1.213
> +++ doc/user_guide.texi	2000/08/07 04:10:01
> @@ -1818,6 +1818,22 @@
>  @sp 1
>  By default, this command is strict, and it uses the default print level.
>  @sp 1
> + at item next [-NSans] [@var{num}]
> +Continues execution until it reaches the next event of
> +the @var{num}'th ancestor of the call to which the current event refers,

This sentence needs a `.'

> +The default value of @var{num} is zero,
> +which means skipping to the next event of the current call.
> +Reports an error if execution is already at the end of the specified call.
> + at sp 1
> +The options @samp{-n} or @samp{--none}, @samp{-s} or @samp{--some},
> + at samp{-a} or @samp{--all} specify the print level to use
> +for the duration of the command,
> +while the options @samp{-S} or @samp{--strict}
> +and @samp{-N} or @samp{--nostrict} specify
> +the strictness of the command.
> + at sp 1
> +By default, this command is strict, and it uses the default print level.
> + at sp 1
>  @item finish [-NSans] [@var{num}]
>  Continues execution until it reaches a final (EXIT or FAIL) port of
>  the @var{num}'th ancestor of the call to which the current event refers.

Since you have elsewhere fixed EXCP documentation, you should do so here:

s/EXIT or FAIL/EXIT, FAIL or EXCP/

Aside from these comments, the diff looks fine.

Cheers,
Mark.

--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to:       mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions:          mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------



More information about the developers mailing list