[MLton-user] Syntax error: replacing WILD with ASTERISK.
Michel Barakat
bmichel at gmail.com
Tue Jun 29 03:08:06 PDT 2010
Hi,
* Context: moving old code which uses MLton to an amd64 machine.
- Moved from MLton 20041109 to MLton 20070826 because:
-- no amd64 support in MLton 20041109
-- looks for " /usr/lib/mlton/world.mlton ". Couldn't find it's
equivalent in the latest release MLton 20100608.
- Using " -default-ann 'allowFFI true' " flag instead of deprecated "
-default-ann 'allowImport true' "
- Wasn't picking up the SML_LIB variable. Fixed by specifying the "
-mlb-path-map " manually.
* Compiler options:
" /usr/lib/mlton/mlton-compile @MLton load-world
/usr/lib/mlton/world.mlton ram-slop 0.5 fixed-heap 1200m --
/usr/lib/mlton -cc gcc -cc-opt -I/usr/lib/mlton/include -cc-opt -O1
-cc-opt -fno-strict-aliasing -fomit-frame-pointer -w -target-cc-opt
x86 -fno-strength-reduce
-fschedule-insns
-fschedule-insns2
-malign-functions=5
-malign-jumps=2
-malign-loops=2
-mcpu=pentiumpro -target-cc-opt sparc -Wa,-xarch=v8plusa
-fcall-used-g5
-fcall-used-g7
-m32
-mv8
-mcpu=ultrasparc -target-link-opt amd64 -L/usr/local/lib/ -lgmp
-target-link-opt cygwin -lgmp -target-link-opt darwin -lgmp
-target-link-opt freebsd -L/usr/local/lib/ -lgmp -target-link-opt
mingw -lgmp -lws2_32 -lkernel32 -lpsapi -lnetapi32 -target-link-opt
netbsd -Wl,-R/usr/pkg/lib -L/usr/local/lib/ -lgmp -target-link-opt
openbsd -L/usr/local/lib/ -lgmp -target-link-opt solaris -lgmp -lnsl
-lsocket -link-opt -lgdtoa -lm -runtime ram-slop 0.3 -default-ann
allowFFI true -mlb-path-map /usr/lib/mlton/mlb-path-map -link-opt
-static -const Exn.keepHistory true main.sml
/home/michel/adate/bin/execute.c "
* Problem
I'm facing the following error message when compiling:
" Error: main.sml 4.15.
Syntax error: replacing WILD with ASTERISK.
[...]
Parse error.
compilation aborted: parseAndElaborate reported errors "
Investigating main.sml reveals the error is happening at the _ffi
calls, for example:
" val HATCHET = _ffi "c_fun_heap_size" : unit -> int; "
Found similar issue but no solution on:
http://mlton.org/pipermail/mlton/2005-November/028162.html
Any help is appreciated.
Cheers
Michel
More information about the MLton-user
mailing list