[m-rev.] for review: normalize decl_ids in decl_set

Fergus Henderson fjh at cs.mu.OZ.AU
Fri Nov 1 05:23:23 AEDT 2002


On 31-Oct-2002, Peter Ross <pro at missioncriticalit.com> wrote:
> compiler/rtti.m:
> 	Remove the varset from the rtti_proc_label structure.  This is
> 	because rtti_proc_label is used as part of the key for the
> 	decl_set structure and sometimes the varset contains all the
> 	variables in the proc and sometimes only the headvariables
> 	leading to different keys representing the same declaration.
> 	Instead record the prog_var and its name together in an
> 	assoc_list.
> 
> compiler/code_util.m:
> compiler/ml_code_util.m:
> 	Hanle the new rtti_proc_label structure.

That looks good.

Just a few minor points:

s/Hanle/Handle/

> --- compiler/rtti.m	27 Oct 2002 03:18:39 -0000	1.21
> +++ compiler/rtti.m	31 Oct 2002 17:07:00 -0000
> @@ -413,8 +413,8 @@
>  			arg_types		::	list(type),
>  			pred_id			::	pred_id,
>  			proc_id			::	proc_id,
> -			proc_varset		::	prog_varset,
> -			proc_headvars		::	list(prog_var),
> +			proc_headvars		::	list(pair(prog_var,
> +								string)),

s/list(pair(/assoc_list(/

Also, it's not clear here that the string is the variable name.
Please add a comment, or use an equivalence type (or both).

Cheers,
	Fergus.

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list