[MLton-user] Java and MLton
Stephen Weeks
sweeks@sweeks.com
Fri, 11 Jun 2004 07:23:22 -0700
> Has anyone tried accessing a MLton module called from a Java program via
> JNI? Any thoughts on feasibility?
>
> JNI is Java's FFI or native interface to C.
The infrastructure for calling MLton from C is there. One thing
that's missing from MLton is the ability to generate a library that
can be linked with other programs. I don't think there's anything
hard to fix this, just work to be done is in unbundling MLton's
assumption, used in various places, that it is generating the "main"
program. Were I to add such a feature, I would certainly try to make
the library interface look just like a C library's, so I would think
it would be enough for what you want.