[m-dev.] diff: fix reuse codegen problem

Peter Ross peter.ross at miscrit.be
Fri Mar 9 00:06:57 AEDT 2001


On Thu, Mar 08, 2001 at 11:50:35PM +1100, Fergus Henderson wrote:
> On 08-Mar-2001, Peter Ross <peter.ross at miscrit.be> wrote:
> > 
> > compiler/ml_unify_gen.m:
> >     Change from using the depreceated body binop to the unmkbody unop.
> 
> s/depreceated/deprecated/
> 
> What makes you think that the `body' binop is deprecated?
> If it is, why is it deprecated?
> 
Because mlds_output_binop no longer handles this case, and it used to
work at some previous point, so I assumed that we were no longer using
this operator.

> > Index: compiler/ml_unify_gen.m
> > ===================================================================
> > RCS file: /home/mercury1/repository/mercury/compiler/ml_unify_gen.m,v
> > retrieving revision 1.16.2.8
> > diff -u -r1.16.2.8 ml_unify_gen.m
> > --- compiler/ml_unify_gen.m	2001/02/20 10:15:27	1.16.2.8
> > +++ compiler/ml_unify_gen.m	2001/03/08 09:36:41
> > @@ -1065,8 +1065,8 @@
> >  			Var2Rval = lval(Var2Lval)
> >  		;
> >  			Var2Rval = mkword(PrimaryTag,
> > -					binop(body, lval(Var2Lval),
> > -					ml_gen_mktag(ReusePrimaryTag)))
> > +					unop(std_unop(unmkbody),
> > +					lval(Var2Lval)))
> 
> Could you explain that one for me in more detail?
> 
When reusing a cell, we must ensure that the tag is correct.  If the tag
on the cell we wish to reuse is different to the one which should be on
the new cell, then we replace the old tag with the new tag.

Pete
--------------------------------------------------------------------------
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