[MLton] the syntax of MLBs

Matthew Fluet fluet@cs.cornell.edu
Thu, 16 Sep 2004 22:18:32 -0400 (EDT)


> 1. It seems that there is no way to include a file name with a space
>    in it.  This is bad.  One way to fix this would be to put filenames
>    in double quotes, and use the same lexical rules as for SML
>    strings.

Using quotes (and keywords) for every file seems like a lot of syntactic
noise.  I'd prefer the convention used most everywhere else (e.g,
Makefiles, shells) of filenames not in quotes unless you need special
chars or spaces.

> 2. I wonder if we went overboard with my goal of making a list of
>    files be a valid mlb.  Would it perhaps be better or clearer if we
>    had a keyword to import files.  We could use "include", "require",
>    "import" (although that's not so good because of _import), or
>    something else.

I don't think it is significantly better.  True, we have some restrictions
right now -- every file must have an extension, and we determine whether
it is sml or mlb based on the extension.  (Of course, the compiler proper
does this as well; there's no way to force compilation of foo.txt as if it
were an sml file).

> 3. I wonder if we should emphasize the different treatment of
>    .sml files and .mlb files using different keywords.  Perhaps we
>    should write

If you're going to be explicit, then you should make this distinction.  I
wouldn't use "open".  "include" seems right for sml files.  I don;t know
about the mlb files.


However, I don't really think this improves anything that much.