author | wenzelm |
Tue, 16 Sep 2008 15:37:32 +0200 | |
changeset 28241 | de20fccf6509 |
child 28550 | 422e9bd169ac |
permissions | -rw-r--r-- |
1 (* Title: Pure/Concurrent/simple_thread.ML
2 ID: $Id$
3 Author: Makarius
5 Simplified thread fork interface.
6 *)
8 signature SIMPLE_THREAD =
9 sig
10 val fork: bool -> (unit -> unit) -> Thread.thread
11 end;
13 structure SimpleThread: SIMPLE_THREAD =
14 struct
16 fun fork interrupts body =
17 Thread.fork (fn () => exception_trace (fn () => body ()),
18 if interrupts then Multithreading.regular_interrupts else Multithreading.no_interrupts);
20 end;