[m-dev.] for review: fix intermodule-optimization bug

Fergus Henderson fjh at cs.mu.OZ.AU
Mon Nov 8 16:41:07 AEDT 1999


On 08-Nov-1999, Simon Taylor <stayl at cs.mu.OZ.AU> wrote:
> 
> Fix a bug reported by Robert Jeschofnik (rejj at students.cs.mu.oz.au)i
> which caused unique mode errors to be reported for clauses in
> a `.opt' file, but not in the `.m' file. This was due to the
> extra headvar unifications added by writing out the clauses
> and reading them back in again creating extra aliasing that the
> current mode analyser can't handle.
> 
> compiler/intermod.m:
> 	Strip out the extra unifications for the head variables
> 	of a clause, replacing the introduced unification with
> 	the RHS term. This doesn't work for lambda-goal unifications,
> 	but they shouldn't occur in clause heads too often.
>
> compiler/hlds_out.m:
> 	In hlds_out__write_clause, allow the arguments of the clause
> 	head to be terms rather than just variables.
> 
> tests/valid/nested_unique_intermod.m:
> tests/valid/nested_unique_intermod2.m:
> tests/invalid/builtin_int.m:
> tests/invalid/builtin_int.err_exp:
> 	Test case.

You should mention the Mmakefiles that you changed
in the log message.

Apart from that, this change looks fine.

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
WWW: <http://www.cs.mu.oz.au/~fjh>  |  of excellence is a lethal habit"
PGP: finger fjh at 128.250.37.3        |     -- the last words of T. S. Garp.
--------------------------------------------------------------------------
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