
7.1 Introduction
In ML programming work generally, transient values tend not to be stateful. Objects are used mainly when information persists from transaction to transaction. The programming model required for using the MLWorks FI is usually procedural and imperative, relying very much upon persistent state.
This situation is almost forced, because most foreign languages are to some degree or even entirely static and imperative. In particular, function calling requires addresses and pointers to be consistent during a foreign function call. This can be achieved by providing static memory and having ML operators construct and analyse data in these static areas.
We have not followed convention and called the FI a Foreign Function Interface or FFI. The reason for this is that ML is strongly typed, and so the interface must also be concerned with the differences in typing between different languages. Further, the concept of function is central to ML and is certainly not neutral from an ML perspective. For this reason, we chose to call our interface a Foreign Interface: a term which is simpler and which implies greater generality than Foreign Function Interface.

Generated with Harlequin WebMaker