wait 0.2.6

Syntactic sugar for calling async functions outside of an async context.
Documentation
1
2
3
4
5
6
7
8
9
10
use wait::prelude::*;

async fn add(a: i32, b: i32) -> i32 {
    a + b
}

fn main() {
    let val = add(2, 2).wait();
    println!("Result: {}", val);
}