[m-dev.] Odd error from the compiler

Ralph Becket rafe at cs.mu.OZ.AU
Mon Jun 16 10:32:34 AEST 2003

I've been working on a packrat parser in

Here's what I get when I try compiling a demo program:

$ mmc --make demo
Making demo.c
demo.m:039: In clause for `main(di, uo)':
demo.m:039:   in argument 1 of call to predicate `packrat.init_memoes/4':
demo.m:039:   mode error: variable `TypeInfo_39' has instantiatedness `free',
demo.m:039:   expected instantiatedness for non-local variables
demo.m:039:   of lambda goals is `ground'.
For more information, try recompiling with `-E'.
** Error making `demo.c'.

I'm a little bit suspect about error messages that mention TypeInfo

At the very least, this is an unhelpful error message (I don't know how
to fix the problem).  At worst it's a bug.  Can anybody say anything one
way or the other?

[Time passes... DMO pointed out that the code that caused the above error
violated the monomorphism restriction for higher order code.  I've fixed
that problem, but my point about the error message remains the same.
Unfortunately, I haven't preserved the erroneous code, but could
probably reproduce it if necessary.]

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