[mercury-users] constrained polymorphic mode error
Fergus Henderson
fjh at cs.mu.OZ.AU
Sat Aug 10 03:21:11 AEST 2002
On 09-Aug-2002, Tom Schrijvers <Tom.Schrijvers at cs.kuleuven.ac.be> wrote:
> Here is another error that puzzles me:
>
> $ mmc cpm_error.m -E
> cpm_error.m:031: In clause for `m(in(cpm_error:val_closure(cpm_error:closure_list((X =< ground)))), out(cpm_error:closure_list((X =< ground))))':
> cpm_error.m:031: in argument 1 of call to predicate `cpm_error:eval/2':
> cpm_error.m:031: mode error: variable `CCL' has instantiatedness `cpm_error:val_closure(cpm_error:closure_list((X =< ground)))',
> cpm_error.m:031: expected instantiatedness was `cpm_error:val_closure((V_2 =< ground))'.
>
> $ mmc -v
> Mercury Compiler, version rotd-2002-08-05, configured for i686-pc-linux-gnu
>
> As far as I can tell it holds that
>
> cpm_error:closure_list((X =< ground)) =< ground
>
> so why does the compiler generate this error?
That one looks to me at first glance like a compiler bug.
When I tried to simplify the test case, the compiler threw up its hands
("Uncaught Mercury exception: Software Error: ... unify_inst failed"),
which indicates that it is definitely a bit confused about these constructs.
Thanks for reporting this -- we will look into it and see if we can
come up with a fix.
Note that this is a fairly new feature, which is not included in the
latest stable release, so I guess it is not *too* suprising that it
may have some bugs.
--
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-users mailing list
post: mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the users
mailing list