std1.0.0-beta-7 SafeC docs

std :: async::combinator

Struct std::Join2

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

generic<A: Future, B: Future, TA, TB> struct Join2 {
    A a;
    B b;
    TA ra[1];
    TB rb[1];
    int done_a;
    int done_b;
    int delivered;
}

Polls both until both are Ready (tokio::join!). Output: Both<TA, TB>.

Fields

§TA ra[1]source
§TB rb[1]source
§int done_asource

1: ra holds a's output

§int done_bsource
§int deliveredsource

the outputs moved out in the Ready Both

Methods

§struct Poll<struct Both<TA, TB>> poll(&Context cx)source · definition
§void drop()source · definition

and outputs nobody received