#
Chapter 9
`cml.ss`: Concurrent ML Compatibility

This library defines a number of procedures that wrap MzScheme concurrency procedures. The wrapper procedures have names and interfaces that more closely match those of Concurrent ML.

`(spawn``` `thunk``)` P R O C E D U R E

Equivalent to `(thread/suspend-to-kill `thunk`)` (see section 7.1 in PLT MzScheme: Language Manual).

`(sync``` `waitable``)` P R O C E D U R E

Equivalent to `(object-wait-multiple `#f` `thunk`)` (see section 7.6 in PLT MzScheme: Language Manual).

`(channel``)`

procedure

Equivalent to `(make-channel)` (see section 7.5 in PLT MzScheme: Language Manual).

`(channel-recv-evt``` `channel``)` P R O C E D U R E

Equivalent to `channel`.

`(channel-send-evt``` `channel v``)` P R O C E D U R E

Equivalent to `(make-channel-put-waitable `channel` `v`)` (see section 7.5 in PLT MzScheme: Language Manual).

`(choice-evt``` `waitable``` `···``)` P R O C E D U R E

Equivalent to `(waitables->waitable-set `waitable` `···`)` (see section 7.6 in PLT MzScheme: Language Manual).

`(wrap-evt``` `waitable proc``)` P R O C E D U R E

Equivalent to `(make-wrapped-waitable `waitable` `proc`)` (see section 7.6 in PLT MzScheme: Language Manual).

`(guard-evt``` `thunk``)` P R O C E D U R E

Equivalent to `(make-guard-waitable `thunk`)` (see section 7.6 in PLT MzScheme: Language Manual).

`(nack-guard-evt``` `proc``)` P R O C E D U R E

Equivalent to `(make-nack-guard-waitable `proc`)` (see section 7.6 in PLT MzScheme: Language Manual).

`(thread-done-evt``` `thread``)` P R O C E D U R E

Equivalent to `(thread-dead-waitable `thread`)` (see section 7.2 in PLT MzScheme: Language Manual).

`(current-time``)` P R O C E D U R E

Equivalent to `(current-seconds)` (see section 15.1 in PLT MzScheme: Language Manual).

`(time-evt``` `k``)` P R O C E D U R E

Returns a waitable that is ready whenever `(current-time)` returns a value greater than or equal to `k`.