In SML/NJ, linking means executing top-level code (i.e., module creation and initialization code) of each compilation unit. The resulting bindings can then be registered at the interactive top level.
val make : string -> bool val autoload : string -> bool
CM.make first acts like CM.recomp. If the (re-)compilation is successful, then it proceeds by linking all modules that require linking. Provided there are no link-time errors, it finally introduces new bindings at top level.
During the course of the same CM.make, the code of each compilation module that is reachable from the root will be executed at most once. Code in units that are marked as private (see Section 4.3) will be executed exactly once. Code in other units will be executed only if the unit has been recompiled since it was executed last time or if it depends on another compilation unit whose code has been executed since.
In effect, different invocations of CM.make (and CM.autoload) will share dynamic state created at link time as much as possible unless the compilation units in question have been explicitly marked private.
CM.autoload acts like CM.make, only ``lazily''. See Section 4.2 for more information.
As before, the result of CM.make indicates success or failure of the operation. The result of CM.autoload indicates success or failure of the registration. (It does not know yet whether loading will actually succeed.)