[MLton] MLton library project
Stephen Weeks
sweeks at sweeks.com
Tue Sep 26 14:38:22 PDT 2006
> I think that one big decision to make is if the library depends heavily on
> itself. I.e., in the mlton/basic stuff, although I really MUCH prefer the
> style, it all depends on other things in that style. The result is that you
> have to carry a huge chunk of the library to use what may be logically a very
> small part.
True. I wonder if the mlton/basic library, which predates MLB by many
years, would be better expressed as a large collection of small MLBs,
each explicitly expressing their dependencies on other MLBs, where
each MLB only exports a structure/signature or two. Then one can
easily build subsets that will draw in exactly what's needed and will
only expose what one specifically imports.
> One thing that I think would actually be a big help for small programs would
> be if the command line mlton would accept multiple .sml, .cm and This way I
> could just say something like
> mlton my-library.mlb junk.sml
> to compile a program which fits in just one file, but needs my library.
> Without this, I have to create a .mlb or .cm file for every program I write.
That is a very reasonable request. I don't see any reason why we
can't take the meaning of a number of SML/MLB files on the command
line to simply be a single MLB listing all the files.
More information about the MLton
mailing list