[MLton] runtime optimization flags?

Matthew Fluet fluet at cs.cornell.edu
Tue Nov 28 13:52:14 PST 2006


>>> I'm getting the following error compiling after the Makefile patch:
>>>
>>> Error: ../lib/mlton/basic/file-desc.sml 14.32.
>>>  Function applied to incorrect argument.
>>>    expects: _ * (_ -> [word])
>>>    but got: _ * (_ -> [Word64.word])
>>>    in: o (Word.layout, fdToWord)
>>>         parseAndElaborate raised in 2.83 + 1.01 (26% GC)
>>
>> What platform?  I was able to self-compile on both x86-linux and
>> x86-darwin without problems.
>
> Oops!  I was accidentally compiling the trunk with MLton compiled
> from the 64-bit branch.  I had this unusual (for me) setup because
> of the experiments I did with the PackWord stuff.

Understandable.  I know I've left a x86_64 branch build on my path before, 
but I guess I've always switched back before trying to compile trunk.

> So, unless something really weird is going on, then you should be
> able to reproduce the above error by compiling the trunk MLton with
> a 64-bit MLton.  AFAIU, the error reflects an assumption (looks
> like SysWord = Word) that is no longer valid with the 64-bit MLton.
> I don't know whether or not this needs fixing.

It's probably worth fixing, although I'll be merging the branches soon, so 
it is almost a moot point.



More information about the MLton mailing list