summaryrefslogtreecommitdiffstats
path: root/src/test/ui/async-await/type-parameter-send.rs
blob: ab2b62aa5aa1c13503e778c698034eca267c70c7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// check-pass
// compile-flags: --crate-type lib
// edition:2018

fn assert_send<F: Send>(_: F) {}

async fn __post<T>() -> T {
    if false {
        todo!()
    } else {
        async {}.await;
        todo!()
    }
}

fn foo<T>() {
    assert_send(__post::<T>());
}