Module Imandra_util.Switch
Switch to cancel tasks
A switch can be activated once, and remains activated forever afterwards
val remove_cb : cb_handle -> unitval empty_cb_handle : cb_handleval set_poll_cb : t -> (unit -> unit) -> unitSet a callback to call to perform some (quick) background polling
val with_cb : t -> (unit -> unit) -> (unit -> 'a) -> 'aAdds callback, computes the function, then remove the callback
val set_cb_opt : t option -> (unit -> unit) -> cb_handleval with_cb_opt : t option -> (unit -> unit) -> (unit -> 'a) -> 'aval activated : t -> boolis the switch already activated?
val poll : t -> unitDo a bit of background work (e.g. polling)