std1.0.0-beta-7 SafeC docs

std :: async::sync

Struct std::Cancellable

#include <std/async/sync.h> source

generic<F: Future, T> struct Cancellable {
    F inner;
    struct Cancelled c;
    int finished;
}

'inner' until it finishes or 'token' is cancelled, whichever is first; on cancellation 'inner' is dropped. Output: ?T, null if cancelled.

Fields

§F innersource
§int finishedsource

Methods

§struct Poll<?T> poll(&Context cx)source · definition
§void drop()source · definition