[MLton] MLton.Thread.atomically

Stephen Weeks MLton@mlton.org
Fri, 26 Mar 2004 10:51:44 -0800


What do people think about removing atomicBegin and atomicEnd from
MLton.Thread, replacing them with a single function

  val MLton.Thread.atomically: (unit -> 'a) -> 'a

This function would do the atomicBegin and atomicEnd, but would also
wrap the computation in a dynamicWind so that if it raises an
exception, atomicEnd is called to end the critical section.