[MLton-user] MLton performance
Stephen Weeks
MLton-user@mlton.org
Mon, 21 Mar 2005 10:23:28 -0800
> I will consider editting the SML/NJ Library code available off the
> web-site to eliminate TimeLimit from smlnj-lib.mlb (exposing it as a
> separate time-limit.mlb).
In general, I think this is a good solution to this kind of problem:
break up monolithic libraries that export lots of structures into lots
of mlbs, each of which exposes a structure or two and directly
expresses its dependencies on other structures by importing the
appropriate mlbs. This has the advantage of making dependencies
explicit and including only the files that a program needs, without
any modifications to mlb semantics. I think it would be worthwhile to
do this for the Basis and the MLton libraries too.
This approach is also much like what is done in other languages,
e.g. Python, where one explicitly imports the modules one needs, and
it doesn't seem too verbose in practice.