single threading mlton

Henry Cejtin henry@sourcelight.com
Wed, 16 Jan 2002 00:25:27 -0600


If I understand Stephen's mail correctly, I really REALLY don't like the idea
of tabulator things that don't pass around a state which requires one to  use
a  ref.   The  general rule, in my mind, is that if some function doesn't get
the stack, then it gets a state which is passed to it and  which  it  returns
(updated).

Also,  in  general I think we are really missing iterators.  Folders are very
nice when they are what you want to do (the looping code owns the  stack  and
you  always do one pass through the entire collection), but when you need the
greater flexibility of iterators (like doing two  collections  in  parallel),
they are very nice.

As to threads, everyone knows my distaste for them, but it also seems like if
you really want them, then you have to commit to  a  fancier  analysis,  like
Stalin  does  for call/cc, which doesn't just give up if a thread is used any
where.  Maybe this is hopeless for things like signals,  but  I  would  think
that it could still do something.