2 * 2004 Matthew Fluet (mfluet@acm.org)
3 * Ported to MLton threads.
8 * COPYRIGHT (c) 1995 AT&T Bell Laboratories.
9 * COPYRIGHT (c) 1989-1991 John H. Reppy
15 val getTid : unit -> thread_id
17 val spawnc : ('a -> unit) -> 'a -> thread_id
18 val spawn : (unit -> unit) -> thread_id
20 val yield : unit -> unit (* mostly for benchmarking *)
22 val joinEvt : thread_id -> unit Event.event
24 (* thread-local data *)
25 val newThreadProp : (unit -> 'a) ->
27 clrFn : unit -> unit, (* clear's current thread's property *)
28 getFn : unit -> 'a, (* get current thread's property; if *)
29 (* the property is not defined, then *)
30 (* it sets it using the initialization *)
32 peekFn : unit -> 'a option, (* return the property's value, if any *)
33 setFn : 'a -> unit (* set the property's value for the *)
36 val newThreadFlag : unit -> {getFn : unit -> bool, setFn : bool -> unit}